Path: utzoo!attcan!uunet!husc6!bloom-beacon!ATHENA.MIT.EDU!swick From: swick@ATHENA.MIT.EDU (Ralph R. Swick) Newsgroups: comp.windows.x Subject: Re: Changing X default cursor Message-ID: <8809161409.AA02487@LYRE.MIT.EDU> Date: 16 Sep 88 14:09:10 GMT References: <159@leibniz.UUCP> Sender: daemon@bloom-beacon.MIT.EDU Organization: DEC/MIT Project Athena Lines: 16 Changing the default cursorfont is NOT the way to do it. If your favorite cursor is in a bitmap(1) file, you can use xsetroot -cursor to change it. Otherwise, you can adapt the following to your needs: #include #include main() { Display *dpy = XOpenDisplay(""); unsigned long mask = CWCursor; XSetWindowAttributes attr; attr.cursor = XCreateFontCursor(dpy, XC_hand2); XChangeWindowAttributes(dpy, DefaultRootWindow(dpy), mask, &attr); XCloseDisplay(dpy); }