From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Glenn Morris Newsgroups: gmane.emacs.bugs Subject: bug#13777: [patch] Add toolbars for Edebug and debugger-mode Date: Wed, 08 May 2013 03:50:35 -0400 Message-ID: References: <20130221184913.101bd49379994f15f3156829@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1367999465 31863 80.91.229.3 (8 May 2013 07:51:05 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 8 May 2013 07:51:05 +0000 (UTC) Cc: 13777@debbugs.gnu.org To: Xue Fuqiao Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed May 08 09:51:03 2013 Return-path: Envelope-to: geb-bug-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 1UZz9R-0007FP-Rz for geb-bug-gnu-emacs@m.gmane.org; Wed, 08 May 2013 09:51:01 +0200 Original-Received: from localhost ([::1]:36768 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UZz9R-0007Q5-Ig for geb-bug-gnu-emacs@m.gmane.org; Wed, 08 May 2013 03:51:01 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:54865) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UZz9N-0007Pw-Ef for bug-gnu-emacs@gnu.org; Wed, 08 May 2013 03:50:58 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UZz9M-00025i-7H for bug-gnu-emacs@gnu.org; Wed, 08 May 2013 03:50:57 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:57667) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UZz9L-00025c-VA for bug-gnu-emacs@gnu.org; Wed, 08 May 2013 03:50:56 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1UZzAQ-0002eN-Br for bug-gnu-emacs@gnu.org; Wed, 08 May 2013 03:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Glenn Morris Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 08 May 2013 07:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13777 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 13777-submit@debbugs.gnu.org id=B13777.136799950910139 (code B ref 13777); Wed, 08 May 2013 07:52:02 +0000 Original-Received: (at 13777) by debbugs.gnu.org; 8 May 2013 07:51:49 +0000 Original-Received: from localhost ([127.0.0.1]:33543 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UZzAA-0002dP-Gd for submit@debbugs.gnu.org; Wed, 08 May 2013 03:51:48 -0400 Original-Received: from fencepost.gnu.org ([208.118.235.10]:46793) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UZzA7-0002dB-BW for 13777@debbugs.gnu.org; Wed, 08 May 2013 03:51:44 -0400 Original-Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1UZz91-0003b0-4d; Wed, 08 May 2013 03:50:35 -0400 X-Spook: president MD2 ASIO Merlin Leuken-Baden jihad Al-Qaeda X-Ran: ?f!{[v*l8iViFSNO2@\:;\,* X-Hue: blue X-Attribution: GM In-Reply-To: <20130221184913.101bd49379994f15f3156829@gmail.com> (Xue Fuqiao's message of "Thu, 21 Feb 2013 18:49:13 +0800") User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:74074 Archived-At: Thanks for the patches. Xue Fuqiao wrote: > *** trunk/lisp/emacs-lisp/edebug.el.orig 2013-02-03 > 09:46:50.383143000 +0800 > --- trunk/lisp/emacs-lisp/edebug.el 2013-02-21 > 18:10:30.220096536 +0800 *************** be installed in > `emacs-lisp-mode-map'.") *** 3727,3732 **** > --- 3727,3745 ---- (These patches seem mangled somehow?) > + (defvar edebug-tool-bar-map > + (let ((map (make-sparse-keymap))) > + (dolist (x '((edebug-set-breakpoint . "gud/break") > + (edebug-unset-breakpoint . "gud/remove") > + (edebug-go-mode . "gud/go") > + (edebug-stop . "gud/stop") > + (edebug-continue-mode . "gud/cont") > + (edebug-next-mode . "gud/next") > + (edebug-step-mode . "gud/step")) > + map) > + (tool-bar-local-item-from-menu > + (car x) (cdr x) map edebug-mode-map)))) Looks alright but: i) I think this needs to be moved after the easy-menu-define call. ii) You need to find a way to restore the normal tool-bar after edebug exits (for whatever reason). > + (defvar debugger-tool-bar-map > + (let ((map (make-sparse-keymap))) > + (dolist (x '((debugger-continue . "gud/cont") > + (debugger-step-through . "gud/step")) > + map) > + (tool-bar-local-item-from-menu > + (car x) (cdr x) map debugger-mode-map)))) Looks ok, but it's a very sparse tool-bar. Is there nothing more that can go in it? It looks a bit silly with just 2 items... Maybe keep some of the standard ones?