diff options
author | Karoly Lorentey <lorentey@elte.hu> | 2005-10-19 14:06:17 +0000 |
---|---|---|
committer | Karoly Lorentey <lorentey@elte.hu> | 2005-10-19 14:06:17 +0000 |
commit | 1072671b5b0f1fda9f91ea99da4bf0bd275ce6eb (patch) | |
tree | f1b05485825e65d7c0ca06cb273be4fe16a44a3f /lisp/progmodes | |
parent | 6d8cf83040cdb54a0b1d72bd6a021f9815bd4af2 (diff) | |
parent | 8b1b64617b37243f75c4052653761d2e2a3943f3 (diff) | |
download | emacs-1072671b5b0f1fda9f91ea99da4bf0bd275ce6eb.tar.gz emacs-1072671b5b0f1fda9f91ea99da4bf0bd275ce6eb.tar.bz2 emacs-1072671b5b0f1fda9f91ea99da4bf0bd275ce6eb.zip |
Merged from miles@gnu.org--gnu-2005 (patch 133-141, 596-609)
Patches applied:
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-596
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-597
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-598
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-599
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-600
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-601
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-602
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-603
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-604
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-605
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-606
Remove lisp/toolbar directory
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-607
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-608
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-609
Update from CVS
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-133
Update from CVS
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-134
Update from CVS
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-135
Update from CVS
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-136
Merge from emacs--cvs-trunk--0
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-137
Update from CVS
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-138
Update from CVS: texi/gnus.texi (RSS): Fix key description.
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-139
Merge from emacs--cvs-trunk--0
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-140
Update from CVS
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-141
Update from CVS: texi/gnus.texi (Document Server Internals): Addition.
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-426
Diffstat (limited to 'lisp/progmodes')
-rw-r--r-- | lisp/progmodes/compile.el | 64 | ||||
-rw-r--r-- | lisp/progmodes/etags.el | 3 | ||||
-rw-r--r-- | lisp/progmodes/gdb-ui.el | 7 | ||||
-rw-r--r-- | lisp/progmodes/gud.el | 39 | ||||
-rw-r--r-- | lisp/progmodes/make-mode.el | 2 | ||||
-rw-r--r-- | lisp/progmodes/meta-mode.el | 2 | ||||
-rw-r--r-- | lisp/progmodes/octave-mod.el | 2 | ||||
-rw-r--r-- | lisp/progmodes/pascal.el | 4 | ||||
-rw-r--r-- | lisp/progmodes/python.el | 2 |
9 files changed, 69 insertions, 56 deletions
diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 269fbeaf137..d041fa366c8 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -1678,37 +1678,20 @@ displays at the top of the window; there is no arrow." "Jump to an error corresponding to MSG at MK. All arguments are markers. If END-MK is non-nil, mark is set there and overlay is highlighted between MK and END-MK." - (if (eq (window-buffer (selected-window)) - (marker-buffer msg)) - ;; If the compilation buffer window is selected, - ;; keep the compilation buffer in this window; - ;; display the source in another window. - (let ((pop-up-windows t)) - (pop-to-buffer (marker-buffer mk))) - (if (window-dedicated-p (selected-window)) - (pop-to-buffer (marker-buffer mk)) - (switch-to-buffer (marker-buffer mk)))) - ;; If narrowing gets in the way of going to the right place, widen. - (unless (eq (goto-char mk) (point)) - (widen) - (goto-char mk)) - (if end-mk - (push-mark end-mk t) - (if mark-active (setq mark-active))) - ;; If hideshow got in the way of - ;; seeing the right place, open permanently. - (dolist (ov (overlays-at (point))) - (when (eq 'hs (overlay-get ov 'invisible)) - (delete-overlay ov) - (goto-char mk))) - ;; Show compilation buffer in other window, scrolled to this error. - (let* ((pop-up-windows t) - ;; Use an existing window if it is in a visible frame. + (let* ((from-compilation-buffer (eq (window-buffer (selected-window)) + (marker-buffer msg))) + ;; Use an existing window if it is in a visible frame. (pre-existing (get-buffer-window (marker-buffer msg) 0)) - (w (let ((display-buffer-reuse-frames t)) - ;; Pop up a window. - (display-buffer (marker-buffer msg)))) + (w (if (and from-compilation-buffer pre-existing) + ;; Calling display-buffer here may end up (partly) hiding + ;; the error location if the two buffers are in two + ;; different frames. So don't do it if it's not necessary. + pre-existing + (let ((display-buffer-reuse-frames t) + (pop-up-windows t)) + ;; Pop up a window. + (display-buffer (marker-buffer msg))))) (highlight-regexp (with-current-buffer (marker-buffer msg) ;; also do this while we change buffer (compilation-set-window w msg) @@ -1718,6 +1701,29 @@ and overlay is highlighted between MK and END-MK." ;; creating a new window. (unless pre-existing (compilation-set-window-height w)) + (if from-compilation-buffer + ;; If the compilation buffer window was selected, + ;; keep the compilation buffer in this window; + ;; display the source in another window. + (let ((pop-up-windows t)) + (pop-to-buffer (marker-buffer mk) 'other-window)) + (if (window-dedicated-p (selected-window)) + (pop-to-buffer (marker-buffer mk)) + (switch-to-buffer (marker-buffer mk)))) + ;; If narrowing gets in the way of going to the right place, widen. + (unless (eq (goto-char mk) (point)) + (widen) + (goto-char mk)) + (if end-mk + (push-mark end-mk t) + (if mark-active (setq mark-active))) + ;; If hideshow got in the way of + ;; seeing the right place, open permanently. + (dolist (ov (overlays-at (point))) + (when (eq 'hs (overlay-get ov 'invisible)) + (delete-overlay ov) + (goto-char mk))) + (when highlight-regexp (if (timerp next-error-highlight-timer) (cancel-timer next-error-highlight-timer)) diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index f6e8697543f..ac2cc23048a 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el @@ -2015,7 +2015,8 @@ for \\[find-tag] (which see)." (message "Making completion list...") (with-output-to-temp-buffer "*Completions*" (display-completion-list - (all-completions pattern 'tags-complete-tag nil))) + (all-completions pattern 'tags-complete-tag nil) + pattern)) (message "Making completion list...%s" "done"))))) (dolist (x '("^No tags table in use; use .* to select one$" diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index 852cd8deb88..bf09669083d 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el @@ -437,6 +437,9 @@ Also display the main routine in the disassembly buffer if present." nil nil))) (push var gdb-var-list) (speedbar 1) + (unless (string-equal + speedbar-initial-expansion-list-name "GUD") + (speedbar-change-initial-expansion-list "GUD")) (if (equal (nth 2 var) "0") (gdb-enqueue-input (list @@ -600,7 +603,9 @@ INDENT is the current indentation depth." (dolist (var gdb-var-list) (if (string-match (concat token "\\.") (nth 1 var)) (setq gdb-var-list (delq var gdb-var-list)))) - (setq gdb-var-changed t)))) + (setq gdb-var-changed t) + (with-current-buffer gud-comint-buffer + (speedbar-timer-fn))))) (defun gdb-get-target-string () (with-current-buffer gud-comint-buffer diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el index d38697a2152..8f962381d24 100644 --- a/lisp/progmodes/gud.el +++ b/lisp/progmodes/gud.el @@ -5,7 +5,7 @@ ;; Keywords: unix, tools ;; Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001, 2002, 2003, -;; 2004, 2005 Free Software Foundation, Inc. +;; 2004, 2005 Free Software Foundation, Inc. ;; This file is part of GNU Emacs. @@ -139,13 +139,13 @@ Used to grey out relevant togolbar icons.") ([remove] menu-item "Remove Breakpoint" gud-remove :enable (not gud-running) :visible (not (and (memq gud-minor-mode '(gdbmi gdba)) - (window-fringes)))) + (> (car (window-fringes)) 0)))) ([tbreak] menu-item "Temporary Breakpoint" gud-tbreak :enable (memq gud-minor-mode '(gdbmi gdba gdb sdb xdb bashdb))) ([break] menu-item "Set Breakpoint" gud-break :enable (not gud-running) :visible (not (and (memq gud-minor-mode '(gdbmi gdba)) - (window-fringes)))) + (> (car (window-fringes)) 0)))) ([up] menu-item "Up Stack" gud-up :enable (and (not gud-running) (memq gud-minor-mode @@ -197,24 +197,24 @@ Used to grey out relevant togolbar icons.") (defvar gud-tool-bar-map (if (display-graphic-p) (let ((map (make-sparse-keymap))) - (dolist (x '((gud-break . "gud-break") - (gud-remove . "gud-remove") - (gud-print . "gud-print") - (gud-pstar . "gud-pstar") - (gud-watch . "gud-watch") - (gud-cont . "gud-cont") - (gud-until . "gud-until") - (gud-finish . "gud-finish") - (gud-run . "gud-run") + (dolist (x '((gud-break . "gud/break") + (gud-remove . "gud/remove") + (gud-print . "gud/print") + (gud-pstar . "gud/pstar") + (gud-watch . "gud/watch") + (gud-cont . "gud/cont") + (gud-until . "gud/until") + (gud-finish . "gud/finish") + (gud-run . "gud/run") ;; gud-s, gud-si etc. instead of gud-step, ;; gud-stepi, to avoid file-name clashes on DOS ;; 8+3 filesystems. - (gud-next . "gud-n") - (gud-step . "gud-s") - (gud-nexti . "gud-ni") - (gud-stepi . "gud-si") - (gud-up . "gud-up") - (gud-down . "gud-down") + (gud-next . "gud/next") + (gud-step . "gud/step") + (gud-nexti . "gud/nexti") + (gud-stepi . "gud/stepi") + (gud-up . "gud/up") + (gud-down . "gud/down") (gud-goto-info . "info")) map) (tool-bar-local-item-from-menu @@ -2575,7 +2575,8 @@ It is saved for when this flag is not set.") ;; Stop displaying an arrow in a source file. (setq gud-overlay-arrow-position nil) (set-process-buffer proc nil) - (if (featurep 'speedbar) + (if (and (boundp 'speedbar-frame) + (string-equal speedbar-initial-expansion-list-name "GUD")) (speedbar-change-initial-expansion-list speedbar-previously-used-expansion-list-name)) (if (memq gud-minor-mode-type '(gdbmi gdba)) diff --git a/lisp/progmodes/make-mode.el b/lisp/progmodes/make-mode.el index 11ae1c66aa7..3a55129c899 100644 --- a/lisp/progmodes/make-mode.el +++ b/lisp/progmodes/make-mode.el @@ -1176,7 +1176,7 @@ The context determines which are considered." (message "Making completion list...") (let ((list (all-completions try table))) (with-output-to-temp-buffer "*Completions*" - (display-completion-list list))) + (display-completion-list list try))) (message "Making completion list...done")))))) diff --git a/lisp/progmodes/meta-mode.el b/lisp/progmodes/meta-mode.el index 9ae3e5a5935..f5bbb4d68db 100644 --- a/lisp/progmodes/meta-mode.el +++ b/lisp/progmodes/meta-mode.el @@ -509,7 +509,7 @@ If the list was changed, sort the list and remove duplicates first." (message "Making completion list...") (let ((list (all-completions symbol list nil))) (with-output-to-temp-buffer "*Completions*" - (display-completion-list list))) + (display-completion-list list symbol))) (message "Making completion list... done")))) (funcall (nth 1 entry))))) diff --git a/lisp/progmodes/octave-mod.el b/lisp/progmodes/octave-mod.el index e37f3b14a15..b65ad9eac1a 100644 --- a/lisp/progmodes/octave-mod.el +++ b/lisp/progmodes/octave-mod.el @@ -1252,7 +1252,7 @@ variables." ;; Taken from comint.el (message "Making completion list...") (with-output-to-temp-buffer "*Completions*" - (display-completion-list list)) + (display-completion-list list string)) (message "Hit space to flush") (let (key first) (if (save-excursion diff --git a/lisp/progmodes/pascal.el b/lisp/progmodes/pascal.el index 3cd243580e2..801096b9b0f 100644 --- a/lisp/progmodes/pascal.el +++ b/lisp/progmodes/pascal.el @@ -1378,7 +1378,7 @@ indent of the current line in parameterlist." ((and (not (null (cdr allcomp))) (= (length pascal-str) (length match))) (with-output-to-temp-buffer "*Completions*" - (display-completion-list allcomp)) + (display-completion-list allcomp pascal-str)) ;; Wait for a keypress. Then delete *Completion* window (momentary-string-display "" (point)) (delete-window (get-buffer-window (get-buffer "*Completions*"))) @@ -1398,7 +1398,7 @@ indent of the current line in parameterlist." (all-completions pascal-str 'pascal-completion)))) ;; Show possible completions in a temporary buffer. (with-output-to-temp-buffer "*Completions*" - (display-completion-list allcomp)) + (display-completion-list allcomp pascal-str)) ;; Wait for a keypress. Then delete *Completion* window (momentary-string-display "" (point)) (delete-window (get-buffer-window (get-buffer "*Completions*"))))) diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index f7788404350..6ed2e39e4e8 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -1652,7 +1652,7 @@ Repeating the command scrolls the completion window." (t (message "Making completion list...") (with-output-to-temp-buffer "*Completions*" - (display-completion-list completions)) + (display-completion-list completions symbol)) (message "Making completion list...%s" "done")))))))) (eval-when-compile (require 'hippie-exp)) |