Font size
Felipe Heidrich
felipe.heidrich at oracle.com
Thu Aug 22 16:13:01 PDT 2013
Hi,
Without a test case it is hard to tell what you mean exactly, but here is a guess:
Some type ago we added a new TextBoundsType#LOGICAL_VERTICAL_CENTER.
This is set in modena.css and affects all text content in controls:
.text {
/* This adjusts text alignment within the bounds of text nodes so that
the text is always vertically centered within the bounds. Based on
the cap height of the text. */
-fx-bounds-type: logical_vertical_center;
/* Enable LCD text rendering */
-fx-font-smoothing-type: lcd;
}
I remember that when this mode is set the font leading (space between lines) is not added to the last line.
Which means if your text has only one line this leading is not add at all (previously it was always added).
You could compare Text to Label, if it happens that Text is the right height while Label is a bit short then probably it is TextBoundsType that is making the difference.
Regards,
Felipe
On Aug 22, 2013, at 2:46 PM, Peter Penzov wrote:
> I added System.setProperty("prism.text", "t2k"); to the start() Java method
> but I don't see any change. any other ideas? I could open JIRA case?
>
>
> On Fri, Aug 23, 2013 at 12:07 AM, John Hendrikx <hjohn at xs4all.nl> wrote:
>
>> On 22/08/2013 22:58, Peter Penzov wrote:
>>
>>> Hi,
>>> I'm working on JavaFX application based on Java 8. It seems that from
>>> version b97 there is a issue with -fx-font-size. It's not working
>>> properly.
>>> If you compare the two images from application tested on JavaFX 2.2 and
>>> JavaFX 8 b103 you will see that there is a difference. Can you give me
>>> some
>>> information when this issue will be fixed?
>>>
>>
>> Could you try do:
>>
>> System.setProperty("prism.**text", "t2k");
>>
>> or:
>>
>> -Dprism.text=t2k
>>
>> I noticed somewhere between the builds you mentioned that the "apparent"
>> font size in some areas changed slightly. Perhaps the above setting will
>> help locate the problem.
>>
>>
>>> Regards
>>>
>>
>>
More information about the openjfx-dev
mailing list