diff --git a/configure.ac b/configure.ac index 62f53a3..a6f2f04 100644 --- a/configure.ac +++ b/configure.ac @@ -1874,6 +1874,7 @@ if test "${HAVE_X11}" = "yes"; then AC_MSG_RESULT($emacs_xkb) if test $emacs_xkb = yes; then AC_DEFINE(HAVE_XKBGETKEYBOARD, 1, [Define to 1 if you have the XkbGetKeyboard function.]) + AC_DEFINE(HAVE_XKB, 1, [Define to 1 if you have the Xkb extension.]) fi AC_CHECK_FUNCS(XrmSetDatabase XScreenResourceString \ diff --git a/src/xterm.c b/src/xterm.c index fb407c8..102ce43 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -130,6 +130,10 @@ extern void _XEditResCheckMessages (Widget, XtPointer, XEvent *, Boolean *); #include "bitmaps/gray.xbm" +#ifdef HAVE_XKB +#include +#endif + /* Default to using XIM if available. */ #ifdef USE_XIM int use_xim = 1; @@ -3243,7 +3247,11 @@ XTring_bell (struct frame *f) else { block_input (); +#ifdef HAVE_XKB + XkbBell (FRAME_X_DISPLAY (f), None, 0, None); +#else XBell (FRAME_X_DISPLAY (f), 0); +#endif XFlush (FRAME_X_DISPLAY (f)); unblock_input (); }