Re: XForms: aligning positioner to xyplot

Steve Lamont (spl@szechuan.ucsd.edu)
Thu, 25 Dec 97 11:25:13 PST

To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :

> From "T.C. Zhao" <zhao@bloch.phys.uwm.edu> :
>
> > To subscribers of the xforms list from "GERALD POLLACK"
> >
> > getting the bounds of the plotted data, using fl_get_xyplot_xbounds
> > and fl_get_xyplot_ybounds;
> > converting these bounds to screen coords with fl_xyplot_w2s;
> > using the screen coords to set up the positioner's geometry with
> > fl_set_object_geometry;
> >
> > But, the positioner ended up too small; the cursor cannot be placed
> > over the extreme left, right, top or bottom portions of the plot.
>
> I haven't tried, but I think if you set positioner_obj->bw = 0,
> the alignment should be better. I think the library should do
> this automatically.

I tested this and there's still a small but signifcant discrepency
between the value calculated by the positioner and the value you get
if you use fl_get_form_mouse() and fl_xyplot_s2w(), where the latter
value is closer to being correct.

Another thing I noted in experimenting with this is that if you resize
the Window, the crosshairs do not intersect at the same point relative
to the underlying plot in the resized window. I don't know if this is
relevant to the problem above but it is indicative of some sort of
scaling issue.

spl

_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuf2.usuhs.mil or see
http://bob.usuf2.usuhs.mil/mailserv/xforms.html
Xforms Home Page: http://bloch.phys.uwm.edu/xforms
List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/