diff options
| author | Geoff Voelker | 1998-04-23 23:38:50 +0000 |
|---|---|---|
| committer | Geoff Voelker | 1998-04-23 23:38:50 +0000 |
| commit | 1032e793e71e7fe2668728b3c36943c2ce2373a8 (patch) | |
| tree | 6ea272bc98cb412de2b758c6e77830d3ab324c86 | |
| parent | ec025f9d8dd7e07712f5faa2f68bb20a997a1fe2 (diff) | |
| download | emacs-1032e793e71e7fe2668728b3c36943c2ce2373a8.tar.gz emacs-1032e793e71e7fe2668728b3c36943c2ce2373a8.zip | |
(scroll-bar-mode, toggle-scroll-bar): By default,
put scroll bars on the right on MS-Windows (since that is the
convention on Windows).
| -rw-r--r-- | lisp/scroll-bar.el | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/lisp/scroll-bar.el b/lisp/scroll-bar.el index 2100a1f51ec..97cfa9d731f 100644 --- a/lisp/scroll-bar.el +++ b/lisp/scroll-bar.el | |||
| @@ -86,7 +86,8 @@ This is nil while loading `scroll-bar.el', and t afterward.") | |||
| 86 | (list (cons 'vertical-scroll-bars scroll-bar-mode))) | 86 | (list (cons 'vertical-scroll-bars scroll-bar-mode))) |
| 87 | (setq frames (cdr frames)))))) | 87 | (setq frames (cdr frames)))))) |
| 88 | 88 | ||
| 89 | (defcustom scroll-bar-mode 'left | 89 | (defcustom scroll-bar-mode |
| 90 | (if (eq system-type 'windows-nt) 'right 'left) | ||
| 90 | "*Specify whether to have vertical scroll bars, and on which side. | 91 | "*Specify whether to have vertical scroll bars, and on which side. |
| 91 | Possible values are nil (no scroll bars), `left' (scroll bars on left) | 92 | Possible values are nil (no scroll bars), `left' (scroll bars on left) |
| 92 | and `right' (scroll bars on right). | 93 | and `right' (scroll bars on right). |
| @@ -116,7 +117,7 @@ turn off scroll bars; otherwise, turn on scroll bars." | |||
| 116 | ;; Tweedle the variable according to the argument. | 117 | ;; Tweedle the variable according to the argument. |
| 117 | (set-scroll-bar-mode (if (null flag) (not scroll-bar-mode) | 118 | (set-scroll-bar-mode (if (null flag) (not scroll-bar-mode) |
| 118 | (and (or (not (numberp flag)) (>= flag 0)) | 119 | (and (or (not (numberp flag)) (>= flag 0)) |
| 119 | 'left)))) | 120 | (if (eq system-type 'windows-nt) 'right 'left))))) |
| 120 | 121 | ||
| 121 | (defun toggle-scroll-bar (arg) | 122 | (defun toggle-scroll-bar (arg) |
| 122 | "Toggle whether or not the selected frame has vertical scroll bars. | 123 | "Toggle whether or not the selected frame has vertical scroll bars. |
| @@ -130,10 +131,12 @@ when they are turned on; if it is nil, they go on the left." | |||
| 130 | (frame-parameters (selected-frame)))) | 131 | (frame-parameters (selected-frame)))) |
| 131 | -1 1)) | 132 | -1 1)) |
| 132 | (setq arg (prefix-numeric-value arg))) | 133 | (setq arg (prefix-numeric-value arg))) |
| 133 | (modify-frame-parameters (selected-frame) | 134 | (modify-frame-parameters |
| 134 | (list (cons 'vertical-scroll-bars | 135 | (selected-frame) |
| 135 | (if (> arg 0) | 136 | (list (cons 'vertical-scroll-bars |
| 136 | (or scroll-bar-mode 'left)))))) | 137 | (if (> arg 0) |
| 138 | (or scroll-bar-mode | ||
| 139 | (if (eq system-type 'windows-nt) 'right 'left))))))) | ||
| 137 | 140 | ||
| 138 | (defun toggle-horizontal-scroll-bar (arg) | 141 | (defun toggle-horizontal-scroll-bar (arg) |
| 139 | "Toggle whether or not the selected frame has horizontal scroll bars. | 142 | "Toggle whether or not the selected frame has horizontal scroll bars. |