Mercurial > emacs
diff src/window.c @ 52565:26d1a4665f6c
(Fset_window_scroll_bars): Validate the value of `vertical_type'.
| author | Masatake YAMATO <jet@gyve.org> |
|---|---|
| date | Mon, 22 Sep 2003 12:55:25 +0000 |
| parents | 9a8ad8b87f32 |
| children | f8adaf14f570 |
line wrap: on
line diff
--- a/src/window.c Mon Sep 22 12:37:00 2003 +0000 +++ b/src/window.c Mon Sep 22 12:55:25 2003 +0000 @@ -5861,7 +5861,8 @@ this is automatically adjusted to a multiple of the frame column width. Third parameter VERTICAL-TYPE specifies the type of the vertical scroll bar: left, right, or nil. -A width of nil and type of t means to use the frame's corresponding value. */) +If WIDTH is nil, use the frame's scroll-bar width. +If TYPE is t, use the frame's scroll-bar type. */) (window, width, vertical_type, horizontal_type) Lisp_Object window, width, vertical_type, horizontal_type; { @@ -5873,6 +5874,12 @@ if (XINT (width) == 0) vertical_type = Qnil; + if (!(EQ (vertical_type, Qnil) + || EQ (vertical_type, Qleft) + || EQ (vertical_type, Qright) + || EQ (vertical_type, Qt))) + error ("Invalid type of vertical scroll bar"); + if (!EQ (w->scroll_bar_width, width) || !EQ (w->vertical_scroll_bar_type, vertical_type)) {
