xforms-development
[Top][All Lists]
Advanced

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

Re: [XForms] axes coords in XYPlot


From: Jens Thoms Toerring
Subject: Re: [XForms] axes coords in XYPlot
Date: Fri, 20 May 2011 13:33:22 +0200
User-agent: Mutt/1.5.20 (2009-06-14)

On Fri, May 20, 2011 at 12:37:41PM +0200, Michal Szymanski wrote:
> > Would you're requirements be satisfied with
> > 
> > void fl_get_xyplot_plotrange( FL_OBJECT * obj,
> >                                                       FL_COORD  * llx,
> >                               FL_COORD  * lly,
> >                               FL_COORD  * urx,
> >                               FL_COORD  * ury );
> > 
> > where llx and lly are the coordinates of the lower left
> > hand and urx and ury those of the upper right hand corner
> > (in pixels relative to the object)? The values are, just
> > as you proposed, from the xi, yi, xf and yf members of
> > the FLI_XYPLOT_SPEC structure.
> 
> Seems fine. If we, however, can afford adding two routines, I would vote for
>   void fl_get_xyplot_screen_plotrange
>   void fl_get_xyplot_world_plotrange
> the first being exactly what you have suggested, and the latter returning
> world coords (which, AFAIU, are kept as xmin,xmax,ymin,ymax members of the
> structure - this may require checking).

They won't do directly because of the tic rounding. But there's
already the function to convert from screen to world coordinates
and that can be used.

> Surely one can convert between the two but it would be easier to get them
> directly. Furthermore, I actually need "world" coordinates (e.g. to plot an
> overlayed full-width or full-height lines on the data) and do not
> immediately see any need for the screen coords of the plot corners.

I will add a second function for the world coordinates.

> > If you are prepared to use the git repository you can
> > download the new version with this function (and a few
> > other bug fixes) immediately (modulo docs for the new
> > function), otherwise you will have to wait until I get
> > around to upload a new "pre-release" version (hopefully
> > within the next few days).
> 
> Well, I can try. I have found the links and instructions on the XForms
> Savannah page.

Just wait a bit until I have checked in the new version
with the second function (I will send you another email
when I'm done).

> BTW, the News there end on 1.0.93sp1, almost a year ago! :-(

Sorry, my day job keeps me quite busy so that I don't have
too much time to spend on XForms at the moment (or any other
things)...
                           Best regads, Jens
-- 
  \   Jens Thoms Toerring  ________      address@hidden
   \_______________________________      http://toerring.de



reply via email to

[Prev in Thread] Current Thread [Next in Thread]