From mboxrd@z Thu Jan 1 00:00:00 1970 Path: quimby.gnus.org!not-for-mail From: "Stefan Monnier" Newsgroups: gmane.emacs.devel Subject: Re: "Overwrite" toggle in the Edit menu Date: Mon, 11 Feb 2002 19:43:22 -0500 Message-ID: <200202120043.g1C0hNa04532@rum.cs.yale.edu> References: <1190-Sat09Feb2002164320+0200-eliz@is.elta.co.il> <5xr8ntrugh.fsf@kfs2.cua.dk> <200202111847.g1BIlxB06888@aztec.santafe.edu> <5xy9hzh8bj.fsf@kfs2.cua.dk> NNTP-Posting-Host: quimby2.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: quimby2.netfonds.no 1013475341 6295 195.204.10.66 (12 Feb 2002 00:55:41 GMT) X-Complaints-To: usenet@quimby2.netfonds.no NNTP-Posting-Date: 12 Feb 2002 00:55:41 GMT Cc: rms@gnu.org, emacs-devel@gnu.org Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby2.netfonds.no with esmtp (Exim 3.12 #1 (Debian)) id 16aRES-0001dR-00 for ; Tue, 12 Feb 2002 01:55:40 +0100 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian)) id 16aR4I-00018o-00; Mon, 11 Feb 2002 19:45:10 -0500 Original-Received: from rum.cs.yale.edu ([128.36.229.169]) by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian)) id 16aR2f-000142-00; Mon, 11 Feb 2002 19:43:29 -0500 Original-Received: (from monnier@localhost) by rum.cs.yale.edu (8.11.6/8.11.6) id g1C0hNa04532; Mon, 11 Feb 2002 19:43:23 -0500 X-Mailer: exmh version 2.4 06/23/2000 with nmh-1.0.4 Original-To: storm@cua.dk (Kim F. Storm) Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.5 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: quimby.gnus.org gmane.emacs.devel:1017 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:1017 > Richard Stallman writes: > > > I noticed this a week ago and started implementing a new feature > > to make it work reliably. It almost works, but has a strange bug: > > the mouse menu completely stopped working. > > > Here are the changes. Can anyone debug this problem? > > Could it be that in the new code below, mode-line-minor-mode-keymap > is used literally (as a symbol) rather than its value ? > > > (setq-default mode-line-modes > > (list > > (propertize " %[(" 'help-echo help-echo) > > ! '(:propertize ("" mode-name mode-line-process minor-mode-alist) > > ! help-echo "mouse-3: minor mode menu" > > ! local-map mode-line-minor-mode-keymap) > > (propertize "%n" 'help-echo "mouse-2: widen" > > 'local-map (make-mode-line-mouse-map > > 'mouse-2 #'mode-line-widen)) > > In the old code, its value was used through this function: > > > - (defun mode-line-mode-name () "\ > > - Return a string to display in the mode line for the current mode name." > > - (when (stringp mode-name) > > - (if (equal mode-name mode-line-copied-mode-name) > > - mode-line-copied-mode-name > > - (setq mode-line-copied-mode-name > > - (propertize mode-name > > - 'local-map mode-line-minor-mode-keymap > > - 'help-echo "mouse-3: minor mode menu")))) > > - mode-line-copied-mode-name) > > - > > Maybe something like this will work: > > (setq-default mode-line-modes > (list > (propertize " %[(" 'help-echo help-echo) > `(:propertize ("" mode-name mode-line-process minor-mode-alist) > help-echo "mouse-3: minor mode menu" > local-map ,mode-line-minor-mode-keymap) > (propertize "%n" 'help-echo "mouse-2: widen" > 'local-map (make-mode-line-mouse-map > 'mouse-2 #'mode-line-widen)) Or just (fset 'mode-line-minor-mode-keymap mode-line-minor-mode-keymap) -- Stefan _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://mail.gnu.org/mailman/listinfo/emacs-devel