Hiding the X cursor?
Peter Hutterer
peter.hutterer at who-t.net
Tue Jul 14 18:38:28 PDT 2009
On Tue, Jul 14, 2009 at 01:37:21PM -0700, Tyler McClung wrote:
> It seems I came in a little too late to reply on the old thread, but
> that's fine.
>
> I'm attempting to (temporarily) hide the cursor in an embedded system
> running matchbox-window-manager. I am able to hide the mouse for all
> newly opened windows, but old windows do not change. I do not want to
> restart the wm for the changes to be global. Here are the things I've
> tried:
>
> 1. Apply an invisible mouse theme via matchbox-remote -theme
> Fail: Did not change anything
>
> 2. Configure/change default icon file to point to xcursor-transparent
> Fail: Works for new windows + root, but not for old windows (works if
> wm is restarted)
>
> 3. Send events to matchbox-window-manager by rewriting the source
> code for the wm as well as matchbox-remote.
> Fail: Does the same thing as attempt 2.
>
> I believe the reason why 2 and 3 do not work is matchbox or X
> maintains a cache of the applied cursors for each window that is open
> and does not mess with the cache for windows that are already open. I
> am unsure if this is how it really works, but I am having trouble
> changing the old windows.
>
> Is there a way to hide the cursor on the fly without restarting the
> server or window manager?
>
> If you're wondering why, I'm attempting to write a little program to
> toggle the view of the cursor on the system because the user may want
> to use the touchscreen, the touchpad, or a mouse; plus some programs
> would be cooler without the cursor.
>
shouldn't XFixesHideCursor and XFixesShowCursor do the job?
(disclaimer: haven't actually used it)
Cheers,
Peter
More information about the xorg
mailing list