Bug Tracker Incident #7971
I am not familiar with localization in QT, so I am leaving this line of enquiry as an exercise for the reader ...
The Idle Shutdown screen incorrectly displays the number of seconds left until closing.
The Display looks like:
Shutdown in 60 seconds.
This is caused by there being two QLabel widgets named "_count" in the idleShutdown.ui file.
UIC helpfully renames the second instance "_count1" when creating ui_idleShutdown.h, but this is the instance that should be updated by the timer event.
Following the conventions elsewhere in the codebase, the attached patch renames the first instance of the QLabel to be "_countLit".
verified fixed in version 320rc
Combined the 3 labels into a single label using the %1 for the seconds.
Half a fix - I did not spot that there were no spaces between the output of the three QLabels.
I am resisting the urge to simply add whitespace into idleShutdown.ui either side of the _count label, but the display does need spacing.
Suggestions please - is there a best practice way of doing this without upsetting the translators too much?
My first thoughts are go for the easy fix:
But is it "better" to combine the 3 QLabels (_countLit, _count, _secondsLit) into one QLabel and use
QString("Shutdown in %1 seconds.").arg(_secsRemaining);
Or should this be backtracked even further and some property (such as Qt::AlignHCenter) be set in the UI?
If someone can suggest the best approach, I will add the appropriate patch to this bug.
Thanks for the free training ;-)
|Incident||3920||Customer # not auto-capitalized||Related to||x|
|Project||XTUPLEAPPS||Ported From Mantis||x|
SubscribersYou do not have permission to view subscribers.
|12/16/10 09:13||acdrupal||New||Incident Added|