8

I am using emacs 24.5 under Linux Gentoo, and I would like to adjust the vertical scroll bar width, as I notice it became much larger than it was in a recent revision.

How to do this in my ".emacs" file ? I tried to manually set variable scroll-bar-width, but emacs reports it does not know this variable (although I came across it while reading the documentation).

Alternatively, I could live without the scroll bar after all (more text space is always fine with me).

Xavier
  • 81
  • 3
  • 4
    I just downloaded the stable public release for 24.5.1, and typed M-x describe-variable RET scroll-bar-width RET and this is the result: "scroll-bar-width is a variable defined in 'C source code'. Its value is nil. Automatically becomes buffer-local when set. Documentation: Width of this buffer's scroll bars in pixels. A value of nil means to use the scroll bar width from the window's frame." You might try something like this in your .emacs file: (setq-default scroll-bar-width 15) and restart Emacs. See also the function set-window-scroll-bars. – lawlist Sep 13 '15 at 19:30
  • 1
    To eliminate the scroll bar entirely, you could use: (add-to-list 'default-frame-alist '(vertical-scroll-bars . nil)) – lawlist Sep 13 '15 at 19:43

1 Answers1

4

Probably depends on your Emacs (e.g. toolkit or not).

On MS Windows, I control it using frame parameter scroll-bar-width (see also scroll-bar-height).

See the Elisp manual, node Layout Parameters.

Drew
  • 77,472
  • 10
  • 114
  • 243