[Top][All Lists]

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

Re: New special-mode parent

From: Dan Nicolaescu
Subject: Re: New special-mode parent
Date: Fri, 13 Jun 2008 11:25:18 -0700

Stefan Monnier <address@hidden> writes:

  > While thinking about the key-binding problems we have in vc-annotate it
  > occurred to me that it should use a view-mode minor mode, but rather it
  > should inherit from a sort of view-mode major mode, so it can override
  > its key-bindings.  And it occurred to me that it should be called
  > `special-mode' and should probably be used by most "special" major modes
  > (those that set the mode-class property to `special').
  > So I'm considering adding to subr.el a simple parent major mode:

  >    (defvar special-mode-map
  >      (let ((map (make-sparse-keymap)))
  >        (suppress-keymap map)
  >        (define-key map "q" 'quit-window)
  >        (define-key map " " 'scroll-up)
  >        (define-key map "\C-?" 'scroll-down)
  >        (define-key map "?" 'describe-mode)

This one does not seem that useful

  >        (define-key map ">" 'end-of-buffer)
  >        (define-key map "<" 'beginning-of-buffer)
  >        (define-key map "g" 'revert-buffer)

or this one

  > Any comment?

IMO, good idea in genearal.

How about having an even more minimalistic version of this turned on
even for read-only files?

reply via email to

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