[387] in Athena Bugs

home help back first fref pref prev next nref lref last post

RT 6.0A: X11 cursorfont bug

daemon@ATHENA.MIT.EDU (csmith@ATHENA.MIT.EDU)
Wed May 18 00:37:30 1988

From: <csmith@ATHENA.MIT.EDU>
Date: Wed, 18 May 88 00:36:55 EDT
To: bugs@ATHENA.MIT.EDU

(On ODIE.MIT.EDU)

About one out of every five of the cursors in the "cursor" font do not
show up properly (usually they don't show up at all) when used as the
cursor for a window.  The following section of code demonstrates this:

------------------------------------------------------------------------------

#include <X11/Xlib.h>
#include <X11/cursorfont.h>

main()
{
	Display *d;
	Window w;
	Cursor mycursor;
	int cursornumber;

	d = XOpenDisplay("");
	w = XCreateSimpleWindow(d,RootWindow(d,0),0,0,100,100,3,
			BlackPixel(d,0),WhitePixel(d,0));
	XMapWindow(d,w);
	XFlush(d);	
	sleep(5);

	for (cursornumber = 0;cursornumber < XC_num_glyphs;cursornumber += 2) {
	    mycursor = XCreateFontCursor(d, cursornumber);
	    XDefineCursor(d,w,mycursor);
	    XFlush(d);
	    printf("%d\n",cursornumber);
	    sleep(1);
	}
}


home help back first fref pref prev next nref lref last post