Commit graph

149 commits

Author SHA1 Message Date
Ivailo Monev
bd063c8b56 generic: remove dead and irrelevant links references
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-10 14:26:19 +03:00
Ivailo Monev
be9d8967f7 kdeui: remove redundant KGlobalSettings::desktopGeometry() methods
QDesktopWidget is Xinerama aware and it can be disabled because I
implemented option for that, see the following commit in the Katie repo:
b7e4bae65f0cae7f3029b98980f638c077ecfc22

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-09 03:58:14 +03:00
Ivailo Monev
9642bc3d81 kdeui: handle zero time as special case in KTimeEdit and better min/max
the plasma frame applet for example uses zero time (QTime(0, 0, 0), not
invalid time) as a special for case for "never" (i.e. don't update) so
having this feature will make KTimeEdit even more suitable for timers (that
ofcourse has to be handled by the application or library, zero time timers
are a thing)

also min/max now allows to set lower seconds (for example) when the minute
is not zero instead of just restricting the seconds value to a hard-minumum
altough that makes me think a step feature may be needed (e.g. to now allow
intervals less than two seconds with minimum of one second)

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-03 05:58:23 +03:00
Ivailo Monev
643efdc576 kdeui: remove forward-declaration of non-existing KDoubleLine class
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-02 23:11:20 +03:00
Ivailo Monev
4de3537a82 kdeui: new KTimeEdit widget
inspired by QTimeEdit but ment for timers

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-02 13:14:24 +03:00
Ivailo Monev
b323e4a95d kdeui: remove forward-declaration of now non-existing KCalendarWidgetPrivate class
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-02 12:19:10 +03:00
Ivailo Monev
925c7571ce kdeui: remove duplicate qevent header inclusion in khistorycombobox source file
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-30 06:52:52 +03:00
Ivailo Monev
a9e778cc6d kdeui: update note in KCalendarWidget::changeEvent()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-29 08:10:04 +03:00
Ivailo Monev
b7e54f8e21 kdeui: stub KSwitchLanguageDialog
to be rewritten. date, time, days, etc. translation and conversion work
like a charm tho (when translated and supported by the locale classes
ofcourse):
https://ibb.co/hcW0dL3

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-28 00:40:39 +03:00
Ivailo Monev
1a45508306 kdecore: reimplement KLocale
by using QLocale in KLocale and separating the date, time and numbers
conversion from translation KLocale actually gets extended locale
support from QLocale (which uses CLDR data v43 currently). translation
remains unaffected. for comparison here is the result of two function
calls the result of which should explain the whole change:
KLocale::allLanguagesList().size() = 669
KLocale::installedLanguages().size() = 68

the first number is locales Katie supports, the second being the
number of languages Katana is translated into

KSwitchLanguageDialog needs a rewrite but that is on the TODO

also copyrighting KCatalog to me because I rewrote it, for reference:
881b47b8ea

KCalendarSystem gets the middle finger - batteries not included for date
and time. extra calendar systems can, but are unlikely to be, supported
in the future

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-26 23:50:18 +03:00
Ivailo Monev
6d3811054d kdeui: adapt KCalendarWidget to locale and language changes
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-23 12:02:13 +03:00
Ivailo Monev
3c697cf8ce kdeui: implement setter and getter for KCalendarWidget to use a specifiec KCalendarSystem
maybe temporary tho but for now the minimum and maximum date will be that
of the KCalendarSystem

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-23 11:29:06 +03:00
Ivailo Monev
8f8865db62 kdeui: do not warn from setupCalendarWidget() if the system locale name is "C"
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-23 08:21:55 +03:00
Ivailo Monev
6c2c0efda8 kdeui: remove unused klocale header inclusion in kcalendarwidget header
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-23 06:20:32 +03:00
Ivailo Monev
061a11fd43 kdeui: replace KDatePicker/KDateTable with new KCalendarWidget class
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>
2023-07-23 06:16:56 +03:00
Ivailo Monev
e84a04fa67 kdeui: remove forward-declaration of now non-existing KTimeZones class
replaced with KTimeZoneList

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-23 02:50:53 +03:00
Ivailo Monev
000c8af989 kdeui: remove unused date and time related widget classes
some of the classes date back to 2001 and 2002, still unused

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-23 02:48:22 +03:00
Ivailo Monev
f2f37377e3 kdecore: reimplement KTimeZone
simpler, cleaner and most importantly - thread-safe (more than the
previous implementation anyway).

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-22 03:53:20 +03:00
Ivailo Monev
f452e2e50b kdecore: reimplement KDateTime via QDateTime
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>
2023-07-21 07:51:13 +03:00
Ivailo Monev
b4fc8cf48b kdeui: remove unused KVBox member and update its documentation
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-10 19:39:19 +03:00
Ivailo Monev
3fdb845769 kutils: multi-backend knetworkmanager implementation
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>
2023-07-08 21:10:54 +03:00
Ivailo Monev
c1456e739a kdeui: update internal KTitleWidget widgets on font change event
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-07 20:12:24 +03:00
Ivailo Monev
937f116b5f kdeui: change the palette of internal KTitleWidget widgets
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>
2023-07-07 20:09:17 +03:00
Ivailo Monev
6e033933c7 kdeui: do not animate the KMessageWidget show/hide
without the slow snapshot-based rendering 500ms animation does not even
make a difference..

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-07 17:56:40 +03:00
Ivailo Monev
99a57832a1 kdeui: correct placeholder in KMessageWidget::setMessageType()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-07 08:12:33 +03:00
Ivailo Monev
c32db57584 kdeui: animate the height of KMessageWidget from KMessageWidget::animatedHide()
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>
2023-07-07 08:03:42 +03:00
Ivailo Monev
8bf6e8bd73 kdeui: do not specify margin for the label of KMessageWidget
there is no inner frame now

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-07 07:51:47 +03:00
Ivailo Monev
0ba71250e0 kdeui: essentially KMessageWidget rewrite
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>
2023-07-07 05:57:48 +03:00
Ivailo Monev
a6ffb2dbc0 kdeui: remove unused KPixmapRegionSelectorWidget and KPixmapRegionSelectorDialog classes
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-03 07:23:23 +03:00
Ivailo Monev
59b6598599 generic: remove bogus KMultiTabBarInternal and KACLListView reimplementations
there are no virtual QFrame::contentsMousePressEvent() and
QTreeWidget::contentsMousePressEvent() methods

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-20 01:49:01 +03:00
Ivailo Monev
ff202c6de0 kio: format and indent
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-19 01:42:14 +03:00
Ivailo Monev
e5f56675d2 generic: call QCoreApplication::applicationName() as static method
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-19 01:19:01 +03:00
Ivailo Monev
36c910c653 generic: move stuff from KDE4Internal module to KDELibs4Config
large-scale changes to the build system, nothing a user sees tho - it is
all under the hood

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-17 19:01:40 +03:00
Ivailo Monev
136fb8d51a kdeui: correct indentation in KLineEdit::paintEvent()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-16 18:37:06 +03:00
Ivailo Monev
e4b82a18f2 kdeui: remove redundant fixx11h header inclusion
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-16 18:23:56 +03:00
Ivailo Monev
19df721868 generic: ODR fixes
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-11 19:58:06 +03:00
Ivailo Monev
56ca9a4c41 generic: remove redundant fixx11h header inclusions
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-11 18:42:58 +03:00
Ivailo Monev
92857996e5 kdeui: remove unused definitions related to KTextEdit features
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-10 11:56:09 +03:00
Ivailo Monev
8c9f56e862 kdeui: drop support for spelling correction via dialog
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-10 01:04:04 +03:00
Ivailo Monev
e978590acd generic: define KDE_DEFAULT_DEBUG_AREA in the main build file for each library
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-09 23:43:20 +03:00
Ivailo Monev
7f7eb09b35 kdeui: spelling classes reimplementation
not leaking enchant dictionaries, simpler implementation and its not
spread across 2 libraries (kdecore and kdeui)

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-09 20:45:52 +03:00
Ivailo Monev
0d50d69dbb generic: remove irrelevant TODO files
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-05 02:50:54 +03:00
Ivailo Monev
819cca1e41 kdeui: replace libdbusmenu-qt dependency with custom classes
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-05-28 20:56:05 +03:00
Ivailo Monev
c2618febf9 kdeui: convert some KIconEffect::apply() methods to static
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-05-21 22:41:34 +03:00
Ivailo Monev
4dbb501d25 generic: drop text-to-speech support
Katana (or any interface designed around key and mouse events) is not
for blind people, trying to slap text-to-speech on top of it was the
wrong thing to do to begin with

side note: speech-dispatcher tends to hang if the output device is not
configured properly (i.e. editing /etc/speech-dispatcher/speechd.conf
manually)

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-18 15:56:59 +02:00
Ivailo Monev
bceaae0470 kdeui: prepare for Katie changes
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-17 15:09:27 +02:00
Ivailo Monev
eb8ff2c536 kdeui: remove unused and private KHBox member
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-09 04:55:12 +02:00
Ivailo Monev
593dd8b8d3 kdeui: format and indent khbox source and header files
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-09 04:53:13 +02:00
Ivailo Monev
e7ae8c8351 kdeui: remove unused and private KTabBar methods
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-09 04:46:18 +02:00
Ivailo Monev
521d3cd59b kdeui: remove unused KFadeWidgetEffect class
for example on how to do it (somewhat) properly see KMessageWidget

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-21 20:05:45 +02:00