Skip to content
Commit fcbfbcbf authored by Marco Martin's avatar Marco Martin Committed by Nate Graham
Browse files

properly size date label in vertical panels

the Text.Fit sizing policy will size the font in order to fit given a fixed
size of the label, but it can't really cause the other way around which we need:
cause a vertical resize in order to accomodate a larger font.
In order to fake that, we fix the date label to an arbitrary tall height
(will overflow outside the applet) and then size the applet based on the label contentheight instead,
leaving the invisible part of the label outside.
In order to avoid the huge text it used to have, limit the maximum size to an arbitrarly
small value, in this case
Math.min(0.7 * timeLabel.height, theme.defaultFont.pixelSize * 1.4)

BUG:417852
FIXED-IN: 5.21
parent 4bbf78a2
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment