interestingly QLocale is not used for many things but that is about to
change, Katie uses it a lot internally (e.g. for QDateTime formatting
and such) so instead of bolting a calendar system on top of KLocale
perhaps a QLocale wrapped around in KLocale will fit the general idea
of using QLocale in widgets when necessary (as does QCalendarWidget).
that however means no way to specify a calendar system (in general,
other than changing the widgets locale itself) but the QDateTime and
related classes are tied to gregorian calendar already - the system
time itself carries no information about the calendar and any
conversions from one calendar to another are basically made up stuff
(there is the time zone thing ofcourse but that is not a calendar)
another interesting thing to note is that KLocale was written such that
it is read-write - changing the date formats for example is possible
because there are public KLocale methods for that.
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
KDateTime shall be used only for storing date and time while KLocale
shall be used to display such, not even going to test what KDateTime
does because it is basically a few methods on top of QDateTime now.
and because QDateTime knows not much about calendar systems while
KLocale supports several it makes sense for KDateTime to not be used for
displaying date and time thus the TODOs for KLocale are simply removed
note that KLocale still uses its own parser and formatter which means
that the change affects only KDateTime and its uses, not KLocale
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
simplifies startup notification for example, external applications that
pass the "nofork" argument may fail (not uncommon to be passed to
konsole)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
because the details widget may be shown, the dialog manually resized and
when the details widget is hidden the manually set size gets overriden -
the dialog size should remain the same after manual resize!
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
essentially moving my code from the old networkstatus module, see the
following commits in the kde-workspace repo:
809b90a113bb559a94266464e03cba6f0ed197ae
c46a5297cc49bf4f19f81ee109833fb0abab9a99
3e01d82f44bf587251455368f7502e9e4e204176
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
mixing style sheet and palette changes is documented to be quircky, note
that the style sheet of the comment label was not reset back to normal
when the message type was changed to KTitleWidget::PlainMessage.
on a side note QPalette::Foreground (or the color style sheet property) and
QPalette::WindowText are the same
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
can animate the opacity too but size change animation suits better a
message widget that is not dialog, still it happens in 500ms and renders
much faster than the previous snapshot-based approach so..
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
the fixed size policy causes all sort of trouble, no more tho. also the
buttons will be centered now when word wrapping is on
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
that way file and directory dialogs will be consistent, not to mention
there were things that KDirSelectDialog was lacking such as resizable
places area.
more changes are needed to account for the directory mode
(KFile::Directory), currently for directory only mode the filter is set
to "All Folders" but it can be changed (the filter widget is not
disabled). also when an attempt to open non-existing directory by name
(via the name input widget) the error says "the file cannot be found"
- it should be "the directory cannot be found" for directory mode
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
QAction has a text() method which will return the same string (the
string passed to the QAction constructor)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>