Skip to content

(Linux) Segments disappear as soon as the timer starts #993

Open

Description

@MirandaStreeter

See attached video for example. It doesn't matter if it's in focus, out of focus, using a keyboard shortcut, or with a control button. Changing the frame rate setting (or any other setting) doesn't seem to make a difference. The segments reappear as soon as I click back out of another page.

Screencast_20241214_213813.webm

Operating System: Arch Linux
KDE Plasma Version: 6.2.4
KDE Frameworks Version: 6.9.0
Qt Version: 6.8.1
Kernel Version: 6.12.4-arch1-1 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 7800X3D 8-Core Processor
Memory: 61.9 GiB of RAM
Graphics Processor: AMD Radeon RX 6600 XT
Manufacturer: ASUS

Activity

  1. added
    requires livesplit-core changesThere's a bug or missing feature in livesplit-core that needs to be implemented.
    layout renderingThis affects the rendering of LiveSplit layouts.
    TauriAn issue about the Tauri based desktop version.
    WebKitAn issue that affects the WebKit engine (used by Safari and Tauri on Linux)
    on Feb 12, 2025
  2. CryZe commented on Feb 12, 2025

    @CryZe
    Collaborator

    What is happening here is that there's 2 canvases on top of each other and for some reason their content gets wiped. I'm guessing the canvas context is getting lost: https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/contextlost_event

    I don't know why that would be happening, but it would be good to confirm it. We can probably try to rerender the content if this happens.

  3. SaveThePolarBearz commented on Mar 9, 2025

    @SaveThePolarBearz
    Contributor

    Same issue on Pop!_OS 22.04 LTS with X11

    • AMD Ryzen 7 5700U with Radeon Graphics
    • 16 GB RAM
    • GNOME 42.9
    • GTK 3.24.33

    Let me know if any other info would help

  4. SaveThePolarBearz commented on Mar 11, 2025

    @SaveThePolarBearz
    Contributor

    So I was able to figure out that forcing layout to redraw by changing its width by a pixel and setting it back worked for me. I know this is a band-aid solution but hopefully this helps give more information about the problem. I did a bit of testing to ensure it redrew everywhere necessary but it still occasionally messes up and the pixel shift is visible.

    In the video I first show what the provided build looks like and then I demonstrate that my build works (mostly) fine

    example.webm

    You can see where redraws were needed under src/ui/LiveSplit.tsx and src/ui/LayoutEditor.tsx everywhere where I called the forceResize method.
    https://github.com/SaveThePolarBearz/LiveSplitOne

  5. CryZe commented on Mar 14, 2025

    @CryZe
    Collaborator

    Yeah so resizing it is expected to work around the problem, as that forces the entire layout to be redrawn. In most frames however the intention is that we don't redraw the content, which seems to work just fine everywhere except with WebKit on Linux. If it's the context lost event, then we can listen to it, but I would need someone to confirm that.

  6. pi3n4t commented on Jul 9, 2025

    @pi3n4t

    Hey, I might be doing something wrong or it's not the "contextlost" event, but I cannot get the canvas to log anything.
    First I get the reference to the (hopefully correct canvas) via the graphics tab:

    Image

    Then I add the event listener to the canvas:
    $1.canvas.addEventListener("contextlost", (event) => { console.log(event); });

    Then I reproduce the error but do not get any logging:

    Image

    Even when I use the function monitorEvents($1); I do not get any logging from the canvas at all. Not even mouse events.
    If you have any idea what I might be doing wrong I can debug further.

    My System, should it help:
    Operating System: EndeavourOS
    KDE Plasma Version: 6.4.2
    KDE Frameworks Version: 6.15.0
    Qt Version: 6.9.1
    Kernel Version: 6.15.5-arch1-1 (64-bit)
    Graphics Platform: Wayland
    Processors: 32 × AMD Ryzen 9 5950X 16-Core Processor
    Memory: 32 GiB of RAM (31,3 GiB usable)
    Graphics Processor: AMD Radeon RX 9070 XT
    System Version: 2.0

  7. CryZe commented on Jul 9, 2025

    @CryZe
    Collaborator

    I debugged this a while ago and it's indeed not the contextlost event and instead a bug in WebKitGTK where it apparently doesn't track the dirty regions of the window properly.

  8. cD1rtX3 commented on Aug 21, 2025

    @cD1rtX3

    Segments actually disappear a lot. Along with the timer. For simple things like opening the settings window.

    Ubuntu 24.04.2 LTS with GNOME 48 on X11

  9. ggtylerr commented on Jan 28, 2026

    @ggtylerr

    As a temporary solution, if you use OBS you can install the LiveSplitOne plugin which doesn't have this bug. Just need to setup global hotkeys if you use Wayland.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    TauriAn issue about the Tauri based desktop version.WebKitAn issue that affects the WebKit engine (used by Safari and Tauri on Linux)layout renderingThis affects the rendering of LiveSplit layouts.requires livesplit-core changesThere's a bug or missing feature in livesplit-core that needs to be implemented.

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions