Hi Laurent
I'm glad the text alignment issues are fixed. :-)

In terms of the text size. We have had discussions on the list before about
this. The wxWidgets backend takes the text size given to it by Plplot in mm
and converts it to pt (assuming on pt is 1/72 of an inch) and requests that
size text from wxWidgets. So the text size requested should be consistent
with any other text requested from wxWidgets.

I have just followed some of the wxWidgets code through and it seems that
the height in points gets converted to logical units (pixels) using the
screen dpi and then I think (although I'm not sure) that the Windows API
function CreateFont get's called with this size. It seems that the text
size requested is the size of the cell the text resides in, i.e. it
includes leading.

So for the wxWidgetsDemo, The text size requested is 2.342mm, which is 7pt
(rounding to integer values) and is converted to 9 logical units
(pixels) by wxWidgets. This uses the screen dpi so round(7 * 96 / 72)
= 9. And I think this font size is requested using the CreateFont function
as the cell size. In fact when I do a screenshot, zoom in and look at the
text, the bracket in the title is 9 pixels from top to bottom. So it seems
everything is how it should be.

I don't know if other devices use similar metrics for the text, but I
assume they must be pretty similar. I guess that the issue really is that
the demo windows are rather small (at least on my system) because they use
the default window size. I could adjust this and make it some other fixed
size, but I'm a bit nervous to do so in case I make them larger than
somebodies screen. I'm happy to take suggestions?

Phil

On 8 January 2017 at 13:20, Laurent Berger <laurent.ber...@univ-lemans.fr>
wrote:

> Hi phil,
>
>
> I have updated all my repo wxwidgetts and plplot and now everything is OK
> using VS 2015 or MSYS2-mingw64. Thanks you very much.
>
> Only one thing wxplplotdemo legend are small (may be tiny)
>
> Le 05/01/2017 à 15:58, Phil Rosenberg a écrit :
>
> Hi Laurent
> Although I haven't upgraded to wxWidgets 3.1. I think I have isolated
> and fixed the issue. It turned out to affect all wxDCs that support
> transformations so I was able to reproduce your bad results on a
> wxMemoryDc. If you grab the latest version from the Git repo then you
> should find everything is working correctly again. If not then please
> let me know.
>
> Phil
>
> On 5 January 2017 at 00:42,  <p.d.rosenb...@gmail.com> 
> <p.d.rosenb...@gmail.com> wrote:
>
> Hi Alan
>
> I agree it would be good to look at this pre release. It's on my to do list
> for asap.
>
>
>
> Sent from my Windows 10 phone
>
>
>
> From: Alan W. Irwin
> Sent: 04 January 2017 20:37
> To: Phil Rosenberg; Pedro Vicente; Laurent Berger; PLplot development list
> Subject: Re: [Plplot-devel] legend and label using wxWidgets
>
>
>
> On 2016-12-28 23:19+0100 Laurent Berger wrote:
>
>
>
>
> wxwidgets commit 0bf38e1 x04 y axis label is good
>
> (https://github.com/wxWidgets/wxWidgets/commit/0bf38e11a33005e289e30c8bc7c67563eae061be)
>
> wxwidgets commit 49000def x04 y axis label is false
>
> (https://github.com/wxWidgets/wxWidgets/commit/49000defcfb11b409d8935126981b14169ee62a3)
>
>
>
> Hi Phil:
>
>
>
> Assuming (subject to Pedro's further extensive testing) that you have
>
> found a good fix for that bug he had discovered, then the only
>
> remaining potentially release critical issue for the wxwidgets-related
>
> components of PLplot is the issue discovered by Laurent above.
>
>
>
> So to learn more about what Laurent reported above,
>
> I described those two commits as follows:
>
>
>
> software@raven> git clone https://github.com/wxWidgets/wxWidgets.git
> wxwidgets.git
>
> software@raven> cd wxwidgets.git
>
> software@raven> git branch
>
> * master
>
> software@raven> git describe 0bf38e1
>
> v3.1.0-620-g0bf38e1
>
> software@raven> git describe 49000def
>
> v3.1.0-621-g49000de
>
>
>
> So it is clear from these results that Laurent already bisected this
>
> issue with the 621st commit beyond the last official release (3.1.0)
>
> of wxwidgets showing the issue for the first time.  And since this is
>
> an issue that will not affect any user of an official wxwidgets
>
> release at this time, that gives us a good excuse to do nothing at
>
> this time if the potential fix is going to be intrusive.
>
>
>
> Of course, this issue will affect our users as soon as the next
>
> wxwidgets official release is out so it would be nice at this time for
>
> you to (a) confirm the above results for 0bf38e1 and 49000def from
>
> Laurent and figure out what the issue is.  If it turns out to be a
>
> wxwidgets regression introduced for 49000def it would be good for you
>
> to draw this quickly to the attention of the wxwidgets developers so
>
> they can fix that regression before their next official release to
>
> avoid making life difficult for PLplot wxwidgets users.  But if it
>
> turns out to be our problem, then please prepare the fix and use your
>
> best judgement (depending on, e.g., whether the fix is more or less
>
> intrusive than the fix you just made) whether to push it now or wait
>
> until after the release.
>
>
>
> 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); the Time
>
> Ephemerides project (timeephem.sf.net); PLplot scientific plotting
>
> software package (plplot.sf.net); 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
>
> __________________________
>
>
>
>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to