From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Whitfield Diffie Newsgroups: gmane.emacs.help Subject: Re: Different key maps in different dired buffers Date: Thu, 26 May 2016 08:05:33 -0700 Message-ID: References: <4159df5c-3545-4c5a-829f-abc80f620813@default> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1464275436 4174 80.91.229.3 (26 May 2016 15:10:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 26 May 2016 15:10:36 +0000 (UTC) Cc: "help-gnu-emacs@gnu.org" To: Drew Adams Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu May 26 17:10:36 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1b5wvj-0001X0-GF for geh-help-gnu-emacs@m.gmane.org; Thu, 26 May 2016 17:10:35 +0200 Original-Received: from localhost ([::1]:38864 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5wvi-0003b1-LR for geh-help-gnu-emacs@m.gmane.org; Thu, 26 May 2016 11:10:34 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54471) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5wqt-0008QQ-7Z for help-gnu-emacs@gnu.org; Thu, 26 May 2016 11:05:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b5wqr-00087o-Tg for help-gnu-emacs@gnu.org; Thu, 26 May 2016 11:05:34 -0400 Original-Received: from mail-qg0-x22a.google.com ([2607:f8b0:400d:c04::22a]:36800) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5wqr-00087a-M4 for help-gnu-emacs@gnu.org; Thu, 26 May 2016 11:05:33 -0400 Original-Received: by mail-qg0-x22a.google.com with SMTP id q32so38425622qgq.3 for ; Thu, 26 May 2016 08:05:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc; bh=0AFtyVsIGFuRw3q0/zXet+6eKui0gajiy1Oxz7dP7nE=; b=PtqOw2AroyUyLXyJGHF2s2tEWwbSaSTLzIkEVgW0HY7vjOh/KjUEtFj/XoIOgk10hj wSLfpdzVChNxT9QQ/ZFuAT41yu3U1Gg6KMLkPJUPKnkwg2kckWeSj+zGihgiwb6sXveF 0Fhxq6r0/7rKDezJtAOo0/XzryBgICVIjDVOmlNsRpCro2Syy8UY4wr/0S27UuSawylf Pq47RXQQzb/O9FanKfguY+TIqOa0XfptkFV/ib0MQg1uAAhBK2OQ13Aap+oT8eu0Gz1c ip1INCEUfyOBhi6JBbnHcHrqutVuTY3qxyrm+IQZkGO8y5XriqJA2+4MEmmr8sQdkL1d Xjdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc; bh=0AFtyVsIGFuRw3q0/zXet+6eKui0gajiy1Oxz7dP7nE=; b=EsW/uBVjwgm7KCIOZ5P3DHhi8JpRRN4zrFhtmTLNEMT4Frk1D1lrleIUk0TWh4TR8C FHUOHiltB2DjP5YoZxuxYGfWAB5oVXzWvy/tIoiib5DXQyoA6u7ECnMzH4BxzgZTvEuA KW1/6u3+BiwRlfxi7ifyNgSMrePZVrzzdSopFc8CVZH0eqI6ImEbr9BRl9k2duPKbaT5 ccNepTBHydzdVWCphEvvaeUloxR5A5ypJXwSIpDY/JeVPodPlhB3tvWYaboxA33J9JnE +xxuxduWUeeIQuT7qYCzYQ44CpZi9dXZkKWHsp8B6UCNzN5gsVW9BMvbphhmH10BqL+X ka8g== X-Gm-Message-State: ALyK8tKCBaCuzdexUdGhH2oWTHwXGlO2xaQRQiRvY8vFQsS3XKGkWVflfofFjcSDqJqpbJ0aZ6JwKrRLjkbqeQ== X-Received: by 10.140.142.136 with SMTP id 130mr9615345qho.64.1464275133155; Thu, 26 May 2016 08:05:33 -0700 (PDT) Original-Received: by 10.55.3.10 with HTTP; Thu, 26 May 2016 08:05:33 -0700 (PDT) In-Reply-To: <4159df5c-3545-4c5a-829f-abc80f620813@default> X-Google-Sender-Auth: Da8_tIdhEa8xKbqb7de0t4hyuPE X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2607:f8b0:400d:c04::22a X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:110124 Archived-At: > In addition to what others have said, which answers your question, > I'd ask what you really want to do. I haven't seen anyone else say anything; did you see other responses that I have somehow not received. > In particular, are you trying to do something different for a given > class (subset, kind) of Dired buffers, or just arbitrary different > Dired buffers. Both, but in the case at hand, it was the former and you question reveals an embarrassment of what I am doing in that the changes in behavior of characters are just a means to doing something else. I have rewritten dired to have a dozen or more changes of behavior, set by switches. (If you are interested in this code, you are welcome to it. It is very variable in quality and is not adequately documented.) One of these is the switch dired-directories-at-top, with the obvious meaning. My calendar consists of a directory of years, which are directories of days. Each day is a directory of events whose names begin with the times. Some of these are plain files; some are directories. In the day directories, I don't want to put the directories at the top. I though I could achieve this adequately (yes, it is a gross hack and not what is really needed) by redefining ``f'' to be a function called dired-find-file-in-future-dir. I then found that ``f'' took on this meaning in every dired buffer. I have other cases in which I have written a function that changes the way a directory is displayed (for example comparing file names numerically rather than as strings) as well as changing the functions of some characters. Probably the general form of my question is how to put a dired buffer in a mode that does not become the mode of all dired buffers. I have not explored minor modes and I have don't think I know the notion of a submode; that word does suggest the right thing. Thank you very much for replying. I have found the responses of this list very variable. I have asked questions that are more interesting, more subtle, and less ignorant than this one, and been met with silence. Whit