all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Whitfield Diffie <whitfield.diffie@gmail.com>, help-gnu-emacs@gnu.org
Subject: RE: Different key maps in different dired buffers
Date: Thu, 26 May 2016 07:03:16 -0700 (PDT)	[thread overview]
Message-ID: <4159df5c-3545-4c5a-829f-abc80f620813@default> (raw)
In-Reply-To: <CAF+O-CVto9o7ybfghRz7xKp0CmuK9dnd-VXvWtL3mzC7Joe60g@mail.gmail.com>

> The function local-set-key seems to be local to major mode, not
> local to an individual buffer.  Can anyone tell me how to set keys to
> special functions in only some dired buffers?

In addition to what others have said, which answers your question,
I'd ask what you really want to do.

In particular, are you trying to do something different for a given
class (subset, kind) of Dired buffers, or just arbitrary different
Dired buffers.  If the former, then consider defining a submode,
i.e., a mode that inherits from Dired mode but has its own keymap
and possibly does things a bit differently.  You can do this with
a major mode or a minor mode.

But if there is no way to recognize a Dired buffer that you might
want to have different key bindings for, then this approach would
not apply.  In that case, the Dired buffers you want to do this
in/for are, in effect, arbitrary.



  parent reply	other threads:[~2016-05-26 14:03 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-26  8:14 Different key maps in different dired buffers Whitfield Diffie
2016-05-26  9:06 ` tomas
2016-05-26 12:25   ` Stefan Monnier
2016-05-26 12:37     ` tomas
2016-05-26 14:03 ` Drew Adams [this message]
2016-05-26 15:05   ` Whitfield Diffie
2016-05-26 15:24     ` Drew Adams
2016-05-26 17:46     ` Dmitry Alexandrov
2016-05-26 17:59       ` Whitfield Diffie
2016-05-26 18:05         ` Drew Adams
2016-05-27  7:09           ` Reply to list [was: Different key maps in different dired buffers] tomas
2016-05-27  8:02             ` Eli Zaretskii
2016-05-27 16:46               ` Glenn Morris
2016-05-27 18:44                 ` Eli Zaretskii
2016-06-03 23:38                   ` Bob Proulx
     [not found]                   ` <mailman.787.1464997128.1216.help-gnu-emacs@gnu.org>
2016-06-04  1:40                     ` Emanuel Berg
2016-06-04  2:12                       ` Bob Proulx
     [not found]                       ` <mailman.789.1465006376.1216.help-gnu-emacs@gnu.org>
2016-06-04  2:51                         ` Emanuel Berg
2016-06-04 15:52                           ` Dmitry Alexandrov
2016-06-04 19:41                             ` Bob Proulx
2016-06-04 19:48                               ` Emanuel Berg
2016-06-06  2:57                                 ` Bob Proulx
     [not found]                                 ` <mailman.953.1465181882.1216.help-gnu-emacs@gnu.org>
2016-06-06  3:11                                   ` Emanuel Berg
2016-06-04 20:05                               ` Stefan Monnier
2016-06-05 10:28                                 ` Dmitry Alexandrov
     [not found]                             ` <mailman.857.1465069271.1216.help-gnu-emacs@gnu.org>
2016-06-05 12:44                               ` Dmitry Alexandrov
2016-06-05 13:35                                 ` Dmitry Alexandrov
2016-06-06  3:29                                   ` Bob Proulx
2016-06-08 11:43                                     ` Dmitry Alexandrov
2016-06-09 23:35                                       ` Emanuel Berg
2016-06-16  0:45                                       ` Bob Proulx
     [not found]                                       ` <mailman.1575.1466037955.1216.help-gnu-emacs@gnu.org>
2016-06-16  5:24                                         ` Emanuel Berg
     [not found]                                   ` <mailman.955.1465183780.1216.help-gnu-emacs@gnu.org>
2016-06-06  6:20                                     ` Emanuel Berg
2016-06-06 22:03                                       ` Bob Proulx
     [not found]                                       ` <mailman.1023.1465250629.1216.help-gnu-emacs@gnu.org>
2016-06-06 22:55                                         ` Emanuel Berg
2016-06-04 17:30                           ` Bob Proulx
     [not found]                           ` <mailman.837.1465055573.1216.help-gnu-emacs@gnu.org>
2016-06-04 18:35                             ` Emanuel Berg
2016-06-05 11:00                               ` Dmitry Alexandrov
     [not found]                               ` <mailman.895.1465124454.1216.help-gnu-emacs@gnu.org>
2016-06-05 23:29                                 ` Emanuel Berg
     [not found]                           ` <mailman.850.1465061448.1216.help-gnu-emacs@gnu.org>
2016-06-04 19:04                             ` Emanuel Berg
2016-05-27 11:42             ` Whitfield Diffie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4159df5c-3545-4c5a-829f-abc80f620813@default \
    --to=drew.adams@oracle.com \
    --cc=help-gnu-emacs@gnu.org \
    --cc=whitfield.diffie@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.