From:	CRDGW2::CRDGW2::MRGATE::"SMTP::CRVAX.SRI.COM::RELAY-INFO-VAX"  4-AUG-1989 04:26
To:	MRGATE::"ARISIA::EVERHART"
Subj:	Re: DECW$CURSOR cursors

Received: From KL.SRI.COM by CRVAX.SRI.COM with TCP; Fri,  4 AUG 89 00:48:23 PDT
Received: from ucbvax.Berkeley.EDU by KL.SRI.COM with TCP; Fri, 4 Aug 89 00:46:18 PDT
Received: by ucbvax.Berkeley.EDU (5.61/1.37)
	id AA28627; Fri, 4 Aug 89 00:41:22 -0700
Received: from USENET by ucbvax.Berkeley.EDU with netnews
	for info-vax@kl.sri.com (info-vax@kl.sri.com)
	(contact usenet@ucbvax.Berkeley.EDU if you have questions)
Date: 4 Aug 89 01:56:18 GMT
From: uhccux!munnari.oz.au!otc!metro!basser!usage!decus!taylort@ames.arc.nasa.gov  (Trevor Taylor)
Organization: DECUS, South Pacific Chapter
Subject: Re: DECW$CURSOR cursors
Message-Id: <507@decus.com.au>
References: <2730@quanta.eng.ohio-state.edu>
Sender: info-vax-request@kl.sri.com
To: info-vax@kl.sri.com

In article <2730@quanta.eng.ohio-state.edu>, DAVISM@kcgl1.eng.ohio-state.edu (Michael T. Davis) writes:
> 	How do you set the cursor for a window to be one of the shapes defined
> in SYS$LIBRARY:DECW$CURSOR.H?  Or more precisely, how do you get the Cursor
> ID?  Using XCreateFontCursor retrieves the desired ID from the cursorfont font,
> which is apparently not the same font used for the shapes in DECW$CURSOR.H.
> 
> 
Try the following (abridged) code:

#include <DECW$CURSOR.H>

Cursor wait_cursor;
Font cursor_font;
Display *dpy;

    ...

    dpy = XtDisplay(mainwidget);
    cursor_font = XLoadFont(dpy, "DECW$CURSOR");
    wait_cursor = XCreateGlyphCursor(dpy,
			cursor_font,
			cursor_font,
			decw$c_wait_cursor,
			decw$c_wait_cursor+1,
			foreground,
			background);

    /* When required ... */
    XDefineCursor(dpy, XtWindow(mainwidget), wait_cursor);


	Trevor		

