Mercurial > emacs
changeset 83290:042f282a2ed7
Merged from miles@gnu.org--gnu-2005 (patch 66, 266-268)
Patches applied:
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-266
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-267
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-268
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-66
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-330
author | Karoly Lorentey <lorentey@elte.hu> |
---|---|
date | Tue, 19 Apr 2005 13:33:31 +0000 |
parents | 1e53ee7473e9 (current diff) aff89865e27c (diff) |
children | bbf359ec4a59 |
files | lisp/ChangeLog lisp/url/url.el lispref/ChangeLog man/ChangeLog src/dispextern.h src/dispnew.c src/fringe.c src/lread.c src/macterm.c src/window.c src/window.h src/xdisp.c src/xfaces.c src/xmenu.c |
diffstat | 25 files changed, 231 insertions(+), 161 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/ChangeLog Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/ChangeLog Tue Apr 19 13:33:31 2005 +0000 @@ -1,3 +1,33 @@ +2005-04-18 Stefan Monnier <monnier@iro.umontreal.ca> + + * isearch.el (isearch-edit-string): Make the search-ring available for + minibuffer history commands. + (minibuffer-local-isearch-map): Remove bindings for M-p and M-n, + the default history commands now work just as well. + (isearch-ring-retreat-edit, isearch-ring-advance-edit): Remove. + +2005-04-18 Kim F. Storm <storm@cua.dk> + + * emulation/cua-base.el (cua--pre-command-handler): Add more + elaborate check for shift modifier on non-window systems. + +2005-04-18 Lars Hansen <larsh@math.ku.dk> + + * desktop.el: Make "--no-desktop" turn off `desktop-save-mode'. + +2005-04-18 Kim F. Storm <storm@cua.dk> + + * tooltip.el (tooltip-show): Change second arg to USE-ECHO-AREA + and make it optional. Don't test tooltip-gud-echo-area here. + (tooltip-gud-process-output, gdb-tooltip-print): + Pass tooltip-gud-echo-area to tooltip-show. + (tooltip-help-tips): Remove second optional arg to tooltip-show. + +2005-04-18 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> + + * tooltip.el (tooltip-mode): `emacs-quick-startup' and + `display-graphic-p' may not be bound yet. + 2005-04-17 Luc Teirlinck <teirllm@auburn.edu> * startup.el (command-line): No longer enable Xterm Mouse mode by
--- a/lisp/desktop.el Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/desktop.el Tue Apr 19 13:33:31 2005 +0000 @@ -1030,9 +1030,10 @@ 'after-init-hook '(lambda () (let ((key "--no-desktop")) - (if (member key command-line-args) - (delete key command-line-args) - (when desktop-save-mode (desktop-read)))))) + (when (member key command-line-args) + (setq command-line-args (delete key command-line-args)) + (setq desktop-save-mode nil))) + (when desktop-save-mode (desktop-read)))) (provide 'desktop)
--- a/lisp/emulation/cua-base.el Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/emulation/cua-base.el Tue Apr 19 13:33:31 2005 +0000 @@ -1066,10 +1066,20 @@ ;; If rectangle is active, expand rectangle in specified direction and ignore the movement. (if movement (cond - ((memq 'shift (event-modifiers - (aref (if window-system - (this-single-command-raw-keys) - (this-single-command-keys)) 0))) + ((if window-system + (memq 'shift (event-modifiers + (aref (this-single-command-raw-keys) 0))) + (or + (memq 'shift (event-modifiers + (aref (this-single-command-keys) 0))) + ;; See if raw escape sequence maps to a shifted event, e.g. S-up or C-S-home. + (and (boundp 'function-key-map) + function-key-map + (let ((ev (lookup-key function-key-map + (this-single-command-raw-keys)))) + (and (vector ev) + (symbolp (setq ev (aref ev 0))) + (string-match "S-" (symbol-name ev))))))) (unless mark-active (push-mark-command nil t)) (setq cua--last-region-shifted t)
--- a/lisp/gnus/ChangeLog Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/gnus/ChangeLog Tue Apr 19 13:33:31 2005 +0000 @@ -1,3 +1,7 @@ +2005-04-18 Katsumi Yamaoka <yamaoka@jpl.org> + + * qp.el (quoted-printable-encode-region): Save excursion. + 2005-04-13 Katsumi Yamaoka <yamaoka@jpl.org> * gnus-art.el (gnus-mime-inline-part): Use mm-string-to-multibyte.
--- a/lisp/gnus/qp.el Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/gnus/qp.el Tue Apr 19 13:33:31 2005 +0000 @@ -1,6 +1,7 @@ ;;; qp.el --- Quoted-Printable functions -;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2005 +;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> ;; Keywords: mail, extensions @@ -100,15 +101,15 @@ If `mm-use-ultra-safe-encoding' is set, fold lines unconditionally and encode lines starting with \"From\"." (interactive "r") - (goto-char from) - (if (re-search-forward (mm-string-to-multibyte "[^\x0-\x7f\x80-\xff]") - to t) - (error "Multibyte character in QP encoding region")) (unless class ;; Avoid using 8bit characters. = is \075. ;; Equivalent to "^\000-\007\013\015-\037\200-\377=" (setq class "\010-\012\014\040-\074\076-\177")) (save-excursion + (goto-char from) + (if (re-search-forward (mm-string-to-multibyte "[^\x0-\x7f\x80-\xff]") + to t) + (error "Multibyte character in QP encoding region")) (save-restriction (narrow-to-region from to) ;; Encode all the non-ascii and control characters.
--- a/lisp/isearch.el Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/isearch.el Tue Apr 19 13:33:31 2005 +0000 @@ -405,12 +405,6 @@ (let ((map (make-sparse-keymap))) (set-keymap-parent map minibuffer-local-map) (define-key map "\r" 'isearch-nonincremental-exit-minibuffer) - (define-key map "\M-n" 'isearch-ring-advance-edit) - (define-key map [next] 'isearch-ring-advance-edit) - (define-key map [down] 'isearch-ring-advance-edit) - (define-key map "\M-p" 'isearch-ring-retreat-edit) - (define-key map [prior] 'isearch-ring-retreat-edit) - (define-key map [up] 'isearch-ring-retreat-edit) (define-key map "\M-\t" 'isearch-complete-edit) (define-key map "\C-s" 'isearch-forward-exit-minibuffer) (define-key map "\C-r" 'isearch-reverse-exit-minibuffer) @@ -937,8 +931,6 @@ \\[isearch-nonincremental-exit-minibuffer] to do one nonincremental search. \\[isearch-forward-exit-minibuffer] to resume isearching forward. \\[isearch-reverse-exit-minibuffer] to resume isearching backward. -\\[isearch-ring-advance-edit] to replace the search string with the next item in the search ring. -\\[isearch-ring-retreat-edit] to replace the search string with the previous item in the search ring. \\[isearch-complete-edit] to complete the search string using the search ring. \\<isearch-mode-map> If first char entered is \\[isearch-yank-word-or-char], then do word search instead." @@ -1024,12 +1016,12 @@ (isearch-unread e)) (setq cursor-in-echo-area nil) (setq isearch-new-string - (let (junk-ring) - (read-from-minibuffer - (isearch-message-prefix nil nil isearch-nonincremental) - isearch-string - minibuffer-local-isearch-map nil - 'junk-ring nil t)) + (read-from-minibuffer + (isearch-message-prefix nil nil isearch-nonincremental) + isearch-string + minibuffer-local-isearch-map nil + (if isearch-regexp 'regexp-search-ring 'search-ring) + nil t) isearch-new-message (mapconcat 'isearch-text-char-description isearch-new-string ""))) @@ -1860,49 +1852,6 @@ (interactive) (isearch-ring-adjust nil)) -(defun isearch-ring-advance-edit (n) - "Insert the next element of the search history into the minibuffer. -With prefix arg N, insert the Nth element." - (interactive "p") - (let* ((yank-pointer-name (if isearch-regexp - 'regexp-search-ring-yank-pointer - 'search-ring-yank-pointer)) - (yank-pointer (eval yank-pointer-name)) - (ring (if isearch-regexp regexp-search-ring search-ring)) - (length (length ring))) - (if (zerop length) - () - (set yank-pointer-name - (setq yank-pointer - (mod (- (or yank-pointer 0) n) - length))) - - (delete-field) - (insert (nth yank-pointer ring)) - (goto-char (point-max))))) - -(defun isearch-ring-retreat-edit (n) - "Insert the previous element of the search history into the minibuffer. -With prefix arg N, insert the Nth element." - (interactive "p") - (isearch-ring-advance-edit (- n))) - -;;(defun isearch-ring-adjust-edit (advance) -;; "Use the next or previous search string in the ring while in minibuffer." -;; (isearch-ring-adjust1 advance) -;; (erase-buffer) -;; (insert isearch-string)) - -;;(defun isearch-ring-advance-edit () -;; (interactive) -;; (isearch-ring-adjust-edit 'advance)) - -;;(defun isearch-ring-retreat-edit () -;; "Retreat to the previous search string in the ring while in the minibuffer." -;; (interactive) -;; (isearch-ring-adjust-edit nil)) - - (defun isearch-complete1 () ;; Helper for isearch-complete and isearch-complete-edit ;; Return t if completion OK, nil if no completion exists.
--- a/lisp/tooltip.el Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/tooltip.el Tue Apr 19 13:33:31 2005 +0000 @@ -188,8 +188,9 @@ ;; If you change the :init-value below, you also need to change the ;; corresponding code in startup.el. :init-value (not (or noninteractive - emacs-quick-startup - (not (display-graphic-p)) + (and (boundp 'emacs-quick-startup) emacs-quick-startup) + (not (and (fboundp 'display-graphic-p) + (display-graphic-p))) (not (fboundp 'x-show-tip)))) :group 'tooltip (unless (or (null tooltip-mode) (fboundp 'x-show-tip)) @@ -289,7 +290,7 @@ (push (cons key value) alist)) alist)) -(defun tooltip-show (text gud-tip) +(defun tooltip-show (text &optional use-echo-area) "Show a tooltip window displaying TEXT. Text larger than `x-max-tooltip-size' is clipped. @@ -300,8 +301,9 @@ `tooltip-x-offset' and `tooltip-y-offset' from the current mouse position. -GUD-TIP is t if the tooltip is from a GUD session and nil otherwise." - (if (and gud-tip tooltip-gud-echo-area) +Optional second arg USE-ECHO-AREA non-nil means to show tooltip +in echo area." + (if use-echo-area (message "%s" text) (condition-case error (let ((params (copy-sequence tooltip-frame-parameters)) @@ -417,7 +419,8 @@ (defun tooltip-gud-process-output (process output) "Process debugger output and show it in a tooltip window." (set-process-filter process tooltip-gud-original-filter) - (tooltip-show (tooltip-strip-prompt process output) t)) + (tooltip-show (tooltip-strip-prompt process output) + tooltip-gud-echo-area)) (defun tooltip-gud-print-command (expr) "Return a suitable command to print the expression EXPR. @@ -464,7 +467,8 @@ (with-current-buffer (gdb-get-buffer 'gdb-partial-output-buffer) (let ((string (buffer-string))) ;; remove newline for tooltip-gud-echo-area - (substring string 0 (- (length string) 1)))) t)) + (substring string 0 (- (length string) 1)))) + tooltip-gud-echo-area)) ;;; Tooltip help. @@ -497,7 +501,7 @@ the timer with ID `tooltip-timeout-id' fires. Value is non-nil if this function handled the tip." (when (stringp tooltip-help-message) - (tooltip-show tooltip-help-message nil) + (tooltip-show tooltip-help-message) t)) (provide 'tooltip)
--- a/lisp/url/ChangeLog Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/url/ChangeLog Tue Apr 19 13:33:31 2005 +0000 @@ -1,3 +1,8 @@ +2005-04-18 Stefan Monnier <monnier@iro.umontreal.ca> + + * url.el (url-retrieve-synchronously): Work around the fact that + url-http sometimes doesn't call the callback. + 2005-04-04 Lute Kamstra <lute@gnu.org> * url-handlers.el (url-handler-mode): Specify :group.
--- a/lisp/url/url.el Mon Apr 18 14:32:14 2005 +0000 +++ b/lisp/url/url.el Tue Apr 19 13:33:31 2005 +0000 @@ -180,15 +180,23 @@ (url-debug 'retrieval "Spinning in url-retrieve-synchronously: %S (%S)" retrieval-done asynch-buffer) - ;; We used to use `sit-for' here, but in some cases it wouldn't - ;; work because apparently pending keyboard input would always - ;; interrupt it before it got a chance to handle process input. - ;; `sleep-for' was tried but it lead to other forms of - ;; hanging. --Stef - (unless (accept-process-output proc) - ;; accept-process-output returned nil, maybe because the process - ;; exited (and may have been replaced with another). - (setq proc (get-buffer-process asynch-buffer))))) + (if (memq (process-status proc) '(closed exit signal failed)) + ;; FIXME: It's not clear whether url-retrieve's callback is + ;; guaranteed to be called or not. It seems that url-http + ;; decides sometimes consciously not to call it, so it's not + ;; clear that it's a bug, but even if we need to decide how + ;; url-http can then warn us that the download has completed. + ;; In the mean time, we use this here workaround. + (setq retrieval-done t) + ;; We used to use `sit-for' here, but in some cases it wouldn't + ;; work because apparently pending keyboard input would always + ;; interrupt it before it got a chance to handle process input. + ;; `sleep-for' was tried but it lead to other forms of + ;; hanging. --Stef + (unless (accept-process-output proc) + ;; accept-process-output returned nil, maybe because the process + ;; exited (and may have been replaced with another). + (setq proc (get-buffer-process asynch-buffer)))))) asynch-buffer))) (defun url-mm-callback (&rest ignored)
--- a/lispref/ChangeLog Mon Apr 18 14:32:14 2005 +0000 +++ b/lispref/ChangeLog Tue Apr 19 13:33:31 2005 +0000 @@ -1,3 +1,8 @@ +2005-04-18 Nick Roberts <nickrob@snap.net.nz> + + * customize.texi (Variable Definitions): Replace tooltip-mode + example with save-place. + 2005-04-17 Richard M. Stallman <rms@gnu.org> * buffers.texi (Indirect Buffers): Clarify.
--- a/lispref/customize.texi Mon Apr 18 14:32:14 2005 +0000 +++ b/lispref/customize.texi Tue Apr 19 13:33:31 2005 +0000 @@ -283,17 +283,14 @@ operation of a certain feature. Assuming that the package is coded to check the value of the option, you still need to arrange for the package to be loaded. You can do that with @code{:require}. @xref{Common -Keywords}. Here is an example, from the library @file{tooltip.el}: +Keywords}. Here is an example, from the library @file{saveplace.el}: @example -(defcustom tooltip-mode nil - "Non-nil if Tooltip mode is enabled..." - :set (lambda (symbol value) - (tooltip-mode (or value 0))) - :initialize 'custom-initialize-default +(defcustom save-place nil + "*Non-nil means automatically save place in each file..." :type 'boolean - :require 'tooltip - :group 'tooltip) + :require 'saveplace + :group 'save-place) @end example If a customization item has a type such as @code{hook} or @code{alist},
--- a/man/ChangeLog Mon Apr 18 14:32:14 2005 +0000 +++ b/man/ChangeLog Tue Apr 19 13:33:31 2005 +0000 @@ -1,3 +1,8 @@ +2005-04-18 Lars Hansen <larsh@math.ku.dk> + + * misc.texi (Saving Emacs Sessions): Add that "--no-desktop" now + turns off desktop-save-mode. + 2005-04-17 Luc Teirlinck <teirllm@auburn.edu> * frames.texi (XTerm Mouse): Xterm Mouse mode is no longer enabled
--- a/man/misc.texi Mon Apr 18 14:32:14 2005 +0000 +++ b/man/misc.texi Tue Apr 19 13:33:31 2005 +0000 @@ -1937,7 +1937,8 @@ @kbd{M-x desktop-revert} reverts to the desktop previously reloaded. Specify the option @samp{--no-desktop} on the command line when you -don't want it to reload any saved desktop. +don't want it to reload any saved desktop. This turns off +@code{desktop-save-mode} for the current session. @vindex desktop-restore-eager By default, all the buffers in the desktop are restored at one go.
--- a/src/ChangeLog Mon Apr 18 14:32:14 2005 +0000 +++ b/src/ChangeLog Tue Apr 19 13:33:31 2005 +0000 @@ -1,3 +1,55 @@ +2005-04-18 Kim F. Storm <storm@cua.dk> + + * dispextern.h (struct glyph_row): New member overlay_arrow_bitmap. + It replaces the corresponding member from struct window, as a + window may now show multiple overlay arrows. + Remove member overlay_arrow_p, superseeded by overlay_arrow_bitmap. + + * dispnew.c (row_equal_p, update_window_line, scrolling_window): + Compare overlay_arrow_bitmap than overlay_arrow_p members. + + * fringe.c (draw_fringe_bitmap): Use overlay_arrow_bitmap from row + rather than from window. + (update_window_fringes): Compare overlay_arrow_bitmap rather than + overlay_arrow_p members. + (Ffringe_bitmaps_at_pos): Return fringe overlay_arrow_bitmap name + if not default. + + * window.h (struct window): Remove member overlay_arrow_bitmap. + + * window.c (make_window): Don't initialize overlay_arrow_bitmap. + + * xdisp.c (overlay_arrow_string_or_property): Remove PBITMAP arg. + Calls changed. Don't check for overlay-arrow-bitmap property here. + (overlay_arrow_at_row): Remove PBITMAP arg. Instead, if left + fringe is present, return Lisp integer for bitmap (or -1 for default). + Fix value of overlay-arrow-bitmap property to be a symbol, use + lookup_fringe_bitmap to parse it. + (display_line): Change call to overlay_arrow_at_row. Store integer + return value as overlay bitmap in row rather than window. + Only show overlay arrow if row displays text, or if no other overlay + arrow is seen in window (if overlay marker is at point-max). + +2005-04-18 Thien-Thi Nguyen <ttn@gnu.org> + + * xfaces.c (realize_x_face) [!HAVE_WINDOW_SYSTEM]: Return NULL. + +2005-04-18 Lute Kamstra <lute@gnu.org> + + * lread.c (Vloads_in_progress): Static. + * fns.c (Vloads_in_progress): Remove extern. + (load_in_progress): Add extern. + (Frequire): Use load_in_progress instead of Vloads_in_progress. + +2005-04-18 Thien-Thi Nguyen <ttn@gnu.org> + + * xmenu.c (Fx_popup_menu): Initialize error_name to NULL. + +2005-04-18 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> + + * macterm.c (XTread_socket): Don't beep on keyboard input even if + no frame is visible. + 2005-04-16 Dan Nicolaescu <dann@ics.uci.edu> * term.c (struct keys): Add support for shifted keys. @@ -110,7 +162,6 @@ into "(any string)". * lread.c (Vloads_in_progress): Not static. - * fns.c (Vloads_in_progress): Add extern. (Frequire): Don't do LOADHIST_ATTACH if Vloads_in_progress is nil.
--- a/src/dispextern.h Mon Apr 18 14:32:14 2005 +0000 +++ b/src/dispextern.h Tue Apr 19 13:33:31 2005 +0000 @@ -726,6 +726,11 @@ position of the next row. */ struct display_pos end; + /* Non-zero means the overlay arrow bitmap is on this line. + -1 means use default overlay arrow bitmap, else + it specifies actual fringe bitmap number. */ + int overlay_arrow_bitmap; + /* Left fringe bitmap number (enum fringe_bitmap_type). */ unsigned left_user_fringe_bitmap : FRINGE_ID_BITS; @@ -764,9 +769,6 @@ unsigned truncated_on_left_p : 1; unsigned truncated_on_right_p : 1; - /* 1 means the overlay arrow is on this line. */ - unsigned overlay_arrow_p : 1; - /* 1 means that this row displays a continued line, i.e. it has a continuation mark at the right side. */ unsigned continued_p : 1;
--- a/src/dispnew.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/dispnew.c Tue Apr 19 13:33:31 2005 +0000 @@ -1506,7 +1506,7 @@ || a->left_fringe_face_id != b->left_fringe_face_id || a->right_fringe_bitmap != b->right_fringe_bitmap || a->right_fringe_face_id != b->right_fringe_face_id - || a->overlay_arrow_p != b->overlay_arrow_p + || a->overlay_arrow_bitmap != b->overlay_arrow_bitmap || a->exact_window_width_line_p != b->exact_window_width_line_p || a->overlapped_p != b->overlapped_p || (MATRIX_ROW_CONTINUATION_LINE_P (a) @@ -4539,7 +4539,7 @@ || desired_row->y != current_row->y || desired_row->visible_height != current_row->visible_height || desired_row->cursor_in_fringe_p != current_row->cursor_in_fringe_p - || desired_row->overlay_arrow_p != current_row->overlay_arrow_p + || desired_row->overlay_arrow_bitmap != current_row->overlay_arrow_bitmap || current_row->redraw_fringe_bitmaps_p || desired_row->mode_line_p != current_row->mode_line_p || desired_row->exact_window_width_line_p != current_row->exact_window_width_line_p @@ -5051,7 +5051,7 @@ || to->right_fringe_bitmap != from->right_fringe_bitmap || to->left_fringe_face_id != from->left_fringe_face_id || to->right_fringe_face_id != from->right_fringe_face_id - || to->overlay_arrow_p != from->overlay_arrow_p)) + || to->overlay_arrow_bitmap != from->overlay_arrow_bitmap)) from->redraw_fringe_bitmaps_p = 1; assign_row (to, from); to->enabled_p = 1, from->enabled_p = 0;
--- a/src/fns.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/fns.c Tue Apr 19 13:33:31 2005 +0000 @@ -66,7 +66,7 @@ extern int minibuffer_auto_raise; extern Lisp_Object minibuf_window; extern Lisp_Object Vlocale_coding_system; -extern Lisp_Object Vloads_in_progress; +extern int load_in_progress; Lisp_Object Qstring_lessp, Qprovide, Qrequire; Lisp_Object Qyes_or_no_p_history; @@ -3460,7 +3460,7 @@ even if the feature specified is already loaded. But not more than once in any file, and not when we aren't loading a file. */ - if (! NILP (Vloads_in_progress)) + if (load_in_progress) { tem = Fcons (Qrequire, feature); if (NILP (Fmember (tem, Vcurrent_load_list)))
--- a/src/fringe.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/fringe.c Tue Apr 19 13:33:31 2005 +0000 @@ -700,11 +700,11 @@ draw_fringe_bitmap_1 (w, row, left_p, overlay, NO_FRINGE_BITMAP); - if (left_p && row->overlay_arrow_p) + if (left_p && row->overlay_arrow_bitmap != NO_FRINGE_BITMAP) draw_fringe_bitmap_1 (w, row, 1, 1, - (w->overlay_arrow_bitmap - ? w->overlay_arrow_bitmap - : OVERLAY_ARROW_BITMAP)); + (row->overlay_arrow_bitmap < 0 + ? OVERLAY_ARROW_BITMAP + : row->overlay_arrow_bitmap)); } @@ -960,10 +960,10 @@ cur->right_fringe_face_id = right_face_id; } - if (row->overlay_arrow_p != cur->overlay_arrow_p) + if (row->overlay_arrow_bitmap != cur->overlay_arrow_bitmap) { redraw_p = row->redraw_fringe_bitmaps_p = cur->redraw_fringe_bitmaps_p = 1; - cur->overlay_arrow_p = row->overlay_arrow_p; + cur->overlay_arrow_bitmap = row->overlay_arrow_bitmap; } row->left_fringe_bitmap = left; @@ -1414,7 +1414,9 @@ if (row) return list3 (get_fringe_bitmap_name (row->left_fringe_bitmap), get_fringe_bitmap_name (row->right_fringe_bitmap), - (row->overlay_arrow_p ? Qt : Qnil)); + (row->overlay_arrow_bitmap == 0 ? Qnil + : row->overlay_arrow_bitmap < 0 ? Qt + : get_fringe_bitmap_name (row->overlay_arrow_bitmap))); else return Qnil; }
--- a/src/lread.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/lread.c Tue Apr 19 13:33:31 2005 +0000 @@ -1,6 +1,6 @@ /* Lisp parsing and input streams. Copyright (C) 1985, 1986, 1987, 1988, 1989, 1993, 1994, 1995, 1997, 1998, - 1999, 2000, 2001, 2003, 2004 Free Software Foundation, Inc. + 1999, 2000, 2001, 2003, 2004, 2005 Free Software Foundation, Inc. This file is part of GNU Emacs. @@ -90,7 +90,7 @@ extern Lisp_Object Qevent_symbol_element_mask; extern Lisp_Object Qfile_exists_p; -/* non-zero if inside `load' */ +/* non-zero iff inside `load' */ int load_in_progress; /* Directory in which the sources were found. */ @@ -194,7 +194,7 @@ /* A list of file names for files being loaded in Fload. Used to check for recursive loads. */ -Lisp_Object Vloads_in_progress; +static Lisp_Object Vloads_in_progress; /* Non-zero means load dangerous compiled Lisp files. */
--- a/src/macterm.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/macterm.c Tue Apr 19 13:33:31 2005 +0000 @@ -8590,13 +8590,15 @@ struct frame *f = mac_focus_frame (dpyinfo); WindowPtr window_ptr; - if (!f) +#if 0 + if (dpyinfo->x_focus_frame == NULL) { /* Beep if wheel move occurs when all the frames are invisible. */ SysBeep(1); break; } +#endif GetEventParameter(eventRef, kEventParamMouseWheelDelta, typeSInt32, NULL, sizeof (SInt32), @@ -9011,6 +9013,7 @@ break; #endif +#if 0 if (dpyinfo->x_focus_frame == NULL) { /* Beep if keyboard input occurs when all the frames @@ -9018,6 +9021,7 @@ SysBeep (1); break; } +#endif { static SInt16 last_key_script = -1;
--- a/src/window.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/window.c Tue Apr 19 13:33:31 2005 +0000 @@ -288,7 +288,6 @@ p->fringes_outside_margins = Qnil; p->scroll_bar_width = Qnil; p->vertical_scroll_bar_type = Qt; - p->overlay_arrow_bitmap = 0; Vwindow_list = Qnil; return val;
--- a/src/window.h Mon Apr 18 14:32:14 2005 +0000 +++ b/src/window.h Tue Apr 19 13:33:31 2005 +0000 @@ -259,9 +259,6 @@ /* This is handy for undrawing the cursor. */ int phys_cursor_ascent, phys_cursor_height; - /* Alternate overlay-arrow-bitmap in this window. */ - int overlay_arrow_bitmap; - /* Non-zero means the cursor is currently displayed. This can be set to zero by functions overpainting the cursor image. */ unsigned phys_cursor_on_p : 1;
--- a/src/xdisp.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/xdisp.c Tue Apr 19 13:33:31 2005 +0000 @@ -9638,22 +9638,14 @@ static Lisp_Object -overlay_arrow_string_or_property (var, pbitmap) +overlay_arrow_string_or_property (var) Lisp_Object var; - int *pbitmap; -{ - Lisp_Object pstr = Fget (var, Qoverlay_arrow_string); - Lisp_Object bitmap; - - if (pbitmap) - { - *pbitmap = 0; - if (bitmap = Fget (var, Qoverlay_arrow_bitmap), INTEGERP (bitmap)) - *pbitmap = XINT (bitmap); - } - - if (!NILP (pstr)) - return pstr; +{ + Lisp_Object val; + + if (val = Fget (var, Qoverlay_arrow_string), STRINGP (val)) + return val; + return Voverlay_arrow_string; } @@ -9703,7 +9695,7 @@ continue; if (! EQ (COERCE_MARKER (val), Fget (var, Qlast_arrow_position)) - || ! (pstr = overlay_arrow_string_or_property (var, 0), + || ! (pstr = overlay_arrow_string_or_property (var), EQ (pstr, Fget (var, Qlast_arrow_string)))) return 1; } @@ -9733,7 +9725,7 @@ Fput (var, Qlast_arrow_position, COERCE_MARKER (val)); Fput (var, Qlast_arrow_string, - overlay_arrow_string_or_property (var, 0)); + overlay_arrow_string_or_property (var)); } else if (up_to_date < 0 || !NILP (Fget (var, Qlast_arrow_position))) @@ -9746,14 +9738,13 @@ /* Return overlay arrow string to display at row. - Return t if display as bitmap in left fringe. + Return integer (bitmap number) for arrow bitmap in left fringe. Return nil if no overlay arrow. */ static Lisp_Object -overlay_arrow_at_row (it, row, pbitmap) +overlay_arrow_at_row (it, row) struct it *it; struct glyph_row *row; - int *pbitmap; { Lisp_Object vlist; @@ -9773,17 +9764,21 @@ && current_buffer == XMARKER (val)->buffer && (MATRIX_ROW_START_CHARPOS (row) == marker_position (val))) { - val = overlay_arrow_string_or_property (var, pbitmap); if (FRAME_WINDOW_P (it->f) && WINDOW_LEFT_FRINGE_WIDTH (it->w) > 0) - return Qt; - if (STRINGP (val)) - return val; - break; - } - } - - *pbitmap = 0; + { + if (val = Fget (var, Qoverlay_arrow_bitmap), SYMBOLP (val)) + { + int fringe_bitmap; + if ((fringe_bitmap = lookup_fringe_bitmap (val)) != 0) + return make_number (fringe_bitmap); + } + return make_number (-1); /* Use default arrow bitmap */ + } + return overlay_arrow_string_or_property (var); + } + } + return Qnil; } @@ -14847,7 +14842,6 @@ struct it *it; { struct glyph_row *row = it->glyph_row; - int overlay_arrow_bitmap; Lisp_Object overlay_arrow_string; /* We always start displaying at hpos zero even if hscrolled. */ @@ -15255,9 +15249,9 @@ mark this glyph row as the one containing the overlay arrow. This is clearly a mess with variable size fonts. It would be better to let it be displayed like cursors under X. */ - if ((overlay_arrow_string - = overlay_arrow_at_row (it, row, &overlay_arrow_bitmap), - !NILP (overlay_arrow_string))) + if ((row->displays_text_p || !overlay_arrow_seen) + && (overlay_arrow_string = overlay_arrow_at_row (it, row), + !NILP (overlay_arrow_string))) { /* Overlay arrow in window redisplay is a fringe bitmap. */ if (STRINGP (overlay_arrow_string)) @@ -15287,8 +15281,8 @@ } else { - it->w->overlay_arrow_bitmap = overlay_arrow_bitmap; - row->overlay_arrow_p = 1; + xassert (INTEGERP (overlay_arrow_string)); + row->overlay_arrow_bitmap = XINT (overlay_arrow_string); } overlay_arrow_seen = 1; }
--- a/src/xfaces.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/xfaces.c Tue Apr 19 13:33:31 2005 +0000 @@ -7115,8 +7115,9 @@ int c; struct face *base_face; { + struct face *face = NULL; #ifdef HAVE_WINDOW_SYSTEM - struct face *face, *default_face; + struct face *default_face; struct frame *f; Lisp_Object stipple, overline, strike_through, box; @@ -7312,8 +7313,8 @@ face->stipple = load_pixmap (f, stipple, &face->pixmap_w, &face->pixmap_h); xassert (FACE_SUITABLE_FOR_CHAR_P (face, c)); +#endif /* HAVE_WINDOW_SYSTEM */ return face; -#endif /* HAVE_WINDOW_SYSTEM */ }
--- a/src/xmenu.c Mon Apr 18 14:32:14 2005 +0000 +++ b/src/xmenu.c Tue Apr 19 13:33:31 2005 +0000 @@ -771,7 +771,7 @@ Lisp_Object keymap, tem; int xpos = 0, ypos = 0; Lisp_Object title; - char *error_name; + char *error_name = NULL; Lisp_Object selection; FRAME_PTR f = NULL; Lisp_Object x, y, window; @@ -2483,7 +2483,7 @@ if (FRAME_X_DISPLAY_INFO (f)->grabbed & (1 << i)) break; } - + /* Display the menu. */ gtk_widget_show_all (menu); gtk_menu_popup (GTK_MENU (menu), 0, 0, pos_func, &popup_x_y, i, 0); @@ -2601,7 +2601,7 @@ /* Display the menu. */ lw_popup_menu (menu, (XEvent *) &dummy); popup_activated_flag = 1; - + { int fact = 4 * sizeof (LWLIB_ID); int specpdl_count = SPECPDL_INDEX (); @@ -3225,7 +3225,7 @@ { struct Lisp_Save_Value *p1 = XSAVE_VALUE (Fcar (arg)); struct Lisp_Save_Value *p2 = XSAVE_VALUE (Fcdr (arg)); - + FRAME_PTR f = p1->pointer; XMenu *menu = p2->pointer; @@ -3459,7 +3459,7 @@ #ifndef MSDOS XMenuActivateSetWaitFunction (x_menu_wait_for_event, FRAME_X_DISPLAY (f)); #endif - + record_unwind_protect (pop_down_menu, Fcons (make_save_value (f, 0), make_save_value (menu, 0)));