aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMartin Rudalics2011-11-07 10:51:08 +0100
committerMartin Rudalics2011-11-07 10:51:08 +0100
commitbe7f55452c6d510d4ace634af0ada198a844b0ec (patch)
treecbec4dd675bff85a253bfac8438a950d5da0b06f /src
parentca78dc431fff3bc2a4f33f2a0fc1449608568d23 (diff)
downloademacs-be7f55452c6d510d4ace634af0ada198a844b0ec.tar.gz
emacs-be7f55452c6d510d4ace634af0ada198a844b0ec.zip
Remove term "subwindow" from code and documentation.
* window.h: Declare delete_all_child_windows instead of delete_all_subwindows. * window.c (Fwindow_nest, Fset_window_nest) (Fset_window_new_total, Fset_window_new_normal) (Fwindow_resize_apply): Don't use term subwindow in doc-strings. (delete_all_subwindows): Rename to delete_all_child_windows. (Fdelete_other_windows_internal, Fset_window_configuration): Call delete_all_child_windows instead of delete_all_subwindows. * frame.c (delete_frame): Call delete_all_child_windows instead of delete_all_subwindows. * window.el (window-combinations): Make WINDOW argument mandatory. Rewrite doc-string. (walk-window-subtree, window-atom-check, window-min-delta) (window-max-delta, window--resize-this-window) (window--resize-root-window-vertically, window-tree) (balance-windows, window-state-put): Rewrite doc-strings as to not mention the term "subwindow". (window--resize-subwindows-skip-p): Rename to window--resize-child-windows-skip-p. (window--resize-subwindows-normal): Rename to window--resize-child-windows-normal. (window--resize-subwindows): Rename to window--resize-child-windows. (window-or-subwindow-p): Rename to window--in-subtree-p. * windows.texi (Resizing Windows, Splitting Windows) (Window Configurations): Use "child window" instead of "subwindow".
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog13
-rw-r--r--src/frame.c2
-rw-r--r--src/window.c76
-rw-r--r--src/window.h2
4 files changed, 53 insertions, 40 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 3711292ad35..5b406a7bc46 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,16 @@
12011-11-07 Martin Rudalics <rudalics@gmx.at>
2
3 * window.h: Declare delete_all_child_windows instead of
4 delete_all_subwindows.
5 * window.c (Fwindow_nest, Fset_window_nest)
6 (Fset_window_new_total, Fset_window_new_normal)
7 (Fwindow_resize_apply): Don't use term subwindow in doc-strings.
8 (delete_all_subwindows): Rename to delete_all_child_windows.
9 (Fdelete_other_windows_internal, Fset_window_configuration):
10 Call delete_all_child_windows instead of delete_all_subwindows.
11 * frame.c (delete_frame): Call delete_all_child_windows instead
12 of delete_all_subwindows.
13
12011-11-07 Paul Eggert <eggert@cs.ucla.edu> 142011-11-07 Paul Eggert <eggert@cs.ucla.edu>
2 15
3 * alloc.c (DEADP): New macro, for porting to GNU/Hurd (Bug#9926). 16 * alloc.c (DEADP): New macro, for porting to GNU/Hurd (Bug#9926).
diff --git a/src/frame.c b/src/frame.c
index 112f102a1f2..d56a2efb17f 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -1320,7 +1320,7 @@ delete_frame (Lisp_Object frame, Lisp_Object force)
1320 1320
1321 /* Mark all the windows that used to be on FRAME as deleted, and then 1321 /* Mark all the windows that used to be on FRAME as deleted, and then
1322 remove the reference to them. */ 1322 remove the reference to them. */
1323 delete_all_subwindows (f->root_window); 1323 delete_all_child_windows (f->root_window);
1324 f->root_window = Qnil; 1324 f->root_window = Qnil;
1325 1325
1326 Vframe_list = Fdelq (frame, Vframe_list); 1326 Vframe_list = Fdelq (frame, Vframe_list);
diff --git a/src/window.c b/src/window.c
index 605d00b8e05..162ae08a00f 100644
--- a/src/window.c
+++ b/src/window.c
@@ -504,8 +504,8 @@ DEFUN ("window-nest", Fwindow_nest, Swindow_nest, 0, 1, 0,
504 doc: /* Return nest status of window WINDOW. 504 doc: /* Return nest status of window WINDOW.
505If WINDOW is omitted or nil, it defaults to the selected window. 505If WINDOW is omitted or nil, it defaults to the selected window.
506 506
507If the return value is nil, subwindows of WINDOW can be recombined with 507If the return value is nil, child windows of WINDOW can be recombined with
508WINDOW's siblings. A return value of non-nil means that subwindows of 508WINDOW's siblings. A return value of non-nil means that child windows of
509WINDOW are never \(re-)combined with WINDOW's siblings. */) 509WINDOW are never \(re-)combined with WINDOW's siblings. */)
510 (Lisp_Object window) 510 (Lisp_Object window)
511{ 511{
@@ -516,8 +516,8 @@ DEFUN ("set-window-nest", Fset_window_nest, Sset_window_nest, 2, 2, 0,
516 doc: /* Set nest status of window WINDOW to STATUS; return STATUS. 516 doc: /* Set nest status of window WINDOW to STATUS; return STATUS.
517If WINDOW is omitted or nil, it defaults to the selected window. 517If WINDOW is omitted or nil, it defaults to the selected window.
518 518
519If STATUS is nil, subwindows of WINDOW can be recombined with WINDOW's 519If STATUS is nil, child windows of WINDOW can be recombined with WINDOW's
520siblings. STATUS non-nil means that subwindows of WINDOW are never 520siblings. STATUS non-nil means that child windows of WINDOW are never
521\(re-)combined with WINDOW's siblings. */) 521\(re-)combined with WINDOW's siblings. */)
522 (Lisp_Object window, Lisp_Object status) 522 (Lisp_Object window, Lisp_Object status)
523{ 523{
@@ -2571,9 +2571,9 @@ DEFUN ("delete-other-windows-internal", Fdelete_other_windows_internal,
2571Only the frame WINDOW is on is affected. WINDOW may be any window and 2571Only the frame WINDOW is on is affected. WINDOW may be any window and
2572defaults to the selected one. 2572defaults to the selected one.
2573 2573
2574Optional argument ROOT, if non-nil, must specify an internal window 2574Optional argument ROOT, if non-nil, must specify an internal window such
2575containing WINDOW as a subwindow. If this is the case, replace ROOT by 2575that WINDOW is in its window subtree. If this is the case, replace ROOT
2576WINDOW and leave alone any windows not contained in ROOT. 2576by WINDOW and leave alone any windows not part of ROOT's subtree.
2577 2577
2578When WINDOW is live try to reduce display jumps by keeping the text 2578When WINDOW is live try to reduce display jumps by keeping the text
2579previously visible in WINDOW in the same place on the frame. Doing this 2579previously visible in WINDOW in the same place on the frame. Doing this
@@ -2637,10 +2637,10 @@ window-start value is reasonable when this function is called. */)
2637 } 2637 }
2638 else 2638 else
2639 { 2639 {
2640 /* See if the frame's selected window is a subwindow of WINDOW, by 2640 /* See if the frame's selected window is a part of the window
2641 finding all the selected window's parents and comparing each 2641 subtree rooted at WINDOW, by finding all the selected window's
2642 one with WINDOW. If it isn't we need a new selected window for 2642 parents and comparing each one with WINDOW. If it isn't we
2643 this frame. */ 2643 need a new selected window for this frame. */
2644 swindow = FRAME_SELECTED_WINDOW (f); 2644 swindow = FRAME_SELECTED_WINDOW (f);
2645 while (1) 2645 while (1)
2646 { 2646 {
@@ -2676,7 +2676,7 @@ window-start value is reasonable when this function is called. */)
2676 2676
2677 if (NILP (w->buffer)) 2677 if (NILP (w->buffer))
2678 { 2678 {
2679 /* Resize subwindows vertically. */ 2679 /* Resize child windows vertically. */
2680 XSETINT (delta, XINT (r->total_lines) - XINT (w->total_lines)); 2680 XSETINT (delta, XINT (r->total_lines) - XINT (w->total_lines));
2681 w->top_line = r->top_line; 2681 w->top_line = r->top_line;
2682 resize_root_window (window, delta, Qnil, Qnil); 2682 resize_root_window (window, delta, Qnil, Qnil);
@@ -2691,7 +2691,7 @@ window-start value is reasonable when this function is called. */)
2691 resize_failed = 1; 2691 resize_failed = 1;
2692 } 2692 }
2693 2693
2694 /* Resize subwindows horizontally. */ 2694 /* Resize child windows horizontally. */
2695 if (!resize_failed) 2695 if (!resize_failed)
2696 { 2696 {
2697 w->left_col = r->left_col; 2697 w->left_col = r->left_col;
@@ -2740,15 +2740,15 @@ window-start value is reasonable when this function is called. */)
2740 XWINDOW (w->parent)->hchild = sibling; 2740 XWINDOW (w->parent)->hchild = sibling;
2741 } 2741 }
2742 2742
2743 /* Delete ROOT and all subwindows of ROOT. */ 2743 /* Delete ROOT and all child windows of ROOT. */
2744 if (!NILP (r->vchild)) 2744 if (!NILP (r->vchild))
2745 { 2745 {
2746 delete_all_subwindows (r->vchild); 2746 delete_all_child_windows (r->vchild);
2747 r->vchild = Qnil; 2747 r->vchild = Qnil;
2748 } 2748 }
2749 else if (!NILP (r->hchild)) 2749 else if (!NILP (r->hchild))
2750 { 2750 {
2751 delete_all_subwindows (r->hchild); 2751 delete_all_child_windows (r->hchild);
2752 r->hchild = Qnil; 2752 r->hchild = Qnil;
2753 } 2753 }
2754 2754
@@ -3349,7 +3349,7 @@ Return SIZE.
3349Optional argument ADD non-nil means add SIZE to the new total size of 3349Optional argument ADD non-nil means add SIZE to the new total size of
3350WINDOW and return the sum. 3350WINDOW and return the sum.
3351 3351
3352Note: This function does not operate on any subwindows of WINDOW. */) 3352Note: This function does not operate on any child windows of WINDOW. */)
3353 (Lisp_Object window, Lisp_Object size, Lisp_Object add) 3353 (Lisp_Object window, Lisp_Object size, Lisp_Object add)
3354{ 3354{
3355 struct window *w = decode_any_window (window); 3355 struct window *w = decode_any_window (window);
@@ -3367,7 +3367,7 @@ DEFUN ("set-window-new-normal", Fset_window_new_normal, Sset_window_new_normal,
3367 doc: /* Set new normal size of WINDOW to SIZE. 3367 doc: /* Set new normal size of WINDOW to SIZE.
3368Return SIZE. 3368Return SIZE.
3369 3369
3370Note: This function does not operate on any subwindows of WINDOW. */) 3370Note: This function does not operate on any child windows of WINDOW. */)
3371 (Lisp_Object window, Lisp_Object size) 3371 (Lisp_Object window, Lisp_Object size)
3372{ 3372{
3373 struct window *w = decode_any_window (window); 3373 struct window *w = decode_any_window (window);
@@ -3378,7 +3378,7 @@ Note: This function does not operate on any subwindows of WINDOW. */)
3378 3378
3379/* Return 1 if setting w->total_lines (w->total_cols if HORFLAG is 3379/* Return 1 if setting w->total_lines (w->total_cols if HORFLAG is
3380 non-zero) to w->new_total would result in correct heights (widths) 3380 non-zero) to w->new_total would result in correct heights (widths)
3381 for window W and recursively all subwindows of W. 3381 for window W and recursively all child windows of W.
3382 3382
3383 Note: This function does not check any of `window-fixed-size-p', 3383 Note: This function does not check any of `window-fixed-size-p',
3384 `window-min-height' or `window-min-width'. It does check that window 3384 `window-min-height' or `window-min-width'. It does check that window
@@ -3393,7 +3393,7 @@ window_resize_check (struct window *w, int horflag)
3393 { 3393 {
3394 c = XWINDOW (w->vchild); 3394 c = XWINDOW (w->vchild);
3395 if (horflag) 3395 if (horflag)
3396 /* All subwindows of W must have the same width as W. */ 3396 /* All child windows of W must have the same width as W. */
3397 { 3397 {
3398 while (c) 3398 while (c)
3399 { 3399 {
@@ -3405,8 +3405,8 @@ window_resize_check (struct window *w, int horflag)
3405 return 1; 3405 return 1;
3406 } 3406 }
3407 else 3407 else
3408 /* The sum of the heights of the subwindows of W must equal W's 3408 /* The sum of the heights of the child windows of W must equal
3409 height. */ 3409 W's height. */
3410 { 3410 {
3411 int sum_of_sizes = 0; 3411 int sum_of_sizes = 0;
3412 while (c) 3412 while (c)
@@ -3424,7 +3424,7 @@ window_resize_check (struct window *w, int horflag)
3424 { 3424 {
3425 c = XWINDOW (w->hchild); 3425 c = XWINDOW (w->hchild);
3426 if (horflag) 3426 if (horflag)
3427 /* The sum of the widths of the subwindows of W must equal W's 3427 /* The sum of the widths of the child windows of W must equal W's
3428 width. */ 3428 width. */
3429 { 3429 {
3430 int sum_of_sizes = 0; 3430 int sum_of_sizes = 0;
@@ -3438,7 +3438,7 @@ window_resize_check (struct window *w, int horflag)
3438 return (sum_of_sizes == XINT (w->new_total)); 3438 return (sum_of_sizes == XINT (w->new_total));
3439 } 3439 }
3440 else 3440 else
3441 /* All subwindows of W must have the same height as W. */ 3441 /* All child windows of W must have the same height as W. */
3442 { 3442 {
3443 while (c) 3443 while (c)
3444 { 3444 {
@@ -3458,9 +3458,9 @@ window_resize_check (struct window *w, int horflag)
3458} 3458}
3459 3459
3460/* Set w->total_lines (w->total_cols if HORIZONTAL is non-zero) to 3460/* Set w->total_lines (w->total_cols if HORIZONTAL is non-zero) to
3461 w->new_total for window W and recursively all subwindows of W. Also 3461 w->new_total for window W and recursively all child windows of W.
3462 calculate and assign the new vertical (horizontal) start positions of 3462 Also calculate and assign the new vertical (horizontal) start
3463 each of these windows. 3463 positions of each of these windows.
3464 3464
3465 This function does not perform any error checks. Make sure you have 3465 This function does not perform any error checks. Make sure you have
3466 run window_resize_check on W before applying this function. */ 3466 run window_resize_check on W before applying this function. */
@@ -3534,8 +3534,8 @@ Optional argument HORIZONTAL omitted or nil means apply requested height
3534values. HORIZONTAL non-nil means apply requested width values. 3534values. HORIZONTAL non-nil means apply requested width values.
3535 3535
3536This function checks whether the requested values sum up to a valid 3536This function checks whether the requested values sum up to a valid
3537window layout, recursively assigns the new sizes of all subwindows and 3537window layout, recursively assigns the new sizes of all child windows
3538calculates and assigns the new start positions of these windows. 3538and calculates and assigns the new start positions of these windows.
3539 3539
3540Note: This function does not check any of `window-fixed-size-p', 3540Note: This function does not check any of `window-fixed-size-p',
3541`window-min-height' or `window-min-width'. All these checks have to 3541`window-min-height' or `window-min-width'. All these checks have to
@@ -3931,12 +3931,12 @@ Signal an error when WINDOW is the only window on its frame. */)
3931 3931
3932 if (!NILP (w->vchild)) 3932 if (!NILP (w->vchild))
3933 { 3933 {
3934 delete_all_subwindows (w->vchild); 3934 delete_all_child_windows (w->vchild);
3935 w->vchild = Qnil; 3935 w->vchild = Qnil;
3936 } 3936 }
3937 else if (!NILP (w->hchild)) 3937 else if (!NILP (w->hchild))
3938 { 3938 {
3939 delete_all_subwindows (w->hchild); 3939 delete_all_child_windows (w->hchild);
3940 w->hchild = Qnil; 3940 w->hchild = Qnil;
3941 } 3941 }
3942 else if (!NILP (w->buffer)) 3942 else if (!NILP (w->buffer))
@@ -5515,7 +5515,7 @@ the return value is nil. Otherwise the value is t. */)
5515 Save their current buffers in their height fields, since we may 5515 Save their current buffers in their height fields, since we may
5516 need it later, if a buffer saved in the configuration is now 5516 need it later, if a buffer saved in the configuration is now
5517 dead. */ 5517 dead. */
5518 delete_all_subwindows (FRAME_ROOT_WINDOW (f)); 5518 delete_all_child_windows (FRAME_ROOT_WINDOW (f));
5519 5519
5520 for (k = 0; k < saved_windows->header.size; k++) 5520 for (k = 0; k < saved_windows->header.size; k++)
5521 { 5521 {
@@ -5729,10 +5729,10 @@ the return value is nil. Otherwise the value is t. */)
5729} 5729}
5730 5730
5731 5731
5732/* Delete all subwindows reachable via the next, vchild, and hchild 5732/* Recursively delete all child windows reachable via the next, vchild,
5733 slots of WINDOW. */ 5733 and hchild slots of WINDOW. */
5734void 5734void
5735delete_all_subwindows (Lisp_Object window) 5735delete_all_child_windows (Lisp_Object window)
5736{ 5736{
5737 register struct window *w; 5737 register struct window *w;
5738 5738
@@ -5740,18 +5740,18 @@ delete_all_subwindows (Lisp_Object window)
5740 5740
5741 if (!NILP (w->next)) 5741 if (!NILP (w->next))
5742 /* Delete WINDOW's siblings (we traverse postorderly). */ 5742 /* Delete WINDOW's siblings (we traverse postorderly). */
5743 delete_all_subwindows (w->next); 5743 delete_all_child_windows (w->next);
5744 5744
5745 w->total_lines = w->buffer; /* See Fset_window_configuration for excuse. */ 5745 w->total_lines = w->buffer; /* See Fset_window_configuration for excuse. */
5746 5746
5747 if (!NILP (w->vchild)) 5747 if (!NILP (w->vchild))
5748 { 5748 {
5749 delete_all_subwindows (w->vchild); 5749 delete_all_child_windows (w->vchild);
5750 w->vchild = Qnil; 5750 w->vchild = Qnil;
5751 } 5751 }
5752 else if (!NILP (w->hchild)) 5752 else if (!NILP (w->hchild))
5753 { 5753 {
5754 delete_all_subwindows (w->hchild); 5754 delete_all_child_windows (w->hchild);
5755 w->hchild = Qnil; 5755 w->hchild = Qnil;
5756 } 5756 }
5757 else if (!NILP (w->buffer)) 5757 else if (!NILP (w->buffer))
diff --git a/src/window.h b/src/window.h
index c6fa5e7a338..6a9641e3e6d 100644
--- a/src/window.h
+++ b/src/window.h
@@ -824,7 +824,7 @@ extern Lisp_Object window_from_coordinates (struct frame *, int, int,
824 enum window_part *, int); 824 enum window_part *, int);
825EXFUN (Fwindow_dedicated_p, 1); 825EXFUN (Fwindow_dedicated_p, 1);
826extern void resize_frame_windows (struct frame *, int, int); 826extern void resize_frame_windows (struct frame *, int, int);
827extern void delete_all_subwindows (Lisp_Object); 827extern void delete_all_child_windows (Lisp_Object);
828extern void freeze_window_starts (struct frame *, int); 828extern void freeze_window_starts (struct frame *, int);
829extern void grow_mini_window (struct window *, int); 829extern void grow_mini_window (struct window *, int);
830extern void shrink_mini_window (struct window *); 830extern void shrink_mini_window (struct window *);