diff --git a/config.h b/config.h index c86daa3d..278589b3 100644 --- a/config.h +++ b/config.h @@ -167,7 +167,7 @@ static unsigned int rows = 24; /* * Default colour and shape of the mouse cursor */ -static unsigned int mouseshape = XC_xterm; +static const char *mouseshape = "xterm"; static unsigned int mousefg = 7; static unsigned int mousebg = 0; diff --git a/config.mk b/config.mk index ef6de394..3bb1e010 100644 --- a/config.mk +++ b/config.mk @@ -17,7 +17,7 @@ INCS = -I$(X11INC) \ `$(PKG_CONFIG) --cflags fontconfig` \ `$(PKG_CONFIG) --cflags freetype2` \ `$(PKG_CONFIG) --cflags harfbuzz` -LIBS = -L$(X11LIB) -lm -lrt -lX11 -lutil -lXft -lXrender\ +LIBS = -L$(X11LIB) -lm -lrt -lX11 -lutil -lXft -lXrender -lXcursor\ `$(PKG_CONFIG) --libs fontconfig` \ `$(PKG_CONFIG) --libs freetype2` \ `$(PKG_CONFIG) --libs harfbuzz` diff --git a/x.c b/x.c index 0a92fcc1..b3b33299 100644 --- a/x.c +++ b/x.c @@ -10,11 +10,11 @@ #include #include #include -#include #include #include #include #include +#include char *argv0; #include "arg.h" @@ -1353,7 +1353,7 @@ xinit(int cols, int rows) } /* white cursor, black outline */ - cursor = XCreateFontCursor(xw.dpy, mouseshape); + cursor = XcursorLibraryLoadCursor(xw.dpy, mouseshape); XDefineCursor(xw.dpy, xw.win, cursor); if (XParseColor(xw.dpy, xw.cmap, colorname[mousefg], &xmousefg) == 0) {