|
From: Ethan M. <merritt@u.washington.edu> - 2012-09-27 19:06:40
|
On Thursday, September 27, 2012 11:41:50 am Ethan A Merritt wrote:
> On Thursday, September 27, 2012 01:40:18 am Dima Kogan wrote:
> > > On Tue, 25 Sep 2012 21:31:55 -0700
> > > "sfeam (Ethan Merritt)" <eam...@gm...> wrote:
> > >
> > > On Saturday, 22 September 2012, Dima Kogan
> > > <gn...@di...> wrote:
> > > >
> > > > I tackled the long-standing issue of the x11 terminal not
> > > > respecting the requested plot aspect ratio
> > > <snip>
> > >
> > > Hi Dima.
> > >
> > > I've applied your patch to CVS in the development branch after review
> > > and testing. <snip>
> >
> > Hi Ethan. Thanks for applying the patch. Main difference I noticed so far is
> > that the point sizes appear smaller in the x11 terminal than they were before
> > this patch.
>
> I have found another problem. I suspect it may be an integer overflow, but
> if so I can't figure out where. Here's a simple recipe to show the problem:
> gnuplot> set term x11
> gnuplot> set sample 15
> gnuplot> plot x with points pt 5
>
> 1) Adjust the X-window so that the plot is very tall.
> 2) Gradually make the plot window narrower and narrower.
> At some point the top border of the plot stops being correctly drawn near
> the top of the window; instead it is drawn near the bottom.
>
> gnuplot> show var GPVAL_TERM
> GPVAL_TERM_XMIN = 473
> GPVAL_TERM_XMAX = 3837
> GPVAL_TERM_YMIN = 280
> GPVAL_TERM_YMAX = 10072
> GPVAL_TERM_XSIZE = 4096
> GPVAL_TERM_YSIZE = 10245
>
> The problem seems to trigger when YMAX crosses exactly 10000,
> but I don't see any relevant use of 9999 or 10000 as a constant in the code.
> Perhaps it's a formatted field overflow from 4 digits to 5 in the y coordinate?
I think that must be it. The coordinates sent from x11.trm to gnuplot_x11 use
format statements like PRINT2("V%04d%04d\n", x, y);
It looks like either the field width has to be increased everywhere to 5 digits,
or else the new rescaling code needs to rethought (perhaps by adjusting both
xsize and ysize rather than only adjusting ysize?) Increasing the field width
has the drawback that more bytes will be sent over the channel regardless of the
window size, which can slow down the communication.
What to do?
Ethan
>
>
> > I'm attaching another patch that tries to handle the point sizes in
> > the same way as the wxt and qt terminals do. After this, the points look similar
> > to the way they looked before.
>
> OK, thanks.
> But please have a look at the problem described above.
>
> >
> > dima
> >
>
> Ethan
>
>
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://ad.doubleclick.net/clk;258768047;13503038;j?
> http://info.appdynamics.com/FreeJavaPerformanceDownload.html
> _______________________________________________
> gnuplot-beta mailing list
> gnu...@li...
> https://lists.sourceforge.net/lists/listinfo/gnuplot-beta
>
--
Ethan A Merritt
Biomolecular Structure Center, K-428 Health Sciences Bldg
University of Washington, Seattle 98195-7742
|