[OpenJDK 2D-Dev] seeking help with text rendering

Michael Heuer heuermh at acm.org
Wed Mar 2 20:37:39 UTC 2011

On Wed, 2 Mar 2011, Phil Race wrote:

> Michael,
> On 3/2/2011 11:05 AM, Michael Heuer wrote:
> > Hello Phil,
> >
> > Thanks for your reply.
> >
> > On Windows XP I see that jlabel-*, jtextcomponent-*, pswing-*, and
> > phtmlview-* all render the same, in that they ignore the LCD-specific
> > rendering hints
> I don't know what you are looking at but I am looking at
> text-rendering-winxp.png
> at the URL you referenced and JLabel does NOT ignore the LCD hints,
> and this XP PNG doesn't have a Jtextcomponent that I can see.
> > (compare e.g. jlabel-lcd-hbgr and java2d-lcd-hbgr, which
> > look very different on my LCD monitor, since HBGR is not appropriate for
> > it).
> I'm not sure what you meant . If you say they are different doesn't
> that mean something is in fact listening to them?
> But where is the "java2d-lcd-hbgr" sample ? Oh, is in the OS X one.
> As I said I don't know about that. Mac doing whatever it wants I
> suppose.  If I had to guess they simply didn't hook up Swing to
> properly honour the hints or you aren't setting the hint in a way
> that OS X believe is applicable. So all a Mac oddity.
> I'm just looking at XP. Show me only on Windows (or Linux)
> where we do the right thing.

Sorry, those screen captures are quite old.  Running the jar attached to
the issue will show all the different combinations.

Note that the rendering for JLabel and friends are influenced by
the Windows XP system property setting described in comment #1 and by the
look and feel setting for Mac OSX (cross-platform vs. Mac OSX look and
feel) and OpenJDK on linux (cross-platform vs. GTK look and feel).


More information about the 2d-dev mailing list