property tooSmall depends on height
If it's tool small it changes what text is shown on top of each other
Whether text is shown changes the height; super complex binding loop
that because it throws in a visibility change and goes via layouts isn't
being caught.
From what I can tell of other code when vertical we always want to show
both bits of text.
BUG: 351479
REVIEW: 124874
In my opinion this is just a temporary workaround and not a very good
one (generally, code-wise it's awesome :P). There should really be a
global config option for that but as we now rely on QLocale and QLocale
is...bad at this, here's at least this small help, which will at least
change the clock format on the panel.
Imo we could really really use something like KLocale again.
REVIEW: 124453
BUG: 345378
FIXED-IN: 5.4.0
One of the most reported bugs wrt digital clock is that the second line
text (date or timezone) is unreadable on small panels so this adds new
state to the clock applet that lays things horizontally when the panel
is too small to show text with the "small" font (set in system
settings).
When there is a date displayed, a delimiter is put in between to allow
easier and faster spotting the time (as on a first glance there is just
a bunch of numbers, so quickly orienteering is super important). I used
the dot symbol first but then went for pipe which I think looks more
clean.
REVIEW: 124449
CCBUG: 348072
Adds a simple QSortFilterProxyModel on top of TimeZonesModel and
reimplements filterAcceptsRow using QStringMatcher (supposedly faster
according to qtdocs).
REVIEW: 123740
BUG: 346681
FIXED-IN: 5.3.1
This was added for KDeclarative 5.9 which we already depend on, so let's
just use it. Battery applet already does.
Backports parts of f5a177b6fa
BUG: 347032
FIXED-IN: 5.3.1
The real timezone that Local links to is also in the list of timezones
for which teh time can be displayed. For whatever reason, it can happen
that the real timezone is selected and not 'Local' and then it's not
treated as local anymore, making the "Show local timezone" setting not
work.
This fixes it.
BUG: 343908
REVIEW: 122473
Right now the clock applet is using one single label (besides the
sizehelper) to fit time, timezone and also date. This has several
drawbacks like for example the whole label must use one font size, one
eliding etc.
Putting everything into its own label gives way more flexibility as we
can position and size things independently - for example making the time
bigger font than the timezone or date and elide long timezone name
without omitting the date. The sizing is now also simpler and more
robust.
This patch adds the time and timezone labels into Flow which changes
direction based on the layout (in vertical panels layouts things
vertically, horizontal panels either vertically or horizontally
depending on date being shown or not), the date label is then always
appended at the bottom. The reason for dateLabel not being in the Flow
is that in horizontal panels we want the date label always go to the
bottom and be center aligned and Flow does not support horizontal
alignment of its children. Two anchors seems much easier in this case.
This removes two i18n strings and works around having to add another one
(line 352 in the patch) - it's not kosher but I did it so it can still
be merged for 5.1.
Finally, this adds states for separate handling of vertical and
horizontal panels, which has cleaned the code quite a lot from all the
"vertical ? complex_a_stuff : complex_b_stuff".
REVIEW: 120461
Still has couple missing features:
* no time in the tooltip yet (needs larger refactor)
* no order selection
* no default timezone (but last used is always saved)
* couple minor issues
REVIEW: 120314
CCBUG: 337564
one has to instruct the JS QML engine that the local timezone
changed (e.g. after editting it in kcm clock); keep track of the tzOffset
and do a recalc if it changes
one has to instruct the JS QML engine that the local timezone
changed (e.g. after editting it in kcm clock); keep track of the tzOffset
and do a recalc if it changes