Click here to Skip to main content
15,920,801 members
Home / Discussions / C#
   

C#

 
Questionhosting windows applications in a winform Pin
algoaddict28-Aug-07 12:07
algoaddict28-Aug-07 12:07 
AnswerRe: hosting windows applications in a winform Pin
Spacix One28-Aug-07 14:13
Spacix One28-Aug-07 14:13 
QuestionRe: hosting windows applications in a winform Pin
algoaddict28-Aug-07 15:37
algoaddict28-Aug-07 15:37 
AnswerRe: hosting windows applications in a winform Pin
Spacix One29-Aug-07 5:04
Spacix One29-Aug-07 5:04 
AnswerRe: hosting windows applications in a winform Pin
Dave Kreskowiak29-Aug-07 5:14
mveDave Kreskowiak29-Aug-07 5:14 
Questionc# class design help Pin
rsaint2728-Aug-07 11:28
rsaint2728-Aug-07 11:28 
QuestionREGEX start and end Pin
Saamir28-Aug-07 11:25
Saamir28-Aug-07 11:25 
AnswerRe: REGEX start and end Pin
PIEBALDconsult28-Aug-07 11:41
mvePIEBALDconsult28-Aug-07 11:41 
GeneralRe: REGEX start and end Pin
Spacix One28-Aug-07 11:43
Spacix One28-Aug-07 11:43 
AnswerRe: REGEX start and end Pin
Joshua Lunsford4-Sep-07 10:04
Joshua Lunsford4-Sep-07 10:04 
Questionsearching an XML file [modified] Pin
jacobparker28-Aug-07 10:14
jacobparker28-Aug-07 10:14 
AnswerRe: searching an XML file Pin
Spacix One28-Aug-07 10:38
Spacix One28-Aug-07 10:38 
GeneralRe: searching an XML file Pin
jacobparker28-Aug-07 12:30
jacobparker28-Aug-07 12:30 
GeneralRe: searching an XML file Pin
Spacix One28-Aug-07 14:04
Spacix One28-Aug-07 14:04 
GeneralRe: searching an XML file Pin
Christian Graus28-Aug-07 16:12
protectorChristian Graus28-Aug-07 16:12 
GeneralRe: searching an XML file Pin
Spacix One29-Aug-07 5:13
Spacix One29-Aug-07 5:13 
GeneralRe: searching an XML file Pin
jacobparker30-Aug-07 4:54
jacobparker30-Aug-07 4:54 
GeneralRe: searching an XML file Pin
Spacix One30-Aug-07 5:10
Spacix One30-Aug-07 5:10 
Questionform control text value & XML Pin
Blubbo28-Aug-07 9:30
Blubbo28-Aug-07 9:30 
QuestionScaling a Polygon Pin
Joshua Lunsford28-Aug-07 9:26
Joshua Lunsford28-Aug-07 9:26 
AnswerRe: Scaling a Polygon Pin
Hessam Jalali28-Aug-07 21:56
Hessam Jalali28-Aug-07 21:56 
I don't know this would be useful or not (and I think you already know this!)but this is all it's math

it can be done using rectangle technique and i'm think is fast enough for normal size shapes

you can assume all your shapes you are going to resize are in a rectangle (x1,y1),(x2,y2) which the first one is top left and the second is bottom right

so for resizing the shape you can resize the rectangle and map the changes to your shape

the easiest way is to get one point as a reference inside the rectangle for fixing the shape

the rectangle would be used for calculating the ratio if you get the ratio directly you wouldn't need the ectangle points

for example I suppose that I have a polygon with (10,10),(21,21),(15,40) and I want to resize it to 2X (the ratio)

I assume my reference point to (10,10)

my new resized polygon without fixing to its position is (20,20),(42,42),(30,80)

my referene point is (20,20) in new polygon so it has linear transform (10,10) from the actual reference so I must subtract it and my refDiff would be (10,10)

the resized fixed position polygon would be (10,10),(32,32),(20,70)

but if you dont have the ratio you must find ir from the rectangle which "x1 is Min of all x"
"x2 is Max of all x" "y1 is Min of all y" and "y2 is Max of all y"

you cn find the ratio from changing the first ractangle Width and Height from the second one and use the ratio as before

so the formula foreach point would be

Xn=ratioAtx*xn-refxDiff
Yn=ratioAty*yn-refyDiff

I think this is the easiest way to do that in math and implementing it is depend on yourself (sorry if you didn't mean this)

hope this would be useful
GeneralRe: Scaling a Polygon Pin
Joshua Lunsford4-Sep-07 10:01
Joshua Lunsford4-Sep-07 10:01 
GeneralRe: Scaling a Polygon Pin
Lewis Liu L8-Sep-09 13:56
Lewis Liu L8-Sep-09 13:56 
QuestionCheck MICR Pin
Saamir28-Aug-07 8:19
Saamir28-Aug-07 8:19 
Questionwhich is more faster Embedded Control or External Pin
I Believe In GOD28-Aug-07 7:14
I Believe In GOD28-Aug-07 7:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.