Re: logical problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi,

the way i have solved this is problem is to set up a graphing coordinate system between the user coordinates (from the CAD file) and the window coordinates: this amounts to setting up a structure containing the min and max of the user coordinates and the window coordinates (and probably more) to be used to translate between the two.

then write the functions user_to_pix_x(), user_to_pix_y(), pix_to_user_x() and pix_to_user_y() for the coordinate system and you can get to there from here with ease, always right vs. the size of the window.

i can provide code if you like.

cheers,

richard


On Mon, 20 Jun 2005 14:10:51 +0200 (MEST), <abent@xxxxxx> wrote:

hi,
please help me i have a logic problem. i write a application
that draws CADpoints from a Cadfile (x,y coord.) on a
drawingarea. so far so good. now i wanna align this points to the
windowsize. my idea was, add the windows x-y coord. to the pointcoord.
but this is not very suggestive. i know this is not a real gtk thing but
i thought some of you are really c++ cracks and could bring me on the
right way. thanks!




--
Richard Boaz
riboaz@xxxxxxxxx
+31.(0)648.792.484
http://www.boazconsultancy.com
_______________________________________________

gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux