GSoC: Libreoffice Theme (week - 1 update)

Michael Weghorn m.weghorn at posteo.de
Mon May 27 05:17:36 UTC 2024


On 2024-05-27 06:48, Sahil Gautam wrote:
> @Michael made a vaild point.
> 
> Haven't played around with the ColorConfig
> much, (slow PC reasons), but this week I will go  through that.
> Things will be more clear then.
> 
> This is my take on it now.
> - Read the colors from the widget toolkits and store it somewhere.
>    The entries in the `Color 
> ColorConfig::GetDefaultColor(ColorConfigEntry eEntry)`
>    are hard-coded, can be created on startup instead. Something like 
> having a vector
>    of structs with the default color values for different ENUMs 
> associated to
>    UI elements.
> 
> - Then the colors in the StyleSettings can be initialized based on theme 
> selection.
>    If it's "System Theme", then the colors saved in the point above can 
> be used to
>    initialize the StyleSettings. If it's some custom theme (extension), 
> then the
>    colors should be read from the expert configuration instead.

One more aspect to take into account is that the system theme can change 
while LO is running.

You can see that e.g. by starting LO with the gtk3 VCL plugin, then 
changing the GTK system theme:
The new theme is applied right away, not only after restarting LO.
(Similar with kf5 and changing the Qt style.)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/libreoffice/attachments/20240527/2c3a679e/attachment.sig>


More information about the LibreOffice mailing list