emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

x-backspace-delete-keys-p without XKB support


From: Dan Nicolaescu
Subject: x-backspace-delete-keys-p without XKB support
Date: Sun, 18 Dec 2005 16:34:18 -0800

x-backspace-delete-keys-p returns nil when the XKB extension is not in
use at run time, or when emacs was compiled without XKB support.
The effect is that both [backspace] and [delete] will delete
backwards. 

I sometime use a sparc-sun-solaris2.7 machine that does not have
XKB. Also I am told that most MS Windows X11 servers do not support
XKB.

Given that the condition that x-backspace-delete-keys-p is quite odd,
and probably unlikely to happen, it is better in the case that we
don't have enough information (because XKB is not supported at
either run time or compile time) to return t. The result is that
[backspace] would delete backwards and [delete] forwards. 

May I install this patch:

Index: xfns.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/xfns.c,v
retrieving revision 1.652
diff -c -3 -p -c -r1.652 xfns.c
*** xfns.c      14 Dec 2005 20:58:33 -0000      1.652
--- xfns.c      19 Dec 2005 00:19:48 -0000
*************** usual X keysyms.  */)
*** 5541,5547 ****
    if (!XkbLibraryVersion (&major, &minor))
      {
        UNBLOCK_INPUT;
!       return Qnil;
      }
  
    /* Check that the server supports XKB.  */
--- 5541,5547 ----
    if (!XkbLibraryVersion (&major, &minor))
      {
        UNBLOCK_INPUT;
!       return Qt;
      }
  
    /* Check that the server supports XKB.  */
*************** usual X keysyms.  */)
*** 5550,5556 ****
    if (!XkbQueryExtension (dpy, &op, &event, &error, &major, &minor))
      {
        UNBLOCK_INPUT;
!       return Qnil;
      }
  
    /* In this code we check that the keyboard has physical keys with names
--- 5550,5556 ----
    if (!XkbQueryExtension (dpy, &op, &event, &error, &major, &minor))
      {
        UNBLOCK_INPUT;
!       return Qt;
      }
  
    /* In this code we check that the keyboard has physical keys with names
*************** usual X keysyms.  */)
*** 5605,5611 ****
    UNBLOCK_INPUT;
    return have_keys;
  #else /* not HAVE_XKBGETKEYBOARD */
!   return Qnil;
  #endif /* not HAVE_XKBGETKEYBOARD */
  }
  
--- 5605,5611 ----
    UNBLOCK_INPUT;
    return have_keys;
  #else /* not HAVE_XKBGETKEYBOARD */
!   return Qt;
  #endif /* not HAVE_XKBGETKEYBOARD */
  }
  




reply via email to

[Prev in Thread] Current Thread [Next in Thread]