Normally the frame parameter
whether the windows in the frame have vertical scroll bars, and
whether they are on the left or right. The frame parameter
scroll-bar-width specifies how wide they are (
meaning the default). See Layout Parameters.
This function reports the scroll bar type settings for frame frame. The value is a cons cell
), where vertical-type is either
nil(which means no scroll bar.) horizontal-type is meant to specify the horizontal scroll bar type, but since they are not implemented, it is always
You can enable or disable scroll bars for a particular buffer,
by setting the variable
vertical-scroll-bar. This variable
automatically becomes buffer-local when set. The possible values are
t, which means to use the
frame's default, and
nil for no scroll bar.
You can also control this for individual windows. Call the function
set-window-scroll-bars to specify what to do for a specific window:
This function sets the width and type of scroll bars for window window.
width specifies the scroll bar width in pixels (
nilmeans use the width specified for the frame). vertical-type specifies whether to have a vertical scroll bar and, if so, where. The possible values are
nil, just like the values of the
The argument horizontal-type is meant to specify whether and where to have horizontal scroll bars, but since they are not implemented, it has no effect. If window is
nil, the selected window is used.
Report the width and type of scroll bars specified for window. If window is omitted or
nil, the selected window is used. The value is a list of the form
(width cols vertical-type horizontal-type
). The value width is the value that was specified for the width (which may be
nil); cols is the number of columns that the scroll bar actually occupies.
horizontal-type is not actually meaningful.
This function returns the width in pixels of window's vertical scrollbar. window must be a live window, and defaults to the selected window.
If you don't specify these values for a window with
set-window-scroll-bars, the buffer-local variables
scroll-bar-width in the buffer being
displayed control the window's vertical scroll bars. The function
set-window-buffer examines these variables. If you change them
in a buffer that is already visible in a window, you can make the
window take note of the new values by calling
specifying the same buffer that is already displayed.
This variable, always local in all buffers, controls whether and where to put scroll bars in windows displaying the buffer. The possible values are
nilfor no scroll bar,
leftto put a scroll bar on the left, and
rightto put a scroll bar on the right.
This function reports the scroll bar type for window window. If window is omitted or
nil, the selected window is used. The value is a cons cell
window-scroll-bars, this reports the scroll bar type actually used, once frame defaults and
scroll-bar-modeare taken into account.