OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
wayland-compat low occasional DISPUTE

Fix LibreOffice scroll lag and wrong sizing on a second monitor

omarchyarchendeavouroscachyosmanjarohyprlandwaylandxwayland
CORRECTED An auditor found the fix wrong or incomplete and rewrote it. · checked against Omarchy omarchy 4.0.4-1 on 2026-10-05
AUDIT NOTE

The wiki claims are quoted correctly (qt6 lag spikes, gtk3 mostly stable, bug 141578, WAYLAND_DISPLAY= workaround) and the UWSM claim holds: /usr/share/uwsm/env.d/10-omarchy says UWSM does not source /etc/profile.d and sources ~/.config/uwsm/default. But LibreOffice's own salplug.cxx autodetect_plugin_list() only prefers kf5/kf6 on Plasma and LXQt and otherwise tries gtk3 first, so on Hyprland LibreOffice already runs gtk3 unless the user forced qt6. The record presents gtk3 as the fix for lag the default config cannot have, so a user already on gtk3 is told to change nothing useful. The same wiki page documents bug 152911, lag that persists on gtk3, worked around with GDK_BACKEND=x11, which the fix omitted. The XWayland branch also ignores Omarchy specifics: with xwayland.force_zero_scaling = true and GDK_SCALE seeded by ~/.config/hypr/monitors.lua, an XWayland LibreOffice gets one global scale, so on mixed monitors it is still wrong on one of them. The wrapper path is sound: /usr/bin/libreoffice is a symlink to soffice, desktop entries call libreoffice, and the session PATH has /usr/local/bin ahead of /usr/bin. Not exercised: launching LibreOffice, and whether GDK_SCALE fully governs gtk3 VCL scaling on X11 is not confirmed.

The cause above was rewritten on 2026-10-05 to match this note; the fix was corrected by the audit itself.

Symptom

LibreOffice scrolls in jerks with big lag spikes when I scroll a document quickly. On a laptop plus external monitor with different scaling, the LibreOffice window is the wrong size on one of them or dialogs are oversized. Uncommenting SAL_USE_VCLPLUGIN in /etc/profile.d/libreoffice-fresh.sh as guides say changed nothing.

Cause

Two separate problems. Scroll lag: the Arch wiki records lag spikes with LibreOffice's qt6 VCL backend on Wayland, and LibreOffice bug 152911, scroll lag that some users also see with gtk3. On Hyprland LibreOffice does not pick qt6 by itself: its autodetection (vcl/source/app/salplug.cxx) prefers KDE backends only on Plasma and LXQt and otherwise tries gtk3 first, so qt6 is in use only if someone set SAL_USE_VCLPLUGIN=qt6. Mixed scaling: per-monitor scaling with different factors is broken by LibreOffice bug 141578, and the wiki's workaround is to run it on XWayland. On Omarchy 4 XWayland is not a full fix, because xwayland.force_zero_scaling = true leaves XWayland apps unscaled by the compositor and GTK on X11 uses the single session-wide GDK_SCALE from ~/.config/hypr/monitors.lua, so one global factor applies to every monitor. The /etc/profile.d route does nothing on Omarchy 4 because the session is started by UWSM, which does not source /etc/profile.d (stated in /usr/share/uwsm/env.d/10-omarchy, which sources ~/.config/uwsm/default instead).

Fix

**1. Check which backend LibreOffice is using.** Help > About shows a VCL: line.

**2. Scroll lag with VCL: qt6: force the GTK3 backend.**

Omarchy 4, in ~/.config/uwsm/default (sourced at login by /usr/share/uwsm/env.d/10-omarchy):


export SAL_USE_VCLPLUGIN=gtk3

Plain Arch with a login shell or display manager that reads /etc/profile.d: uncomment the same line in /etc/profile.d/libreoffice-fresh.sh (or libreoffice-still.sh).

Log out and back in either way. If something you set earlier forces qt6, remove it rather than stacking a second export.

**3. Scroll lag with VCL: gtk3 already (the Hyprland default):** this is LibreOffice bug 152911, and the wiki's workaround is running the GTK backend on X11. Test it:


GDK_BACKEND=x11 libreoffice

**4. Mixed-scale monitors: run LibreOffice on XWayland.** Test it:


WAYLAND_DISPLAY= libreoffice

On Omarchy 4 an XWayland window gets one scale on every monitor, taken from GDK_SCALE (set in ~/.config/hypr/monitors.lua), because Omarchy turns on xwayland.force_zero_scaling. Pick the value for the monitor you use LibreOffice on most, for example WAYLAND_DISPLAY= GDK_SCALE=1 libreoffice for a 1x external screen. On plain Arch without force_zero_scaling the compositor scales the window instead, and it may look blurry on the higher-scale monitor.

To apply it to every launch including the desktop entries, put a wrapper earlier in PATH than /usr/bin, calling the real binary by full path (add GDK_SCALE=1 after WAYLAND_DISPLAY= if you chose a fixed scale):


sudo tee /usr/local/bin/libreoffice >/dev/null <<'EOF'
#!/bin/sh
exec env WAYLAND_DISPLAY= /usr/bin/libreoffice "$@"
EOF
sudo chmod 755 /usr/local/bin/libreoffice

Remove it with sudo rm /usr/local/bin/libreoffice once bug 141578 is fixed.

Verify

Help > About shows the VCL: backend you chose after logging back in. Scrolling a long document is smooth. With the wrapper, hyprctl clients shows xwayland: 1 for the LibreOffice window, and the interface is the right size on the monitor you tuned GDK_SCALE for.

Sources

libreoffice-scroll-lag-or-wrong-scale-wayland