diff options
| author | Karoly Lorentey | 2004-07-13 15:45:15 +0000 |
|---|---|---|
| committer | Karoly Lorentey | 2004-07-13 15:45:15 +0000 |
| commit | 4cb2afc64f004ba91ff0bd37cf8ca6669b228988 (patch) | |
| tree | ebf8a9fc7d69d2282e75f28087cb9245f97e9865 /src | |
| parent | 1705c9330e905dc35f95ad9b79d32d59db214433 (diff) | |
| parent | 23b8b1803172cf4749f0260b79a89bb2ee391e79 (diff) | |
| download | emacs-4cb2afc64f004ba91ff0bd37cf8ca6669b228988.tar.gz emacs-4cb2afc64f004ba91ff0bd37cf8ca6669b228988.zip | |
Merged in changes from CVS trunk.
Patches applied:
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-450
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-451
Update from CVS: lisp/subr.el (get-buffer-window-list): Doc fix.
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-452
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-453
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-218
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 15 | ||||
| -rw-r--r-- | src/alloc.c | 2 | ||||
| -rw-r--r-- | src/buffer.c | 14 | ||||
| -rw-r--r-- | src/window.c | 31 |
4 files changed, 51 insertions, 11 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index bbedc86886e..b3a9386da86 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | 2004-07-12 Kim F. Storm <storm@cua.dk> | ||
| 2 | |||
| 3 | * alloc.c (mark_object): Only look at Lisp_Misc_Save_Value | ||
| 4 | if GC_MARK_STACK. | ||
| 5 | |||
| 6 | 2004-07-10 Luc Teirlinck <teirllm@auburn.edu> | ||
| 7 | |||
| 8 | * buffer.c (Fswitch_to_buffer, Fpop_to_buffer): Doc fixes. | ||
| 9 | |||
| 10 | * window.c (Fwindow_buffer, Fother_window, Fget_lru_window) | ||
| 11 | (Fget_largest_window, Fget_buffer_window, Fdelete_windows_on) | ||
| 12 | (Freplace_buffer_in_windows, Fset_window_buffer) | ||
| 13 | (Fselect-window, Fdisplay-buffer, Fsplit_window): Doc fixes. | ||
| 14 | (syms_of_window): Expand docstring of `display-buffer-function'. | ||
| 15 | |||
| 1 | 2004-07-09 Luc Teirlinck <teirllm@auburn.edu> | 16 | 2004-07-09 Luc Teirlinck <teirllm@auburn.edu> |
| 2 | 17 | ||
| 3 | * editfns.c (Ffloat_time, Fformat_time_string, Fdecode_time) | 18 | * editfns.c (Ffloat_time, Fformat_time_string, Fdecode_time) |
diff --git a/src/alloc.c b/src/alloc.c index 5dc8d186369..955f274c270 100644 --- a/src/alloc.c +++ b/src/alloc.c | |||
| @@ -5035,6 +5035,7 @@ mark_object (arg) | |||
| 5035 | break; | 5035 | break; |
| 5036 | 5036 | ||
| 5037 | case Lisp_Misc_Save_Value: | 5037 | case Lisp_Misc_Save_Value: |
| 5038 | #if GC_MARK_STACK | ||
| 5038 | { | 5039 | { |
| 5039 | register struct Lisp_Save_Value *ptr = XSAVE_VALUE (obj); | 5040 | register struct Lisp_Save_Value *ptr = XSAVE_VALUE (obj); |
| 5040 | /* If DOGC is set, POINTER is the address of a memory | 5041 | /* If DOGC is set, POINTER is the address of a memory |
| @@ -5047,6 +5048,7 @@ mark_object (arg) | |||
| 5047 | mark_maybe_object (*p); | 5048 | mark_maybe_object (*p); |
| 5048 | } | 5049 | } |
| 5049 | } | 5050 | } |
| 5051 | #endif | ||
| 5050 | break; | 5052 | break; |
| 5051 | 5053 | ||
| 5052 | case Lisp_Misc_Overlay: | 5054 | case Lisp_Misc_Overlay: |
diff --git a/src/buffer.c b/src/buffer.c index 031f5da8e6e..c5783ade2a0 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -1664,9 +1664,15 @@ switch_to_buffer_1 (buffer, norecord) | |||
| 1664 | 1664 | ||
| 1665 | DEFUN ("switch-to-buffer", Fswitch_to_buffer, Sswitch_to_buffer, 1, 2, "BSwitch to buffer: ", | 1665 | DEFUN ("switch-to-buffer", Fswitch_to_buffer, Sswitch_to_buffer, 1, 2, "BSwitch to buffer: ", |
| 1666 | doc: /* Select buffer BUFFER in the current window. | 1666 | doc: /* Select buffer BUFFER in the current window. |
| 1667 | BUFFER may be a buffer or a buffer name. | 1667 | If BUFFER does not identify an existing buffer, |
| 1668 | then this function creates a buffer with that name. | ||
| 1669 | |||
| 1670 | When called from Lisp, BUFFER may be a buffer, a string \(a buffer name), | ||
| 1671 | or nil. If BUFFER is nil, then this function chooses a buffer | ||
| 1672 | using `other-buffer'. | ||
| 1668 | Optional second arg NORECORD non-nil means | 1673 | Optional second arg NORECORD non-nil means |
| 1669 | do not put this buffer at the front of the list of recently selected ones. | 1674 | do not put this buffer at the front of the list of recently selected ones. |
| 1675 | This function returns the buffer it switched to. | ||
| 1670 | 1676 | ||
| 1671 | WARNING: This is NOT the way to work on another buffer temporarily | 1677 | WARNING: This is NOT the way to work on another buffer temporarily |
| 1672 | within a Lisp program! Use `set-buffer' instead. That avoids messing with | 1678 | within a Lisp program! Use `set-buffer' instead. That avoids messing with |
| @@ -1689,11 +1695,15 @@ the window-buffer correspondences. */) | |||
| 1689 | 1695 | ||
| 1690 | DEFUN ("pop-to-buffer", Fpop_to_buffer, Spop_to_buffer, 1, 3, 0, | 1696 | DEFUN ("pop-to-buffer", Fpop_to_buffer, Spop_to_buffer, 1, 3, 0, |
| 1691 | doc: /* Select buffer BUFFER in some window, preferably a different one. | 1697 | doc: /* Select buffer BUFFER in some window, preferably a different one. |
| 1692 | If BUFFER is nil, then some other buffer is chosen. | 1698 | BUFFER may be a buffer, a string \(a buffer name), or nil. |
| 1699 | If BUFFER is a string which is not the name of an existing buffer, | ||
| 1700 | then this function creates a buffer with that name. | ||
| 1701 | If BUFFER is nil, then it chooses some other buffer. | ||
| 1693 | If `pop-up-windows' is non-nil, windows can be split to do this. | 1702 | If `pop-up-windows' is non-nil, windows can be split to do this. |
| 1694 | If optional second arg OTHER-WINDOW is non-nil, insist on finding another | 1703 | If optional second arg OTHER-WINDOW is non-nil, insist on finding another |
| 1695 | window even if BUFFER is already visible in the selected window, | 1704 | window even if BUFFER is already visible in the selected window, |
| 1696 | and ignore `same-window-regexps' and `same-window-buffer-names'. | 1705 | and ignore `same-window-regexps' and `same-window-buffer-names'. |
| 1706 | This function returns the buffer it switched to. | ||
| 1697 | This uses the function `display-buffer' as a subroutine; see the documentation | 1707 | This uses the function `display-buffer' as a subroutine; see the documentation |
| 1698 | of `display-buffer' for additional customization information. | 1708 | of `display-buffer' for additional customization information. |
| 1699 | 1709 | ||
diff --git a/src/window.c b/src/window.c index 5b4c8928232..b470b705397 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -395,7 +395,8 @@ decode_any_window (window) | |||
| 395 | } | 395 | } |
| 396 | 396 | ||
| 397 | DEFUN ("window-buffer", Fwindow_buffer, Swindow_buffer, 0, 1, 0, | 397 | DEFUN ("window-buffer", Fwindow_buffer, Swindow_buffer, 0, 1, 0, |
| 398 | doc: /* Return the buffer that WINDOW is displaying. */) | 398 | doc: /* Return the buffer that WINDOW is displaying. |
| 399 | WINDOW defaults to the selected window. */) | ||
| 399 | (window) | 400 | (window) |
| 400 | Lisp_Object window; | 401 | Lisp_Object window; |
| 401 | { | 402 | { |
| @@ -1749,8 +1750,8 @@ DEFUN ("other-window", Fother_window, Sother_window, 1, 2, "p", | |||
| 1749 | doc: /* Select the ARG'th different window on this frame. | 1750 | doc: /* Select the ARG'th different window on this frame. |
| 1750 | All windows on current frame are arranged in a cyclic order. | 1751 | All windows on current frame are arranged in a cyclic order. |
| 1751 | This command selects the window ARG steps away in that order. | 1752 | This command selects the window ARG steps away in that order. |
| 1752 | A negative ARG moves in the opposite order. If the optional second | 1753 | A negative ARG moves in the opposite order. The optional second |
| 1753 | argument ALL_FRAMES is non-nil, cycle through all frames. */) | 1754 | argument ALL_FRAMES has the same meaning as in `next-window', which see. */) |
| 1754 | (arg, all_frames) | 1755 | (arg, all_frames) |
| 1755 | Lisp_Object arg, all_frames; | 1756 | Lisp_Object arg, all_frames; |
| 1756 | { | 1757 | { |
| @@ -2068,6 +2069,7 @@ check_all_windows () | |||
| 2068 | DEFUN ("get-lru-window", Fget_lru_window, Sget_lru_window, 0, 1, 0, | 2069 | DEFUN ("get-lru-window", Fget_lru_window, Sget_lru_window, 0, 1, 0, |
| 2069 | doc: /* Return the window least recently selected or used for display. | 2070 | doc: /* Return the window least recently selected or used for display. |
| 2070 | Return a full-width window if possible. | 2071 | Return a full-width window if possible. |
| 2072 | A minibuffer window is never a candidate. | ||
| 2071 | If optional argument FRAME is `visible', search all visible frames. | 2073 | If optional argument FRAME is `visible', search all visible frames. |
| 2072 | If FRAME is 0, search all visible and iconified frames. | 2074 | If FRAME is 0, search all visible and iconified frames. |
| 2073 | If FRAME is t, search all frames. | 2075 | If FRAME is t, search all frames. |
| @@ -2087,6 +2089,7 @@ If FRAME is a frame, search only that frame. */) | |||
| 2087 | 2089 | ||
| 2088 | DEFUN ("get-largest-window", Fget_largest_window, Sget_largest_window, 0, 1, 0, | 2090 | DEFUN ("get-largest-window", Fget_largest_window, Sget_largest_window, 0, 1, 0, |
| 2089 | doc: /* Return the largest window in area. | 2091 | doc: /* Return the largest window in area. |
| 2092 | A minibuffer window is never a candidate. | ||
| 2090 | If optional argument FRAME is `visible', search all visible frames. | 2093 | If optional argument FRAME is `visible', search all visible frames. |
| 2091 | If FRAME is 0, search all visible and iconified frames. | 2094 | If FRAME is 0, search all visible and iconified frames. |
| 2092 | If FRAME is t, search all frames. | 2095 | If FRAME is t, search all frames. |
| @@ -2101,6 +2104,7 @@ If FRAME is a frame, search only that frame. */) | |||
| 2101 | 2104 | ||
| 2102 | DEFUN ("get-buffer-window", Fget_buffer_window, Sget_buffer_window, 1, 2, 0, | 2105 | DEFUN ("get-buffer-window", Fget_buffer_window, Sget_buffer_window, 1, 2, 0, |
| 2103 | doc: /* Return a window currently displaying BUFFER, or nil if none. | 2106 | doc: /* Return a window currently displaying BUFFER, or nil if none. |
| 2107 | BUFFER can be a buffer or a buffer name. | ||
| 2104 | If optional argument FRAME is `visible', search all visible frames. | 2108 | If optional argument FRAME is `visible', search all visible frames. |
| 2105 | If optional argument FRAME is 0, search all visible and iconified frames. | 2109 | If optional argument FRAME is 0, search all visible and iconified frames. |
| 2106 | If FRAME is t, search all frames. | 2110 | If FRAME is t, search all frames. |
| @@ -2183,6 +2187,7 @@ value is reasonable when this function is called. */) | |||
| 2183 | DEFUN ("delete-windows-on", Fdelete_windows_on, Sdelete_windows_on, | 2187 | DEFUN ("delete-windows-on", Fdelete_windows_on, Sdelete_windows_on, |
| 2184 | 1, 2, "bDelete windows on (buffer): ", | 2188 | 1, 2, "bDelete windows on (buffer): ", |
| 2185 | doc: /* Delete all windows showing BUFFER. | 2189 | doc: /* Delete all windows showing BUFFER. |
| 2190 | BUFFER must be a buffer or the name of an existing buffer. | ||
| 2186 | Optional second argument FRAME controls which frames are affected. | 2191 | Optional second argument FRAME controls which frames are affected. |
| 2187 | If optional argument FRAME is `visible', search all visible frames. | 2192 | If optional argument FRAME is `visible', search all visible frames. |
| 2188 | If FRAME is 0, search all visible and iconified frames. | 2193 | If FRAME is 0, search all visible and iconified frames. |
| @@ -2212,7 +2217,8 @@ If FRAME is a frame, search only that frame. */) | |||
| 2212 | DEFUN ("replace-buffer-in-windows", Freplace_buffer_in_windows, | 2217 | DEFUN ("replace-buffer-in-windows", Freplace_buffer_in_windows, |
| 2213 | Sreplace_buffer_in_windows, | 2218 | Sreplace_buffer_in_windows, |
| 2214 | 1, 1, "bReplace buffer in windows: ", | 2219 | 1, 1, "bReplace buffer in windows: ", |
| 2215 | doc: /* Replace BUFFER with some other buffer in all windows showing it. */) | 2220 | doc: /* Replace BUFFER with some other buffer in all windows showing it. |
| 2221 | BUFFER may be a buffer or the name of an existing buffer. */) | ||
| 2216 | (buffer) | 2222 | (buffer) |
| 2217 | Lisp_Object buffer; | 2223 | Lisp_Object buffer; |
| 2218 | { | 2224 | { |
| @@ -3024,7 +3030,7 @@ set_window_buffer (window, buffer, run_hooks_p, keep_margins_p) | |||
| 3024 | 3030 | ||
| 3025 | DEFUN ("set-window-buffer", Fset_window_buffer, Sset_window_buffer, 2, 3, 0, | 3031 | DEFUN ("set-window-buffer", Fset_window_buffer, Sset_window_buffer, 2, 3, 0, |
| 3026 | doc: /* Make WINDOW display BUFFER as its contents. | 3032 | doc: /* Make WINDOW display BUFFER as its contents. |
| 3027 | BUFFER can be a buffer or buffer name. | 3033 | BUFFER can be a buffer or the name of an existing buffer. |
| 3028 | Optional third arg KEEP-MARGINS non-nil means that WINDOW's current | 3034 | Optional third arg KEEP-MARGINS non-nil means that WINDOW's current |
| 3029 | display margins, fringe widths, and scroll bar settings are maintained; | 3035 | display margins, fringe widths, and scroll bar settings are maintained; |
| 3030 | the default is to reset these from BUFFER's local settings or the frame | 3036 | the default is to reset these from BUFFER's local settings or the frame |
| @@ -3065,7 +3071,7 @@ defaults. */) | |||
| 3065 | DEFUN ("select-window", Fselect_window, Sselect_window, 1, 2, 0, | 3071 | DEFUN ("select-window", Fselect_window, Sselect_window, 1, 2, 0, |
| 3066 | doc: /* Select WINDOW. Most editing will apply to WINDOW's buffer. | 3072 | doc: /* Select WINDOW. Most editing will apply to WINDOW's buffer. |
| 3067 | If WINDOW is not already selected, make WINDOW's buffer current | 3073 | If WINDOW is not already selected, make WINDOW's buffer current |
| 3068 | and make WINDOW the frame's selected window. | 3074 | and make WINDOW the frame's selected window. Return WINDOW. |
| 3069 | Optional second arg NORECORD non-nil means | 3075 | Optional second arg NORECORD non-nil means |
| 3070 | do not put this buffer at the front of the list of recently selected ones. | 3076 | do not put this buffer at the front of the list of recently selected ones. |
| 3071 | 3077 | ||
| @@ -3249,7 +3255,8 @@ See `same-window-buffer-names' and `same-window-regexps'. */) | |||
| 3249 | DEFUN ("display-buffer", Fdisplay_buffer, Sdisplay_buffer, 1, 3, | 3255 | DEFUN ("display-buffer", Fdisplay_buffer, Sdisplay_buffer, 1, 3, |
| 3250 | "BDisplay buffer: \nP", | 3256 | "BDisplay buffer: \nP", |
| 3251 | doc: /* Make BUFFER appear in some window but don't select it. | 3257 | doc: /* Make BUFFER appear in some window but don't select it. |
| 3252 | BUFFER can be a buffer or a buffer name. | 3258 | BUFFER must be the name of an existing buffer, or, when called from Lisp, |
| 3259 | a buffer. | ||
| 3253 | If BUFFER is shown already in some window, just use that one, | 3260 | If BUFFER is shown already in some window, just use that one, |
| 3254 | unless the window is the selected window and the optional second | 3261 | unless the window is the selected window and the optional second |
| 3255 | argument NOT-THIS-WINDOW is non-nil (interactively, with prefix arg). | 3262 | argument NOT-THIS-WINDOW is non-nil (interactively, with prefix arg). |
| @@ -3592,7 +3599,11 @@ WINDOW defaults to selected one and SIZE to half its size. | |||
| 3592 | If optional third arg HORFLAG is non-nil, split side by side | 3599 | If optional third arg HORFLAG is non-nil, split side by side |
| 3593 | and put SIZE columns in the first of the pair. In that case, | 3600 | and put SIZE columns in the first of the pair. In that case, |
| 3594 | SIZE includes that window's scroll bar, or the divider column to its right. | 3601 | SIZE includes that window's scroll bar, or the divider column to its right. |
| 3595 | Returns the newly-created window. */) | 3602 | Interactively, all arguments are nil. |
| 3603 | |||
| 3604 | Returns the newly created window (which is the lower or rightmost one). | ||
| 3605 | The upper or leftmost window is the original one and remains selected. | ||
| 3606 | See Info node `(elisp)Splitting Windows' for more details and examples.*/) | ||
| 3596 | (window, size, horflag) | 3607 | (window, size, horflag) |
| 3597 | Lisp_Object window, size, horflag; | 3608 | Lisp_Object window, size, horflag; |
| 3598 | { | 3609 | { |
| @@ -6457,7 +6468,9 @@ the buffer; `temp-buffer-show-hook' is not run unless this function runs it. */ | |||
| 6457 | DEFVAR_LISP ("display-buffer-function", &Vdisplay_buffer_function, | 6468 | DEFVAR_LISP ("display-buffer-function", &Vdisplay_buffer_function, |
| 6458 | doc: /* If non-nil, function to call to handle `display-buffer'. | 6469 | doc: /* If non-nil, function to call to handle `display-buffer'. |
| 6459 | It will receive two args, the buffer and a flag which if non-nil means | 6470 | It will receive two args, the buffer and a flag which if non-nil means |
| 6460 | that the currently selected window is not acceptable. | 6471 | that the currently selected window is not acceptable. |
| 6472 | It should choose or create a window, display the specified buffer in it, | ||
| 6473 | and return the window. | ||
| 6461 | Commands such as `switch-to-buffer-other-window' and `find-file-other-window' | 6474 | Commands such as `switch-to-buffer-other-window' and `find-file-other-window' |
| 6462 | work using this function. */); | 6475 | work using this function. */); |
| 6463 | Vdisplay_buffer_function = Qnil; | 6476 | Vdisplay_buffer_function = Qnil; |