bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#4550: 23.1; give users a choice for quitting backtrace buffer


From: Drew Adams
Subject: bug#4550: 23.1; give users a choice for quitting backtrace buffer
Date: Thu, 24 Sep 2009 10:00:57 -0700

emacs -Q
 
This change in debug.el is not good:
 
Revision 1.107 - (view) (download) (annotate) - [select for diffs] 
Fri Apr 18 01:29:23 2008 UTC (17 months, 1 week ago) by monnier 
Branch: MAIN 
CVS Tags: font-backend-base 
Branch point for: font-backend 
Changes since 1.106: +4 -3 lines 
Diff to previous 1.106 
(debug): Revert to bury-buffer since quit-window is not better anyway.
 
In my case, this change means that the debugger frame is iconified
each time, and this includes some times when the debugger is still
active, which makes it impossible to access/use. (*)
 
The point is that `bury-buffer' is unacceptable for my use - it is
practically impossible for me to use the debugger in Emacs 23.  I can
live with no action at all (which keeps the *Backtrace* frame around)
or with `quit-window' in place of `bury-buffer'. I cannot live with
`bury-buffer'.  So I redefine `debug', just to change that one silly
function call.
 
The solution is to call a function that is the value of a user option:
`debugger-quit-function'. I don't care what the default value is -
make it `bury-buffer' if you want.
 
The user option's value should have :type `function' or, better, a
`choice' between nil and `function', where nil would mean do nothing.
If the :type is just `function' a user can of course use function
`ignore' to do nothing, but that is not so obvious for some users, so
in that case, please call that out in the doc string.
 
The code would then do this, in place of calling (bury-buffer):
 
;; If the option can have value nil:
(when debugger-quit-function
  (funcall debugger-quit-function))
 
;; If the option value can only be a function:
(funcall debugger-quit-function)
 
I would then customize the option to `quit-window' (or nil or
`ignore').
 

---
(*) No, I'm not going to try to figure out what's happening in those
cases where it is iconified when still active; it's hard enough using
the debugger when broken like this, without trying to debug the
debugger.  In case it helps, I will say however that I don't remember
seeing that when `bury-buffer' was used briefly during Emacs 22
development - back then it was iconified only when empty (finished),
IIRC.
 

In GNU Emacs 23.1.1 (i386-mingw-nt5.1.2600)
 of 2009-07-29 on SOFT-MJASON
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (4.4)'
 







reply via email to

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