Hyprland: mouse cursor doesn't show on external display

I’ve just installed hyprland on my machine and it works nicely in general, but I can’t see mouse cursor on my external monitor. The built-in screen works just fine, but as soon as I move the cursor onto the other display it disappears, though I can still click things (e.g. hyperlinks in browser get underlined and when I press my left mouse button at that moment, the browser follows the link despite lack of the visual representation of the cursor).

I’ve spent some time in hyprland docs and FAQ, but can’t see anything. Maybe anyone has gone through a similar issue?

Executing echo $WLR_NO_HARDWARE_CURSORS yields 1. I use a laptop with NVidia optimus card.

The entire configuration (if needed) is here: https://github.com/bratfizyk/dotFiles/tree/hypr

Let me answer my own question :).

I’ve changed a lot of things, but I think what solved the issue was moving the declaration of the WLR_NO_HARDWARE_CURSORS variable to another place.

When posting this question it was defined in home.sessionVariables. I moved it to hyprland configuration:

  wayland.windowManager.hyprland = {
    enable = true;
    # ...
    settings = {
        # ...
        env = [
          "LIBVA_DRIVER_NAME,nvidia"
          "XDG_SESSION_TYPE,wayland"
          "WLR_NO_HARDWARE_CURSORS,1"
        ];
    };
1 Like