diff options
Diffstat (limited to 'src/window.c')
| -rw-r--r-- | src/window.c | 194 |
1 files changed, 72 insertions, 122 deletions
diff --git a/src/window.c b/src/window.c index b21671b4153..a7daa1353bd 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -467,67 +467,33 @@ Return nil if WINDOW has no previous sibling. */) | |||
| 467 | return decode_any_window (window)->prev; | 467 | return decode_any_window (window)->prev; |
| 468 | } | 468 | } |
| 469 | 469 | ||
| 470 | DEFUN ("window-splits", Fwindow_splits, Swindow_splits, 0, 1, 0, | 470 | DEFUN ("window-combination-limit", Fwindow_combination_limit, Swindow_combination_limit, 0, 1, 0, |
| 471 | doc: /* Return splits status for the window WINDOW. | 471 | doc: /* Return combination limit of window WINDOW. |
| 472 | If WINDOW is omitted or nil, it defaults to the selected window. | ||
| 473 | |||
| 474 | If the value returned by this function is nil and WINDOW is resized, the | ||
| 475 | corresponding space is preferably taken from (or given to) WINDOW's | ||
| 476 | right sibling. When WINDOW is deleted, its space is given to its left | ||
| 477 | sibling. | ||
| 478 | |||
| 479 | If the value returned by this function is non-nil, resizing and deleting | ||
| 480 | WINDOW may resize all windows in the same combination. */) | ||
| 481 | (Lisp_Object window) | ||
| 482 | { | ||
| 483 | return decode_any_window (window)->splits; | ||
| 484 | } | ||
| 485 | |||
| 486 | DEFUN ("set-window-splits", Fset_window_splits, Sset_window_splits, 2, 2, 0, | ||
| 487 | doc: /* Set splits status of window WINDOW to STATUS. | ||
| 488 | If WINDOW is omitted or nil, it defaults to the selected window. | ||
| 489 | |||
| 490 | If STATUS is nil and WINDOW is later resized, the corresponding space is | ||
| 491 | preferably taken from (or given to) WINDOW's right sibling. When WINDOW | ||
| 492 | is deleted, its space is given to its left sibling. | ||
| 493 | |||
| 494 | If STATUS is non-nil, resizing and deleting WINDOW may resize all | ||
| 495 | windows in the same combination. */) | ||
| 496 | (Lisp_Object window, Lisp_Object status) | ||
| 497 | { | ||
| 498 | register struct window *w = decode_any_window (window); | ||
| 499 | |||
| 500 | w->splits = status; | ||
| 501 | |||
| 502 | return w->splits; | ||
| 503 | } | ||
| 504 | |||
| 505 | DEFUN ("window-nest", Fwindow_nest, Swindow_nest, 0, 1, 0, | ||
| 506 | doc: /* Return nest status of window WINDOW. | ||
| 507 | If WINDOW is omitted or nil, it defaults to the selected window. | 472 | If WINDOW is omitted or nil, it defaults to the selected window. |
| 508 | 473 | ||
| 509 | If the return value is nil, child windows of WINDOW can be recombined with | 474 | If the return value is nil, child windows of WINDOW can be recombined with |
| 510 | WINDOW's siblings. A return value of non-nil means that child windows of | 475 | WINDOW's siblings. A return value of t means that child windows of |
| 511 | WINDOW are never \(re-)combined with WINDOW's siblings. */) | 476 | WINDOW are never \(re-)combined with WINDOW's siblings. */) |
| 512 | (Lisp_Object window) | 477 | (Lisp_Object window) |
| 513 | { | 478 | { |
| 514 | return decode_any_window (window)->nest; | 479 | return decode_any_window (window)->combination_limit; |
| 515 | } | 480 | } |
| 516 | 481 | ||
| 517 | DEFUN ("set-window-nest", Fset_window_nest, Sset_window_nest, 2, 2, 0, | 482 | DEFUN ("set-window-combination-limit", Fset_window_combination_limit, Sset_window_combination_limit, 2, 2, 0, |
| 518 | doc: /* Set nest status of window WINDOW to STATUS; return STATUS. | 483 | doc: /* Set combination limit of window WINDOW to STATUS; return STATUS. |
| 519 | If WINDOW is omitted or nil, it defaults to the selected window. | 484 | If WINDOW is omitted or nil, it defaults to the selected window. |
| 520 | 485 | ||
| 521 | If STATUS is nil, child windows of WINDOW can be recombined with WINDOW's | 486 | If STATUS is nil, child windows of WINDOW can be recombined with |
| 522 | siblings. STATUS non-nil means that child windows of WINDOW are never | 487 | WINDOW's siblings. STATUS t means that child windows of WINDOW are |
| 523 | \(re-)combined with WINDOW's siblings. */) | 488 | never \(re-)combined with WINDOW's siblings. Other values are reserved |
| 489 | for future use. */) | ||
| 524 | (Lisp_Object window, Lisp_Object status) | 490 | (Lisp_Object window, Lisp_Object status) |
| 525 | { | 491 | { |
| 526 | register struct window *w = decode_any_window (window); | 492 | register struct window *w = decode_any_window (window); |
| 527 | 493 | ||
| 528 | w->nest = status; | 494 | w->combination_limit = status; |
| 529 | 495 | ||
| 530 | return w->nest; | 496 | return w->combination_limit; |
| 531 | } | 497 | } |
| 532 | 498 | ||
| 533 | DEFUN ("window-use-time", Fwindow_use_time, Swindow_use_time, 0, 1, 0, | 499 | DEFUN ("window-use-time", Fwindow_use_time, Swindow_use_time, 0, 1, 0, |
| @@ -861,7 +827,7 @@ The inside edges do not include the space used by the WINDOW's scroll | |||
| 861 | bar, display margins, fringes, header line, and/or mode line. */) | 827 | bar, display margins, fringes, header line, and/or mode line. */) |
| 862 | (Lisp_Object window) | 828 | (Lisp_Object window) |
| 863 | { | 829 | { |
| 864 | register struct window *w = decode_any_window (window); | 830 | register struct window *w = decode_window (window); |
| 865 | 831 | ||
| 866 | return list4 (make_number (WINDOW_BOX_LEFT_EDGE_COL (w) | 832 | return list4 (make_number (WINDOW_BOX_LEFT_EDGE_COL (w) |
| 867 | + WINDOW_LEFT_MARGIN_COLS (w) | 833 | + WINDOW_LEFT_MARGIN_COLS (w) |
| @@ -876,9 +842,9 @@ bar, display margins, fringes, header line, and/or mode line. */) | |||
| 876 | } | 842 | } |
| 877 | 843 | ||
| 878 | DEFUN ("window-inside-pixel-edges", Fwindow_inside_pixel_edges, Swindow_inside_pixel_edges, 0, 1, 0, | 844 | DEFUN ("window-inside-pixel-edges", Fwindow_inside_pixel_edges, Swindow_inside_pixel_edges, 0, 1, 0, |
| 879 | doc: /* Return a list of the edge pixel coordinates of WINDOW. | 845 | doc: /* Return a list of the edge pixel coordinates of WINDOW's text area. |
| 880 | The list has the form (LEFT TOP RIGHT BOTTOM), all relative to 0, 0 at | 846 | The list has the form (LEFT TOP RIGHT BOTTOM), all relative to (0,0) |
| 881 | the top left corner of the frame. | 847 | at the top left corner of the frame's window area. |
| 882 | 848 | ||
| 883 | RIGHT is one more than the rightmost x position of WINDOW's text area. | 849 | RIGHT is one more than the rightmost x position of WINDOW's text area. |
| 884 | BOTTOM is one more than the bottommost y position of WINDOW's text area. | 850 | BOTTOM is one more than the bottommost y position of WINDOW's text area. |
| @@ -886,7 +852,7 @@ The inside edges do not include the space used by WINDOW's scroll bar, | |||
| 886 | display margins, fringes, header line, and/or mode line. */) | 852 | display margins, fringes, header line, and/or mode line. */) |
| 887 | (Lisp_Object window) | 853 | (Lisp_Object window) |
| 888 | { | 854 | { |
| 889 | register struct window *w = decode_any_window (window); | 855 | register struct window *w = decode_window (window); |
| 890 | 856 | ||
| 891 | return list4 (make_number (WINDOW_BOX_LEFT_EDGE_X (w) | 857 | return list4 (make_number (WINDOW_BOX_LEFT_EDGE_X (w) |
| 892 | + WINDOW_LEFT_MARGIN_WIDTH (w) | 858 | + WINDOW_LEFT_MARGIN_WIDTH (w) |
| @@ -903,9 +869,9 @@ display margins, fringes, header line, and/or mode line. */) | |||
| 903 | DEFUN ("window-inside-absolute-pixel-edges", | 869 | DEFUN ("window-inside-absolute-pixel-edges", |
| 904 | Fwindow_inside_absolute_pixel_edges, | 870 | Fwindow_inside_absolute_pixel_edges, |
| 905 | Swindow_inside_absolute_pixel_edges, 0, 1, 0, | 871 | Swindow_inside_absolute_pixel_edges, 0, 1, 0, |
| 906 | doc: /* Return a list of the edge pixel coordinates of WINDOW. | 872 | doc: /* Return a list of the edge pixel coordinates of WINDOW's text area. |
| 907 | The list has the form (LEFT TOP RIGHT BOTTOM), all relative to 0, 0 at | 873 | The list has the form (LEFT TOP RIGHT BOTTOM), all relative to (0,0) |
| 908 | the top left corner of the display. | 874 | at the top left corner of the frame's window area. |
| 909 | 875 | ||
| 910 | RIGHT is one more than the rightmost x position of WINDOW's text area. | 876 | RIGHT is one more than the rightmost x position of WINDOW's text area. |
| 911 | BOTTOM is one more than the bottommost y position of WINDOW's text area. | 877 | BOTTOM is one more than the bottommost y position of WINDOW's text area. |
| @@ -913,7 +879,7 @@ The inside edges do not include the space used by WINDOW's scroll bar, | |||
| 913 | display margins, fringes, header line, and/or mode line. */) | 879 | display margins, fringes, header line, and/or mode line. */) |
| 914 | (Lisp_Object window) | 880 | (Lisp_Object window) |
| 915 | { | 881 | { |
| 916 | register struct window *w = decode_any_window (window); | 882 | register struct window *w = decode_window (window); |
| 917 | int add_x, add_y; | 883 | int add_x, add_y; |
| 918 | calc_absolute_offset (w, &add_x, &add_y); | 884 | calc_absolute_offset (w, &add_x, &add_y); |
| 919 | 885 | ||
| @@ -1916,7 +1882,7 @@ recombine_windows (Lisp_Object window) | |||
| 1916 | 1882 | ||
| 1917 | w = XWINDOW (window); | 1883 | w = XWINDOW (window); |
| 1918 | parent = w->parent; | 1884 | parent = w->parent; |
| 1919 | if (!NILP (parent) && NILP (w->nest)) | 1885 | if (!NILP (parent) && NILP (w->combination_limit)) |
| 1920 | { | 1886 | { |
| 1921 | p = XWINDOW (parent); | 1887 | p = XWINDOW (parent); |
| 1922 | if (((!NILP (p->vchild) && !NILP (w->vchild)) | 1888 | if (((!NILP (p->vchild) && !NILP (w->vchild)) |
| @@ -2381,7 +2347,7 @@ Anything else means consider all windows on WINDOW's frame and no | |||
| 2381 | others. | 2347 | others. |
| 2382 | 2348 | ||
| 2383 | If WINDOW is not on the list of windows returned, some other window will | 2349 | If WINDOW is not on the list of windows returned, some other window will |
| 2384 | be listed first but no error is signalled. */) | 2350 | be listed first but no error is signaled. */) |
| 2385 | (Lisp_Object window, Lisp_Object minibuf, Lisp_Object all_frames) | 2351 | (Lisp_Object window, Lisp_Object minibuf, Lisp_Object all_frames) |
| 2386 | { | 2352 | { |
| 2387 | return window_list_1 (window, minibuf, all_frames); | 2353 | return window_list_1 (window, minibuf, all_frames); |
| @@ -2771,9 +2737,6 @@ window-start value is reasonable when this function is called. */) | |||
| 2771 | 2737 | ||
| 2772 | replace_window (root, window, 1); | 2738 | replace_window (root, window, 1); |
| 2773 | 2739 | ||
| 2774 | /* Reset WINDOW's splits status. */ | ||
| 2775 | w->splits = Qnil; | ||
| 2776 | |||
| 2777 | /* This must become SWINDOW anyway ....... */ | 2740 | /* This must become SWINDOW anyway ....... */ |
| 2778 | if (!NILP (w->buffer) && !resize_failed) | 2741 | if (!NILP (w->buffer) && !resize_failed) |
| 2779 | { | 2742 | { |
| @@ -3288,8 +3251,7 @@ make_parent_window (Lisp_Object window, int horflag) | |||
| 3288 | p->start = Qnil; | 3251 | p->start = Qnil; |
| 3289 | p->pointm = Qnil; | 3252 | p->pointm = Qnil; |
| 3290 | p->buffer = Qnil; | 3253 | p->buffer = Qnil; |
| 3291 | p->splits = Qnil; | 3254 | p->combination_limit = Qnil; |
| 3292 | p->nest = Qnil; | ||
| 3293 | p->window_parameters = Qnil; | 3255 | p->window_parameters = Qnil; |
| 3294 | } | 3256 | } |
| 3295 | 3257 | ||
| @@ -3336,7 +3298,7 @@ make_window (void) | |||
| 3336 | w->start_at_line_beg = w->display_table = w->dedicated = Qnil; | 3298 | w->start_at_line_beg = w->display_table = w->dedicated = Qnil; |
| 3337 | w->base_line_number = w->base_line_pos = w->region_showing = Qnil; | 3299 | w->base_line_number = w->base_line_pos = w->region_showing = Qnil; |
| 3338 | w->column_number_displayed = w->redisplay_end_trigger = Qnil; | 3300 | w->column_number_displayed = w->redisplay_end_trigger = Qnil; |
| 3339 | w->splits = w->nest = w->window_parameters = Qnil; | 3301 | w->combination_limit = w->window_parameters = Qnil; |
| 3340 | w->prev_buffers = w->next_buffers = Qnil; | 3302 | w->prev_buffers = w->next_buffers = Qnil; |
| 3341 | /* Initialize non-Lisp data. */ | 3303 | /* Initialize non-Lisp data. */ |
| 3342 | w->desired_matrix = w->current_matrix = 0; | 3304 | w->desired_matrix = w->current_matrix = 0; |
| @@ -3709,7 +3671,7 @@ set correctly. See the code of `split-window' for how this is done. */) | |||
| 3709 | int horflag | 3671 | int horflag |
| 3710 | /* HORFLAG is 1 when we split side-by-side, 0 otherwise. */ | 3672 | /* HORFLAG is 1 when we split side-by-side, 0 otherwise. */ |
| 3711 | = EQ (side, Qt) || EQ (side, Qleft) || EQ (side, Qright); | 3673 | = EQ (side, Qt) || EQ (side, Qleft) || EQ (side, Qright); |
| 3712 | int do_nest = 0; | 3674 | int combination_limit = 0; |
| 3713 | 3675 | ||
| 3714 | CHECK_WINDOW (old); | 3676 | CHECK_WINDOW (old); |
| 3715 | o = XWINDOW (old); | 3677 | o = XWINDOW (old); |
| @@ -3718,11 +3680,11 @@ set correctly. See the code of `split-window' for how this is done. */) | |||
| 3718 | 3680 | ||
| 3719 | CHECK_NUMBER (total_size); | 3681 | CHECK_NUMBER (total_size); |
| 3720 | 3682 | ||
| 3721 | /* Set do_nest to 1 if we have to make a new parent window. We do | 3683 | /* Set combination_limit to 1 if we have to make a new parent window. |
| 3722 | that if either `window-nest' is non-nil, or OLD has no parent, or | 3684 | We do that if either `window-combination-limit' is t, or OLD has no |
| 3723 | OLD is ortho-combined. */ | 3685 | parent, or OLD is ortho-combined. */ |
| 3724 | do_nest = | 3686 | combination_limit = |
| 3725 | !NILP (Vwindow_nest) | 3687 | !NILP (Vwindow_combination_limit) |
| 3726 | || NILP (o->parent) | 3688 | || NILP (o->parent) |
| 3727 | || NILP (horflag | 3689 | || NILP (horflag |
| 3728 | ? (XWINDOW (o->parent)->hchild) | 3690 | ? (XWINDOW (o->parent)->hchild) |
| @@ -3742,8 +3704,8 @@ set correctly. See the code of `split-window' for how this is done. */) | |||
| 3742 | error ("Attempt to split minibuffer window"); | 3704 | error ("Attempt to split minibuffer window"); |
| 3743 | else if (XINT (total_size) < (horflag ? 2 : 1)) | 3705 | else if (XINT (total_size) < (horflag ? 2 : 1)) |
| 3744 | error ("Size of new window too small (after split)"); | 3706 | error ("Size of new window too small (after split)"); |
| 3745 | else if (!do_nest && !NILP (Vwindow_splits)) | 3707 | else if (!combination_limit && !NILP (Vwindow_combination_resize)) |
| 3746 | /* `window-splits' non-nil means try to resize OLD's siblings | 3708 | /* `window-combination-resize' non-nil means try to resize OLD's siblings |
| 3747 | proportionally. */ | 3709 | proportionally. */ |
| 3748 | { | 3710 | { |
| 3749 | p = XWINDOW (o->parent); | 3711 | p = XWINDOW (o->parent); |
| @@ -3767,7 +3729,7 @@ set correctly. See the code of `split-window' for how this is done. */) | |||
| 3767 | } | 3729 | } |
| 3768 | 3730 | ||
| 3769 | /* This is our point of no return. */ | 3731 | /* This is our point of no return. */ |
| 3770 | if (do_nest) | 3732 | if (combination_limit) |
| 3771 | { | 3733 | { |
| 3772 | /* Save the old value of o->normal_cols/lines. It gets corrupted | 3734 | /* Save the old value of o->normal_cols/lines. It gets corrupted |
| 3773 | by make_parent_window and we need it below for assigning it to | 3735 | by make_parent_window and we need it below for assigning it to |
| @@ -3776,12 +3738,9 @@ set correctly. See the code of `split-window' for how this is done. */) | |||
| 3776 | 3738 | ||
| 3777 | make_parent_window (old, horflag); | 3739 | make_parent_window (old, horflag); |
| 3778 | p = XWINDOW (o->parent); | 3740 | p = XWINDOW (o->parent); |
| 3779 | /* Store value of `window-nest' in new parent's nest slot. */ | 3741 | /* Store value of `window-combination-limit' in new parent's |
| 3780 | p->nest = Vwindow_nest; | 3742 | combination_limit slot. */ |
| 3781 | /* Have PARENT inherit splits slot value from OLD. */ | 3743 | p->combination_limit = Vwindow_combination_limit; |
| 3782 | p->splits = o->splits; | ||
| 3783 | /* Store value of `window-splits' in OLD's splits slot. */ | ||
| 3784 | o->splits = Vwindow_splits; | ||
| 3785 | /* These get applied below. */ | 3744 | /* These get applied below. */ |
| 3786 | p->new_total = horflag ? o->total_cols : o->total_lines; | 3745 | p->new_total = horflag ? o->total_cols : o->total_lines; |
| 3787 | p->new_normal = new_normal; | 3746 | p->new_normal = new_normal; |
| @@ -3832,9 +3791,6 @@ set correctly. See the code of `split-window' for how this is done. */) | |||
| 3832 | n->scroll_bar_width = r->scroll_bar_width; | 3791 | n->scroll_bar_width = r->scroll_bar_width; |
| 3833 | n->vertical_scroll_bar_type = r->vertical_scroll_bar_type; | 3792 | n->vertical_scroll_bar_type = r->vertical_scroll_bar_type; |
| 3834 | 3793 | ||
| 3835 | /* Store `window-splits' in NEW's splits slot. */ | ||
| 3836 | n->splits = Vwindow_splits; | ||
| 3837 | |||
| 3838 | /* Directly assign orthogonal coordinates and sizes. */ | 3794 | /* Directly assign orthogonal coordinates and sizes. */ |
| 3839 | if (horflag) | 3795 | if (horflag) |
| 3840 | { | 3796 | { |
| @@ -3974,10 +3930,9 @@ Signal an error when WINDOW is the only window on its frame. */) | |||
| 3974 | /* Put SIBLING into PARENT's place. */ | 3930 | /* Put SIBLING into PARENT's place. */ |
| 3975 | replace_window (parent, sibling, 0); | 3931 | replace_window (parent, sibling, 0); |
| 3976 | /* Have SIBLING inherit the following three slot values from | 3932 | /* Have SIBLING inherit the following three slot values from |
| 3977 | PARENT (the nest slot is not inherited). */ | 3933 | PARENT (the combination_limit slot is not inherited). */ |
| 3978 | s->normal_cols = p->normal_cols; | 3934 | s->normal_cols = p->normal_cols; |
| 3979 | s->normal_lines = p->normal_lines; | 3935 | s->normal_lines = p->normal_lines; |
| 3980 | s->splits = p->splits; | ||
| 3981 | /* Mark PARENT as deleted. */ | 3936 | /* Mark PARENT as deleted. */ |
| 3982 | p->vchild = p->hchild = Qnil; | 3937 | p->vchild = p->hchild = Qnil; |
| 3983 | /* Try to merge SIBLING into its new parent. */ | 3938 | /* Try to merge SIBLING into its new parent. */ |
| @@ -5364,7 +5319,7 @@ struct saved_window | |||
| 5364 | Lisp_Object left_margin_cols, right_margin_cols; | 5319 | Lisp_Object left_margin_cols, right_margin_cols; |
| 5365 | Lisp_Object left_fringe_width, right_fringe_width, fringes_outside_margins; | 5320 | Lisp_Object left_fringe_width, right_fringe_width, fringes_outside_margins; |
| 5366 | Lisp_Object scroll_bar_width, vertical_scroll_bar_type, dedicated; | 5321 | Lisp_Object scroll_bar_width, vertical_scroll_bar_type, dedicated; |
| 5367 | Lisp_Object splits, nest, window_parameters; | 5322 | Lisp_Object combination_limit, window_parameters; |
| 5368 | }; | 5323 | }; |
| 5369 | 5324 | ||
| 5370 | #define SAVED_WINDOW_N(swv,n) \ | 5325 | #define SAVED_WINDOW_N(swv,n) \ |
| @@ -5595,8 +5550,7 @@ the return value is nil. Otherwise the value is t. */) | |||
| 5595 | w->scroll_bar_width = p->scroll_bar_width; | 5550 | w->scroll_bar_width = p->scroll_bar_width; |
| 5596 | w->vertical_scroll_bar_type = p->vertical_scroll_bar_type; | 5551 | w->vertical_scroll_bar_type = p->vertical_scroll_bar_type; |
| 5597 | w->dedicated = p->dedicated; | 5552 | w->dedicated = p->dedicated; |
| 5598 | w->splits = p->splits; | 5553 | w->combination_limit = p->combination_limit; |
| 5599 | w->nest = p->nest; | ||
| 5600 | w->window_parameters = p->window_parameters; | 5554 | w->window_parameters = p->window_parameters; |
| 5601 | XSETFASTINT (w->last_modified, 0); | 5555 | XSETFASTINT (w->last_modified, 0); |
| 5602 | XSETFASTINT (w->last_overlay_modified, 0); | 5556 | XSETFASTINT (w->last_overlay_modified, 0); |
| @@ -5874,8 +5828,7 @@ save_window_save (Lisp_Object window, struct Lisp_Vector *vector, int i) | |||
| 5874 | p->scroll_bar_width = w->scroll_bar_width; | 5828 | p->scroll_bar_width = w->scroll_bar_width; |
| 5875 | p->vertical_scroll_bar_type = w->vertical_scroll_bar_type; | 5829 | p->vertical_scroll_bar_type = w->vertical_scroll_bar_type; |
| 5876 | p->dedicated = w->dedicated; | 5830 | p->dedicated = w->dedicated; |
| 5877 | p->splits = w->splits; | 5831 | p->combination_limit = w->combination_limit; |
| 5878 | p->nest = w->nest; | ||
| 5879 | p->window_parameters = w->window_parameters; | 5832 | p->window_parameters = w->window_parameters; |
| 5880 | if (!NILP (w->buffer)) | 5833 | if (!NILP (w->buffer)) |
| 5881 | { | 5834 | { |
| @@ -6338,7 +6291,8 @@ freeze_window_starts (struct frame *f, int freeze_p) | |||
| 6338 | and the like. | 6291 | and the like. |
| 6339 | 6292 | ||
| 6340 | This ignores a couple of things like the dedicatedness status of | 6293 | This ignores a couple of things like the dedicatedness status of |
| 6341 | window, splits, nest and the like. This might have to be fixed. */ | 6294 | window, combination_limit and the like. This might have to be |
| 6295 | fixed. */ | ||
| 6342 | 6296 | ||
| 6343 | int | 6297 | int |
| 6344 | compare_window_configurations (Lisp_Object configuration1, Lisp_Object configuration2, int ignore_positions) | 6298 | compare_window_configurations (Lisp_Object configuration1, Lisp_Object configuration2, int ignore_positions) |
| @@ -6542,41 +6496,39 @@ will redraw the entire frame; the special value `tty' causes the | |||
| 6542 | frame to be redrawn only if it is a tty frame. */); | 6496 | frame to be redrawn only if it is a tty frame. */); |
| 6543 | Vrecenter_redisplay = Qtty; | 6497 | Vrecenter_redisplay = Qtty; |
| 6544 | 6498 | ||
| 6545 | DEFVAR_LISP ("window-splits", Vwindow_splits, | 6499 | DEFVAR_LISP ("window-combination-resize", Vwindow_combination_resize, |
| 6546 | doc: /* Non-nil means splitting windows is handled specially. | 6500 | doc: /* Non-nil means resize window combinations proportionally. |
| 6547 | If this variable is nil, splitting a window gets the entire screen space | 6501 | If this variable is nil, splitting a window gets the entire screen space |
| 6548 | for displaying the new window from the window to split. If this | 6502 | for displaying the new window from the window to split. Deleting and |
| 6549 | variable is non-nil, splitting a window may resize all windows in the | 6503 | resizing a window preferably resizes one adjacent window only. |
| 6550 | same combination. This also allows to split a window that is otherwise | 6504 | |
| 6551 | too small or of fixed size. | 6505 | If this variable is non-nil, splitting a window tries to get the space |
| 6552 | 6506 | proportionally from all windows in the same combination. This also | |
| 6553 | The value of this variable is also assigned to the split status of the | 6507 | allows to split a window that is otherwise too small or of fixed size. |
| 6554 | new window and, provided the old and new window form a new combination, | 6508 | Resizing and deleting a window proportionally resize all windows in the |
| 6555 | to the window that was split as well. The split status of a window can | 6509 | same combination. |
| 6556 | be retrieved with the function `window-splits' and altered by the | 6510 | |
| 6557 | function `set-window-splits'. | 6511 | This variable takes no effect if `window-combination-limit' is non-nil. */); |
| 6558 | 6512 | Vwindow_combination_resize = Qnil; | |
| 6559 | If the value of the variable `window-nest' is non-nil, the space for the | 6513 | |
| 6560 | new window is exclusively taken from the window that shall be split, but | 6514 | DEFVAR_LISP ("window-combination-limit", Vwindow_combination_limit, |
| 6561 | the split status of the window that is split as well as that of the new | ||
| 6562 | window are still set to the value of this variable. */); | ||
| 6563 | Vwindow_splits = Qnil; | ||
| 6564 | |||
| 6565 | DEFVAR_LISP ("window-nest", Vwindow_nest, | ||
| 6566 | doc: /* Non-nil means splitting a window makes a new parent window. | 6515 | doc: /* Non-nil means splitting a window makes a new parent window. |
| 6567 | If this variable is nil, splitting a window will create a new parent | 6516 | If this variable is nil, splitting a window will create a new parent |
| 6568 | window only if the window has no parent window or the window shall | 6517 | window only if the window has no parent window or the window shall |
| 6569 | become a combination orthogonal to the one it it is part of. | 6518 | become a combination orthogonal to the one it is part of. |
| 6519 | |||
| 6520 | If this variable is t, splitting a window always creates a new parent | ||
| 6521 | window. If all splits behave this way, each frame's window tree is a | ||
| 6522 | binary tree and every window but the frame's root window has exactly one | ||
| 6523 | sibling. | ||
| 6570 | 6524 | ||
| 6571 | If this variable is non-nil, splitting a window always creates a new | 6525 | Other values are reserved for future use. |
| 6572 | parent window. If all splits behave this way, each frame's window tree | ||
| 6573 | is a binary tree and every window but the frame's root window has | ||
| 6574 | exactly one sibling. | ||
| 6575 | 6526 | ||
| 6576 | The value of this variable is also assigned to the nest status of the | 6527 | The value of this variable is also assigned to the combination-limit |
| 6577 | new parent window. The nest status of a window can be retrieved via the | 6528 | status of the new parent window. The combination-limit status of a |
| 6578 | function `window-nest' and altered by the function `set-window-nest'. */); | 6529 | window can be retrieved via the function `window-combination-limit' and |
| 6579 | Vwindow_nest = Qnil; | 6530 | altered by the function `set-window-combination-limit'. */); |
| 6531 | Vwindow_combination_limit = Qnil; | ||
| 6580 | 6532 | ||
| 6581 | defsubr (&Sselected_window); | 6533 | defsubr (&Sselected_window); |
| 6582 | defsubr (&Sminibuffer_window); | 6534 | defsubr (&Sminibuffer_window); |
| @@ -6596,10 +6548,8 @@ function `window-nest' and altered by the function `set-window-nest'. */); | |||
| 6596 | defsubr (&Swindow_left_child); | 6548 | defsubr (&Swindow_left_child); |
| 6597 | defsubr (&Swindow_next_sibling); | 6549 | defsubr (&Swindow_next_sibling); |
| 6598 | defsubr (&Swindow_prev_sibling); | 6550 | defsubr (&Swindow_prev_sibling); |
| 6599 | defsubr (&Swindow_splits); | 6551 | defsubr (&Swindow_combination_limit); |
| 6600 | defsubr (&Sset_window_splits); | 6552 | defsubr (&Sset_window_combination_limit); |
| 6601 | defsubr (&Swindow_nest); | ||
| 6602 | defsubr (&Sset_window_nest); | ||
| 6603 | defsubr (&Swindow_use_time); | 6553 | defsubr (&Swindow_use_time); |
| 6604 | defsubr (&Swindow_top_line); | 6554 | defsubr (&Swindow_top_line); |
| 6605 | defsubr (&Swindow_left_column); | 6555 | defsubr (&Swindow_left_column); |