diff options
| author | Martin Rudalics | 2014-02-21 09:02:05 +0100 |
|---|---|---|
| committer | Martin Rudalics | 2014-02-21 09:02:05 +0100 |
| commit | 8dd3e94fb6b780ac2bf5d07795df376a296ef5b5 (patch) | |
| tree | af14870e616ff0a4c8f3fc6dec5d32069bfcb70e /src | |
| parent | afe1e4c8eb4b4ef62569bd272507ecd5ffd51a2f (diff) | |
| download | emacs-8dd3e94fb6b780ac2bf5d07795df376a296ef5b5.tar.gz emacs-8dd3e94fb6b780ac2bf5d07795df376a296ef5b5.zip | |
Fix handling of window-min-height/-width (Bug#16738).
* window.el (window--dump-window, window--dump-frame): New
functions.
(window--min-size-1): Account for window dividers. When
window-resize-pixelwise is nil, delay rounding till after the
sum of the window components has been calculated.
(window--min-delta-1, window--max-delta-1): When PIXELWISE is
nil make sure at least one text line and two text columns remain
fully visible.
(window-resize): Signal an error when window-resize-apply fails.
(window--resize-child-windows): Fix calculation of by how many
pixels a window can still be shrunk via window-new-normal.
(adjust-window-trailing-edge): Call window--resizable with
correct TRAIL argument.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 4 | ||||
| -rw-r--r-- | src/window.c | 10 |
2 files changed, 14 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index ae35ff6cce2..2b631dfc5f9 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2014-02-21 Martin Rudalics <rudalics@gmx.at> | ||
| 2 | |||
| 3 | * window.c (Fwindow_scroll_bar_width): New function. | ||
| 4 | |||
| 1 | 2014-02-21 Paul Eggert <eggert@cs.ucla.edu> | 5 | 2014-02-21 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 6 | ||
| 3 | Pacify GCC when configuring with --enable-gcc-warnings. | 7 | Pacify GCC when configuring with --enable-gcc-warnings. |
diff --git a/src/window.c b/src/window.c index b2c97d52157..0f62838d672 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -974,6 +974,15 @@ WINDOW must be a live window and defaults to the selected one. */) | |||
| 974 | return (make_number (WINDOW_BOTTOM_DIVIDER_WIDTH (decode_live_window (window)))); | 974 | return (make_number (WINDOW_BOTTOM_DIVIDER_WIDTH (decode_live_window (window)))); |
| 975 | } | 975 | } |
| 976 | 976 | ||
| 977 | DEFUN ("window-scroll-bar-width", Fwindow_scroll_bar_width, | ||
| 978 | Swindow_scroll_bar_width, 0, 1, 0, | ||
| 979 | doc: /* Return the width in pixels of WINDOW's vertical scrollbar. | ||
| 980 | WINDOW must be a live window and defaults to the selected one. */) | ||
| 981 | (Lisp_Object window) | ||
| 982 | { | ||
| 983 | return (make_number (WINDOW_SCROLL_BAR_AREA_WIDTH (decode_live_window (window)))); | ||
| 984 | } | ||
| 985 | |||
| 977 | DEFUN ("window-hscroll", Fwindow_hscroll, Swindow_hscroll, 0, 1, 0, | 986 | DEFUN ("window-hscroll", Fwindow_hscroll, Swindow_hscroll, 0, 1, 0, |
| 978 | doc: /* Return the number of columns by which WINDOW is scrolled from left margin. | 987 | doc: /* Return the number of columns by which WINDOW is scrolled from left margin. |
| 979 | WINDOW must be a live window and defaults to the selected one. */) | 988 | WINDOW must be a live window and defaults to the selected one. */) |
| @@ -7363,6 +7372,7 @@ pixelwise even if this option is nil. */); | |||
| 7363 | defsubr (&Swindow_header_line_height); | 7372 | defsubr (&Swindow_header_line_height); |
| 7364 | defsubr (&Swindow_right_divider_width); | 7373 | defsubr (&Swindow_right_divider_width); |
| 7365 | defsubr (&Swindow_bottom_divider_width); | 7374 | defsubr (&Swindow_bottom_divider_width); |
| 7375 | defsubr (&Swindow_scroll_bar_width); | ||
| 7366 | defsubr (&Swindow_inside_edges); | 7376 | defsubr (&Swindow_inside_edges); |
| 7367 | defsubr (&Swindow_inside_pixel_edges); | 7377 | defsubr (&Swindow_inside_pixel_edges); |
| 7368 | defsubr (&Swindow_inside_absolute_pixel_edges); | 7378 | defsubr (&Swindow_inside_absolute_pixel_edges); |