|
From: Thomas S. <t.s...@fz...> - 2009-12-09 20:14:10
|
the factor for the wxt-terminal is 20, in 'gnuplot/src/wxterminal/gp_cairo.h': /* oversampling scale */ #define GP_CAIRO_SCALE 20 if you read out the mouse coordinates in axis units, you may convert these to '20*pixel' units using GPVAL_TERM_* and GPVAL_X/Y_*. then you may generate the circles coordinates and convert back to axis units, specifying the center and the radius in x-axis units. ZoltánVörös wrote: > >> those interactive terminals use an internal screen of a fixed >> size which is then scaled to fit into the actual canvas window. >> >> e.g. X11: >> GPVAL_TERM_XMIN = 285 >> GPVAL_TERM_XMAX = 4000 >> GPVAL_TERM_YMIN = 236 >> GPVAL_TERM_YMAX = 4019 >> always nearly the same values (differ a little bit due to some >> adjustments of the margins because the font size is not scaled), >> regardless of the actual window size and aspect ratio. >> if you plot into an x11 terminal, look at the GPVAL_TERM_* >> variables, then change the plot window size with the mouse, >> replot (is needed to change the variables), and look at the >> variables again, you will see that there is not much change. > > Greetings Thomas, > > Many thanks for your effort! I still feel a bit uncomfortable > with this situation. > >> >> i think this applies to the wxt terminal in a similar way, but i >> don't have a wxt terminal here, so i can't test it. > > I believe, it is 1:20 on wxt. At least, this is what I measured. > After rescaling the terminal with the mouse, I got quite different > numbers. > > My problem is the following: I would like to draw a circle based on > three points on it. I can read out the mouse variables, but those are > given as axis coordinates. However, what if I want to use the mouse > coordinates to draw a circle with respect to the screen? I understand > that the circle requires axis coordinates, but only for the position. > I mean, if I want to draw a circle based on coordinates that I get by > clicking the mouse three times, then I have to have some means of > converting between the screen and the axes. Is there a way to do that? > Cheers, > Zoltán > > > ------------------------------------------------------------------------------ > Return on Information: > Google Enterprise Search pays you back > Get the facts. > http://p.sf.net/sfu/google-dev2dev > _______________________________________________ > gnuplot-info mailing list > gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-info > > -- View this message in context: http://old.nabble.com/What-is-the-meaning-of-the-terminal-variables--tp26700899p26716877.html Sent from the Gnuplot - User mailing list archive at Nabble.com. |