9

Can I remove the mouse pointer entirely from X? As in removing it and not just hiding it?

I don't use the mouse at all. Everything I do is completely keyboard driven, so I hide the mouse pointer and disable my touchpad. However, the cursor still has a position on my screen, which causes applications to fire hover events.

This can be extremely annoying, for instance in chrome, if a link happens to intersect the cursor it will display a bright white tooltip in the bottom left of the window.

6
  • Wouldn't it be enough to move the pointer to a non-annoying location (e.g. one of the screen corners)? Commented Feb 22, 2017 at 22:20
  • @Gilles I am using a tiling window manager, so I am always using the entire screen such that every point on my screen is inside some window. If however I could move the cursor to a point outside my screen, that would work
    – BlackCap
    Commented Feb 22, 2017 at 22:31
  • Just disable the pointer driver from xorg.conf then? Commented Feb 23, 2017 at 9:27
  • The core pointer is so deeply ingrained into X that I don't think it can be completely disabled. Would disconnecting all devices that move it around, and then moving it outside the visible screen space (e.g. with xte or xdotool) be acceptable?
    – dirkt
    Commented Feb 23, 2017 at 20:32
  • @dirkt Absolutely, however, I cannot move it outside the screen with xdotool. xdotool mousemove 10000 10000 moves the cursor to the bottom right corner of my screen rather than outside, and it does not accept negative numbers.
    – BlackCap
    Commented Feb 24, 2017 at 21:54

1 Answer 1

4

Configure your X session to start with the argument -nocursor. For example:

exec /usr/bin/X -nocursor -nolisten tcp "$@"
11
  • 2
    -nocursor seems to only hide the cursor. It can still be moved around, clicked, and more importantly- trigger hover events
    – BlackCap
    Commented Feb 22, 2017 at 20:37
  • 1
    Hmm, not good. What window manager / desktop environment do you use? Does your distribution have the unclutter program?
    – airhuff
    Commented Feb 22, 2017 at 20:43
  • 2
    unclutter may not be what you want though. From the Arch Linux wiki: "Unclutter hides your X mouse cursor when you do not need it, to prevent it from getting in the way. You have only to move the mouse to restore the mouse cursor. Unclutter is very useful in tiling window managers where you do not need the mouse often. "
    – airhuff
    Commented Feb 22, 2017 at 20:46
  • 2
    Never mind, finally found it here.
    – 17xande
    Commented Oct 17, 2017 at 13:55
  • 1
    After uninstalling the entirety of gnome, suddenly -nocursor works, which is odd because I remember testing this with startx. I suppose something overloaded it.
    – BlackCap
    Commented May 31, 2018 at 19:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .