Review Request 118274: [digital-clock] Replace sizing timer with fontSizeMode property

Martin Klapetek martin.klapetek at gmail.com
Fri May 23 10:24:41 UTC 2014



> On May 23, 2014, 12:07 p.m., David Edmundson wrote:
> > applets/digital-clock/package/contents/ui/DigitalClock.qml, line 84
> > <https://git.reviewboard.kde.org/r/118274/diff/1/?file=274305#file274305line84>
> >
> >     we should take this size from the sizeHelper I think?
> >     They might potentially be slightly different.
> >

Sure, would mean less duplicated code...but I don't think they could ever be different if they both take height of the same font?

It's the max size anyway, the real size will be somewhere in the middle in 99% of the cases, computed by QML.


> On May 23, 2014, 12:07 p.m., David Edmundson wrote:
> > applets/digital-clock/package/contents/ui/DigitalClock.qml, line 156
> > <https://git.reviewboard.kde.org/r/118274/diff/1/?file=274305#file274305line156>
> >
> >     I don't get this change

currently it reserves space for 10:00:00 while for times with leading "2" this would be insufficient as 2 is almost always more wide than 1, hence now it reserves space for 20:00:00


- Martin


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/118274/#review58345
-----------------------------------------------------------


On May 23, 2014, 12:04 p.m., Martin Klapetek wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/118274/
> -----------------------------------------------------------
> 
> (Updated May 23, 2014, 12:04 p.m.)
> 
> 
> Review request for Plasma.
> 
> 
> Bugs: 335147
>     https://bugs.kde.org/show_bug.cgi?id=335147
> 
> 
> Repository: plasma-workspace
> 
> 
> Description
> -------
> 
> QML offers a fontSizeMode[1] setting that scales font to the available size. I've replaced the sizing timer we had in clock with this, works very well.
> 
> [1] http://qt-project.org/doc/qt-5/qml-qtquick-text.html#fontSizeMode-prop
> 
> 
> Diffs
> -----
> 
>   applets/digital-clock/package/contents/ui/DigitalClock.qml c05711e 
> 
> Diff: https://git.reviewboard.kde.org/r/118274/diff/
> 
> 
> Testing
> -------
> 
> Plasmoid in horizontal panel - great
> Plasmoid in vertical panel - also great
> Plasmoid on desktop - perfect
> 
> 
> Thanks,
> 
> Martin Klapetek
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20140523/66489560/attachment.html>


More information about the Plasma-devel mailing list