Outreachy Dec 2023 - Implement Qt/KDE Frameworks theming using native Qt widgets
Caolán McNamara
caolan.mcnamara at collabora.com
Thu Dec 7 19:53:37 UTC 2023
On Thu, 2023-12-07 at 08:20 +0000, Michael Weghorn wrote:
> For anyone interested, I'm copying parts of 2 emails I sent to Omkar
> earlier with some more thoughts on the project. If anyone has any
> further thoughts, please don't hesitate to add them.
I think the idea of starting with the simple message dialogs is a good
one.
After that the writer "tools, word count" and then "insert, more
breaks, manual break" are fairly simple non-message dialogs that were
among the first to be adapted to new schemes in the past cause they are
fairly simple.
To make it possible to make incremental progress what can be done is to
have something like a new "QtInstance::CreateBuilder" that defaults to
calling SalInstance::CreateBuilder for everything except for an
initially very short list of .ui files that are known to work with the
new implementation. So can just accept the simplest of dialogs to get
bootstrapped.
There is the gtk4 approach of taking the input .ui and converting it to
a different format that gtk4 itself then loads, or the vcl approach of
loading the .ui and parsing it to create vcl widgets directly.
I don't know what's available in QT but one possibility is reworking
the vcl .ui parser, and split it into a parser and overrideable methods
that do the widget creation. It might also then be a possibility to
rework the layout code of VclBox/VclGrid/VclContainer to be standalone
things that can be reused by multiple implementations so as to
implement a QT version of those. So maybe mostly existing parser where
a new inherited version can override the widget creation to create real
QT ones, with maybe LibreOffice-specific qt-compatible containers
reusing the existing layout logic of the vcl implementations.
More information about the LibreOffice
mailing list