diff options
| author | Martin Rudalics | 2008-10-19 13:50:25 +0000 |
|---|---|---|
| committer | Martin Rudalics | 2008-10-19 13:50:25 +0000 |
| commit | aac0c6e36567d1b1fcdf2d8fa95b3d5a84a3e6d7 (patch) | |
| tree | c6e82dcc4f2d4238dc0aff3d51cc8c567636bcf5 /src/window.c | |
| parent | 291703b5c724833ab8cc7e943ddc58f146b4bb1b (diff) | |
| download | emacs-aac0c6e36567d1b1fcdf2d8fa95b3d5a84a3e6d7.tar.gz emacs-aac0c6e36567d1b1fcdf2d8fa95b3d5a84a3e6d7.zip | |
(Fwindow_dedicated_p, Fset_window_dedicated_p):
Mention kill-buffer in doc-string.
(Fset_window_buffer): Reinsert tem check removed in last commit.
(Fenlarge_window, Fshrink_window): Have argument names and
doc-string follow Elisp manual more closely.
Diffstat (limited to 'src/window.c')
| -rw-r--r-- | src/window.c | 56 |
1 files changed, 32 insertions, 24 deletions
diff --git a/src/window.c b/src/window.c index 20b6ef846dc..58b8dd3b843 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -1268,8 +1268,8 @@ WINDOW defaults to the selected window. | |||
| 1268 | When a window is dedicated to its buffer, `display-buffer' and | 1268 | When a window is dedicated to its buffer, `display-buffer' and |
| 1269 | `set-window-buffer' will refrain from displaying another buffer in it. | 1269 | `set-window-buffer' will refrain from displaying another buffer in it. |
| 1270 | `get-lru-window' and `get-largest-window' treat dedicated windows | 1270 | `get-lru-window' and `get-largest-window' treat dedicated windows |
| 1271 | specially. `delete-windows-on' and `replace-buffer-in-windows' | 1271 | specially. `delete-windows-on', `replace-buffer-in-windows' and |
| 1272 | sometimes delete a dedicated window and the containing frame. */) | 1272 | `kill-buffer' can delete a dedicated window and the containing frame. */) |
| 1273 | (window) | 1273 | (window) |
| 1274 | Lisp_Object window; | 1274 | Lisp_Object window; |
| 1275 | { | 1275 | { |
| @@ -1286,8 +1286,8 @@ Return FLAG. | |||
| 1286 | When a window is dedicated to its buffer, `display-buffer' and | 1286 | When a window is dedicated to its buffer, `display-buffer' and |
| 1287 | `set-window-buffer' will refrain from displaying another buffer in it. | 1287 | `set-window-buffer' will refrain from displaying another buffer in it. |
| 1288 | `get-lru-window' and `get-largest-window' treat dedicated windows | 1288 | `get-lru-window' and `get-largest-window' treat dedicated windows |
| 1289 | specially. `delete-windows-on' and `replace-buffer-in-windows' | 1289 | specially. `delete-windows-on', `replace-buffer-in-windows' and |
| 1290 | sometimes delete a dedicated window and the containing frame. */) | 1290 | `kill-buffer' can delete a dedicated window and the containing frame. */) |
| 1291 | (window, flag) | 1291 | (window, flag) |
| 1292 | Lisp_Object window, flag; | 1292 | Lisp_Object window, flag; |
| 1293 | { | 1293 | { |
| @@ -3490,7 +3490,9 @@ This function runs the hook `window-scroll-functions'. */) | |||
| 3490 | error ("Attempt to display deleted buffer"); | 3490 | error ("Attempt to display deleted buffer"); |
| 3491 | 3491 | ||
| 3492 | tem = w->buffer; | 3492 | tem = w->buffer; |
| 3493 | if (!EQ (tem, Qt)) | 3493 | if (NILP (tem)) |
| 3494 | error ("Window is deleted"); | ||
| 3495 | else if (!EQ (tem, Qt)) | ||
| 3494 | /* w->buffer is t when the window is first being set up. */ | 3496 | /* w->buffer is t when the window is first being set up. */ |
| 3495 | { | 3497 | { |
| 3496 | if (!NILP (w->dedicated) && !EQ (tem, buffer)) | 3498 | if (!NILP (w->dedicated) && !EQ (tem, buffer)) |
| @@ -3887,17 +3889,19 @@ See Info node `(elisp)Splitting Windows' for more details and examples. */) | |||
| 3887 | } | 3889 | } |
| 3888 | 3890 | ||
| 3889 | DEFUN ("enlarge-window", Fenlarge_window, Senlarge_window, 1, 2, "p", | 3891 | DEFUN ("enlarge-window", Fenlarge_window, Senlarge_window, 1, 2, "p", |
| 3890 | doc: /* Make current window ARG lines bigger. | 3892 | doc: /* Make selected window SIZE lines taller. |
| 3891 | From program, optional second arg non-nil means grow sideways ARG columns. | 3893 | Interactively, if no argument is given, make the selected window one |
| 3892 | Interactively, if an argument is not given, make the window one line bigger. | 3894 | line taller. If optional argument HORIZONTAL is non-nil, make selected |
| 3893 | If HORIZONTAL is non-nil, enlarge horizontally instead of vertically. | 3895 | window wider by SIZE columns. If SIZE is negative, shrink the window by |
| 3894 | This function can delete windows, even the second window, if they get | 3896 | -SIZE lines or columns. Return nil. |
| 3895 | too small. */) | 3897 | |
| 3896 | (arg, horizontal) | 3898 | This function can delete windows if they get too small. The size of |
| 3897 | Lisp_Object arg, horizontal; | 3899 | fixed size windows is not altered by this function. */) |
| 3900 | (size, horizontal) | ||
| 3901 | Lisp_Object size, horizontal; | ||
| 3898 | { | 3902 | { |
| 3899 | CHECK_NUMBER (arg); | 3903 | CHECK_NUMBER (size); |
| 3900 | enlarge_window (selected_window, XINT (arg), !NILP (horizontal)); | 3904 | enlarge_window (selected_window, XINT (size), !NILP (horizontal)); |
| 3901 | 3905 | ||
| 3902 | run_window_configuration_change_hook (SELECTED_FRAME ()); | 3906 | run_window_configuration_change_hook (SELECTED_FRAME ()); |
| 3903 | 3907 | ||
| @@ -3905,15 +3909,19 @@ too small. */) | |||
| 3905 | } | 3909 | } |
| 3906 | 3910 | ||
| 3907 | DEFUN ("shrink-window", Fshrink_window, Sshrink_window, 1, 2, "p", | 3911 | DEFUN ("shrink-window", Fshrink_window, Sshrink_window, 1, 2, "p", |
| 3908 | doc: /* Make current window ARG lines smaller. | 3912 | doc: /* Make selected window SIZE lines smaller. |
| 3909 | From program, optional second arg non-nil means shrink sideways arg columns. | 3913 | Interactively, if no argument is given, make the selected window one |
| 3910 | Interactively, if an argument is not given, make the window one line smaller. | 3914 | line smaller. If optional argument HORIZONTAL is non-nil, make the |
| 3911 | Only siblings to the right or below are changed. */) | 3915 | window narrower by SIZE columns. If SIZE is negative, enlarge selected |
| 3912 | (arg, side) | 3916 | window by -SIZE lines or columns. Return nil. |
| 3913 | Lisp_Object arg, side; | 3917 | |
| 3914 | { | 3918 | This function can delete windows if they get too small. The size of |
| 3915 | CHECK_NUMBER (arg); | 3919 | fixed size windows is not altered by this function. */) |
| 3916 | enlarge_window (selected_window, -XINT (arg), !NILP (side)); | 3920 | (size, horizontal) |
| 3921 | Lisp_Object size, horizontal; | ||
| 3922 | { | ||
| 3923 | CHECK_NUMBER (size); | ||
| 3924 | enlarge_window (selected_window, -XINT (size), !NILP (horizontal)); | ||
| 3917 | 3925 | ||
| 3918 | run_window_configuration_change_hook (SELECTED_FRAME ()); | 3926 | run_window_configuration_change_hook (SELECTED_FRAME ()); |
| 3919 | 3927 | ||