On 2009-09-28 08:21-0700 Alan W. Irwin wrote:

> I am pretty sure your conclusion is not correct.  The offsets refer to the
> position of the widget on the X root window that corresponds to the physical
> device (monitor or LCD).  So you can specify an offset relative to the
> constant root window for _every_ widget on Linux (since it ultimately uses X
> for display). I haven't looked deeper at it, but I assume both the Qt4 and
> cairographics library stacks provide access to this X capability for their
> respective X backends so it will be simply a matter of finding out how
> that is done and using the PLplot offsets appropriately.

I just tried this idea with revision 10486.  A quick look at the Qt4
documentation seemed to indicate move(ix, iy) was required for this and
should be applied like resize.  Therefore, I applied move right after the
existing resize, and the result worked! Note, -dev qtwidget treats negative
offsets as zero (just like -dev xwin), but positive offsets allow you to
position the -dev qtwidget anywhere on the root window.  And the implication
of the Qt4 documentation is this method of positioning -dev qtwidget works
for the Quartz (Apple) and Microsoft display backends for Qt4 as well.

Note, there is no resize currently used in extqt, but I tried something
similar to the (now) existing resize and move for the qtwidgets case, and
there were no build errors or valgrind errors when I ran
examples/c++/qt_example.  However, that example was completely oblivious to
PLplot -geometry options (size or offset) so I didn't commit that change.
After all, I am only doing this by rote with no sound fundamental knowledge
about what I should be doing here.  Thus, I am leaving it to the Qt4/C++
experts here to get the -geometry option to work for examples/c++/qt_example
and extqt in general.

Also, I leave it to the cairo experts here to get offsets to work for xcairo
and extcairo.  I hope it will be just as straightforward for them as it
was for me for the -dev qtwidget case.

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________

Linux-powered Science
__________________________

------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
Plplot-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to