Solved LibreOffice system theme and global menu broken after update

I recently updated the system, and since then the system theme and the global menu don't apply anymore in LibreOffice, but it was fine before the update and I touched nothing.
Code:
Freebsd 14.1 p4
Theme: [Plasma], Breeze [GTK2/3]
DE: Plasma 5.27.11

Code:
LibreOffice:
Version: 24.8.2.1 (X86_64) / LibreOffice Community
Build ID: 480(Build:1)
CPU threads: 4; OS: FreeBSD 14.1; UI render: default; VCL: x11
Locale: en-US (C.UTF-8); UI: en-US
Calc: threaded

 
I am facing the same problem on my desktop after libreoffice was updated to 24.8.2.1, under KDE (plasma 5.27.11). In addition, closing libreoffice results in core dump occasionally.
Incidentally, libreoffice running under XFCE on my laptop still uses the 'gtk2' theme applied through qt5ct without any problem, after this update.
 
I have the same problem myself with KDE5 on 14.1.
I think it broke on the update to Libreoffice from version 24.2.5.2_1 to 24.8.0.3. Re-compiling from ports or clearning the .config directory does not resolve issue.
 
Was LibreOffice upgraded? If not, and assuming you are using packages and not building from ports, try pkg install -f libreoffice a force install (reinstall) of the package.
I ran into an issue with libwraster, one of the ImageMagick7 libraries libwraster depended on was "touched" and broke libwraster and hence WindowMaker.
A pkg install -f libwraster cleared the issue for me.
 
It upgraded originally from packages, then tried reinstalling from ports. The libwraster was not installed, but installing from packages it did not resolve the issue.
Last known version of Libreoffice where the theme worked was 24.2.5.2. None of the 24.8.x seem to have working system themes.
 
I was not expecting you to need libwraster; that was merely an example of "i recently upgraded, it broke this when it shouldn't have and reinstalling the broken package fixed it"
 
  • Like
Reactions: drr
I have nothing to report about the quarterly update , No package have been uninstalled during the process and no package have been reported to be broken or in conflict.
 
  • Like
Reactions: drr
try pkg install -f libreoffice a force install (reinstall) of the package
The issue persists after a pkg install -f with clearing of previous conf files. The issue is also seen on a fresh install of FreeBSD. Now I am getting a core dump every time I close a libreoffice app.
 
i had a issue not so long ago with Handbrake not picking up the global theme
which was defined in settings.ini

Code:
~/.config/gtk-3.0/settings.ini

to fix the issue i had to export the GTK_THEME
in my ~/.zshenv file as well

Code:
~/.zshenv

Code:
# dark theme needed for handbrake
export GTK_THEME=Adwaita-dark:dark

might be worth seeing if the exporting the GTK_THEME in your shell config
and setting it in the the settings.ini also fixes the issue with LibreOffice

Code:
printenv

Code:
GTK_THEME=Adwaita-dark:dark
 
I recently updated the system, and since then the system theme and the global menu don't apply anymore in LibreOffice, but it was fine before the update and I touched nothing.
Code:
Freebsd 14.1 p4
Theme: [Plasma], Breeze [GTK2/3]
DE: Plasma 5.27.11

Code:
LibreOffice:
Version: 24.8.2.1 (X86_64) / LibreOffice Community
Build ID: 480(Build:1)
CPU threads: 4; OS: FreeBSD 14.1; UI render: default; VCL: x11
Locale: en-US (C.UTF-8); UI: en-US
Calc: threaded

It is mine on Openbox, the same version.
lo.gif
 
might be worth seeing if the exporting the GTK_THEME in your shell config
The pkg version of libreoffice is compiled with gtk off and qt5 on.
Code:
Options        :
        COINMP         : off
        CUPS           : on
        DOCS           : on
        GNOME          : off
        GTK3           : off
        GTK4           : off
        JAVA           : on
        KF5            : off
        KF6            : off
        LTO            : off
        MARIADB        : off
        MMEDIA         : on
        PDFIUM         : on
        PGSQL          : off
        QT5            : on
        QT6            : off
        SDK            : off
        TEST           : off
        WEBDAV         : off
Before this issue, libreoffice was using the qt/KDE theme on my KDE desktop. On my other machine running XFCE, libreoffice still uses the theme applied through 'qtct'. So, I think it should have used the qt theme, not gtk.
 
Additional info :


Code:
$ gdb /usr/local/lib/libreoffice/program/soffice.bin soffice.bin.core
GNU gdb (GDB) 15.1 [GDB v15.1 for FreeBSD]
Copyright (C) 2024 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-portbld-freebsd14.1".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/local/lib/libreoffice/program/soffice.bin...
(No debugging symbols found in /usr/local/lib/libreoffice/program/soffice.bin)
[New LWP 134278]
[New LWP 153466]
Core was generated by `/usr/local/lib/libreoffice/program/soffice.bin --writer --splash-pipe=5'.
Program terminated with signal SIGSEGV, Segmentation fault.
Address not mapped to object.
#0  0x00000008222374e4 in rtl_uString_release () from /usr/local/lib/libreoffice/program/libuno_sal.so.3
[Current thread is 1 (LWP 134278)]
(gdb)

Code:
:~ $ neofetch
```                        `      
  ` `.....---.......--.```   -/    -------------
  +o   .--`         /y:`      +.   OS: FreeBSD 14.1-RELEASE-p4 amd64
   yo`:.            :o      `+-    
    y/               -/`   -o/    
   .-                  ::/sy+:.    
   /                     `--  /  
  `:                          :`   DE: Plasma 5.27.11
  `:                          :`   WM: KWin
   /                          /    Theme: [Plasma], Breeze [GTK2/3]
   .-                        -.    Icons: Flat-Remix-Blue-Dark [Plasma], Flat-Remix-Blue-Dark [GTK2/3]
    --                      -.    
     `:`                  `:`      
       .--             `--.        
          .---.....----.

Also, it's the same for me, reinstalling LibreOffice, or deleting its ~.config directory change nothing.
 
i had a issue not so long ago with Handbrake not picking up the global theme
which was defined in settings.ini

Code:
~/.config/gtk-3.0/settings.ini

to fix the issue i had to export the GTK_THEME
in my ~/.zshenv file as well

Code:
~/.zshenv

Code:
# dark theme needed for handbrake
export GTK_THEME=Adwaita-dark:dark

might be worth seeing if the exporting the GTK_THEME in your shell config
and setting it in the the settings.ini also fixes the issue with LibreOffice

Code:
printenv

Code:
GTK_THEME=Adwaita-dark:dark
I don't have a variable named GTK_THEME in ~/.config/gtk-3.0/setting.ini, neither any ~/.shenv file
Code:
cat .config/gtk-3.0/settings.ini
[Settings]
gtk-application-prefer-dark-theme=true
gtk-button-images=true
gtk-cursor-theme-name=breeze_cursors
gtk-cursor-theme-size=24
gtk-decoration-layout=icon:minimize,maximize,close
gtk-enable-animations=true
gtk-font-name=Noto Sans,  10
gtk-icon-theme-name=Flat-Remix-Blue-Dark
gtk-menu-images=true
gtk-modules=colorreload-gtk-module:window-decorations-gtk-module:appmenu-gtk-module
gtk-primary-button-warps-slider=false
gtk-shell-shows-menubar=1
gtk-theme-name=Breeze
gtk-toolbar-style=3
gtk-xft-dpi=98304
 
There were no problems. XFCE with Graybird dark, GTK2/3. Office works good (v. 24.8.2.1 (X86_64)). But GIMP was problem (Rectangle select tool) after the update. I deleted the config in the home directory and everything is OK.
 
It appears that libreoffice 24.8.2.1 is using VCL plugin 'gen' by default, resulting in the 'x11' UI.
libreoffice-vcl-x11.png


Setting VCL plugin to 'qt5' brings the qt/plasma theme back. For me, this seems to also resolve the issue of core dump on exit.
libreoffice-vcl-qt5.png


I believe the libreoffice launch script selects the default VCL plugin. Not sure why the latest version uses 'gen' when previous versions used 'qt5'; the libreoffice binary package is compiled with qt5 'on'.
 
It appears that libreoffice 24.8.2.1 is using VCL plugin 'gen' by default, resulting in the 'x11' UI.
View attachment 20742

Setting VCL plugin to 'qt5' brings the qt/plasma theme back. For me, this seems to also resolve the issue of core dump on exit.
View attachment 20743

I believe the libreoffice launch script selects the default VCL plugin. Not sure why the latest version uses 'gen' when previous versions used 'qt5'; the libreoffice binary package is compiled with qt5 'on'.
How did you changed this setting permanently because for me adding
Code:
export SAL_USE_VCLPLUGIN=qt5
to
Code:
~/.profile
changed nothing.

This work :
Code:
SAL_USE_VCLPLUGIN=qt5 /usr/local/bin/soffice
but it's not permanent.
 
How did you changed this setting permanently because for me adding
I do not use a display manager, so I set this environment variable through the shell's resource file, ~/.cshrc in my case, as
Code:
setenv SAL_USE_VCLPLUGIN qt5
Looking at the entries in ~/.profile, you may need to set it as below, though I have not done this.
Code:
SAL_USE_VCLPLUGIN=qt5; export SAL_USE_VCLPLUGIN
 
If you're using KDE plasma, permanence can be achieved by creating or editing $HOME/.config/plasma-workspace/env/path.sh and adding the following line :
Code:
export SAL_USE_VCLPLUGIN=qt5
Then logout, login and test your libreoffice.
 
Back
Top