Subject: bug#79323: 30.2; Control-X-prefix not remapable

From: Howard Melman <[email-masked]>
Date: Sat, 30 Aug 2025 23:50:27 -0400

Juri Linkov <[email-masked]> writes:

> +(defun tab-line--undefine-keys ()
> +  "Uninstall key bindings previously bound by `tab-line--define-keys'."
> +  (when tab-line-define-keys
> +    (define-key ctl-x-map [left] 'previous-buffer)
> +    (define-key ctl-x-map [C-left] 'previous-buffer)
> +    (define-key ctl-x-map [M-left] nil)
> +    (define-key ctl-x-map [right] 'next-buffer)
> +    (define-key ctl-x-map [C-right] 'next-buffer)
> +    (define-key ctl-x-map [M-right] 'next-buffer)))

I didn't check this, but could you do this instead? 
(I use this form of define-keymap in other cases.)

(defun tab-line--undefine-keys ()
  "Uninstall key bindings previously bound by `tab-line--define-keys'."
  (when tab-line-define-keys
    (define-keymap :keymap ctl-x-map
      [left] 'previous-buffer
      [C-left] 'previous-buffer
      [M-left] nil
      [right] 'next-buffer
      [C-right] 'next-buffer
      [M-right] 'next-buffer)))

-- 

Howard