Commit | Line | Data |
---|---|---|
1cd7adc6 | 1 | ;;; cus-start.el --- define customization properties of builtins |
976f7668 | 2 | |
ba318903 | 3 | ;; Copyright (C) 1997, 1999-2014 Free Software Foundation, Inc. |
976f7668 | 4 | |
1444b0c0 PA |
5 | ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> |
6 | ;; Keywords: internal | |
bd78fa1d | 7 | ;; Package: emacs |
1444b0c0 | 8 | |
c2383d2d RS |
9 | ;; This file is part of GNU Emacs. |
10 | ||
eb3fa2cf | 11 | ;; GNU Emacs is free software: you can redistribute it and/or modify |
c2383d2d | 12 | ;; it under the terms of the GNU General Public License as published by |
eb3fa2cf GM |
13 | ;; the Free Software Foundation, either version 3 of the License, or |
14 | ;; (at your option) any later version. | |
c2383d2d RS |
15 | |
16 | ;; GNU Emacs is distributed in the hope that it will be useful, | |
17 | ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | |
18 | ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
19 | ;; GNU General Public License for more details. | |
20 | ||
21 | ;; You should have received a copy of the GNU General Public License | |
eb3fa2cf | 22 | ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. |
c2383d2d | 23 | |
1444b0c0 | 24 | ;;; Commentary: |
976f7668 | 25 | |
4883633e | 26 | ;; This file adds customize support for built-in variables. |
1444b0c0 | 27 | |
4883633e RS |
28 | ;; While dumping Emacs, this file is loaded, but it only records |
29 | ;; the standard values; it does not do the rest of the job. | |
30 | ;; Later on, if the user makes a customization buffer, | |
31 | ;; this file is loaded again with (require 'cus-start); | |
32 | ;; then it does the whole job. | |
1444b0c0 | 33 | |
4883633e | 34 | ;;; Code: |
1444b0c0 | 35 | |
0356de22 GM |
36 | ;; Elements of this list have the form: |
37 | ;; SYMBOL GROUP TYPE VERSION REST... | |
38 | ;; SYMBOL is the name of the variable. | |
39 | ;; GROUP is the custom group to which it belongs (may also be a list | |
40 | ;; of groups) | |
41 | ;; TYPE is the defcustom :type. | |
42 | ;; VERSION is the defcustom :version (or nil). | |
43 | ;; REST is a set of :KEYWORD VALUE pairs. Accepted :KEYWORDs are: | |
44 | ;; :standard - standard value for SYMBOL (else use current value) | |
45 | ;; :set - custom-set property | |
46 | ;; :risky - risky-local-variable property | |
47 | ;; :safe - safe-local-variable property | |
48 | ;; :tag - custom-tag property | |
e047f448 | 49 | (let ((all '(;; alloc.c |
1444b0c0 | 50 | (gc-cons-threshold alloc integer) |
2bc356d7 | 51 | (gc-cons-percentage alloc float) |
0f014aa1 | 52 | (garbage-collection-messages alloc boolean) |
1444b0c0 | 53 | ;; buffer.c |
0f7b074f CY |
54 | (cursor-type |
55 | display | |
56 | (choice | |
57 | (const :tag "Frame default" t) | |
58 | (const :tag "Filled box" box) | |
59 | (const :tag "Hollow cursor" hollow) | |
60 | (const :tag "Vertical bar" bar) | |
61 | (cons :tag "Vertical bar with specified width" | |
62 | (const bar) integer) | |
63 | (const :tag "Horizontal bar" hbar) | |
64 | (cons :tag "Horizontal bar with specified width" | |
65 | (const hbar) integer) | |
66 | (const :tag "None "nil))) | |
e45db0fb | 67 | (mode-line-format mode-line sexp) ;Hard to do right. |
4e3b4528 | 68 | (major-mode internal function) |
1444b0c0 PA |
69 | (case-fold-search matching boolean) |
70 | (fill-column fill integer) | |
71 | (left-margin fill integer) | |
72 | (tab-width editing-basics integer) | |
73 | (ctl-arrow display boolean) | |
74 | (truncate-lines display boolean) | |
84975bbe | 75 | (word-wrap display boolean) |
1444b0c0 | 76 | (selective-display-ellipses display boolean) |
516b77a3 | 77 | (indicate-empty-lines fringe boolean) |
eb94dac6 LT |
78 | (indicate-buffer-boundaries |
79 | fringe | |
80 | (choice | |
81 | (const :tag "No indicators" nil) | |
82 | (const :tag "On left, with arrows" left) | |
83 | (const :tag "On right, with arrows" right) | |
a4fbb790 LT |
84 | (set :tag "Pick your own design" |
85 | :value ((t . nil)) | |
86 | :format "%{%t%}:\n%v\n%d" | |
87 | :doc "You can specify a default and then override it \ | |
88 | for individual indicators. | |
89 | Leaving \"Default\" unchecked is equivalent with specifying a default of | |
90 | \"Do not show\"." | |
91 | (choice :tag "Default" | |
92 | :value (t . nil) | |
93 | (const :tag "Do not show" (t . nil)) | |
94 | (const :tag "On the left" (t . left)) | |
95 | (const :tag "On the right" (t . right))) | |
96 | (choice :tag "Top" | |
97 | :value (top . left) | |
98 | (const :tag "Do not show" (top . nil)) | |
99 | (const :tag "On the left" (top . left)) | |
100 | (const :tag "On the right" (top . right))) | |
101 | (choice :tag "Bottom" | |
102 | :value (bottom . left) | |
103 | (const :tag "Do not show" (bottom . nil)) | |
104 | (const :tag "On the left" (bottom . left)) | |
105 | (const :tag "On the right" (bottom . right))) | |
106 | (choice :tag "Up arrow" | |
107 | :value (up . left) | |
108 | (const :tag "Do not show" (up . nil)) | |
109 | (const :tag "On the left" (up . left)) | |
110 | (const :tag "On the right" (up . right))) | |
111 | (choice :tag "Down arrow" | |
112 | :value (down . left) | |
113 | (const :tag "Do not show" (down . nil)) | |
114 | (const :tag "On the left" (down . left)) | |
115 | (const :tag "On the right" (down . right)))) | |
516b77a3 | 116 | (other :tag "On left, no arrows" t))) |
c6d57325 | 117 | (scroll-up-aggressively windows |
58cc0a01 | 118 | (choice (const :tag "off" nil) float) |
c6d57325 RS |
119 | "21.1") |
120 | (scroll-down-aggressively windows | |
58cc0a01 | 121 | (choice (const :tag "off" nil) float) |
c6d57325 | 122 | "21.1") |
58cc0a01 | 123 | (line-spacing display (choice (const :tag "none" nil) number) |
6671cab3 | 124 | "22.1") |
ec514007 | 125 | (cursor-in-non-selected-windows |
c8c59954 GM |
126 | cursor boolean nil |
127 | :tag "Cursor In Non-selected Windows" | |
e9c8529f GM |
128 | :set (lambda (symbol value) |
129 | (set-default symbol value) | |
130 | (force-mode-line-update t))) | |
9d794026 | 131 | (transient-mark-mode editing-basics boolean nil |
c8c59954 | 132 | :standard (not noninteractive) |
88f43c67 GM |
133 | :initialize custom-initialize-delay |
134 | :set custom-set-minor-mode) | |
b177498a EZ |
135 | (bidi-paragraph-direction |
136 | paragraphs | |
137 | (choice | |
138 | (const :tag "Left to Right" left-to-right) | |
139 | (const :tag "Right to Left" right-to-left) | |
904215d2 EZ |
140 | (const :tag "Dynamic, according to paragraph text" nil)) |
141 | "24.1") | |
1444b0c0 PA |
142 | ;; callint.c |
143 | (mark-even-if-inactive editing-basics boolean) | |
144 | ;; callproc.c | |
145 | (shell-file-name execute file) | |
146 | (exec-path execute | |
f747a488 | 147 | (repeat (choice (const :tag "default directory" nil) |
72e869ba | 148 | (directory :format "%v")))) |
2bc356d7 | 149 | (exec-suffixes execute (repeat string)) |
5e3097cd | 150 | ;; charset.c |
c11f69e1 KH |
151 | (charset-map-path installation |
152 | (repeat (directory :format "%v"))) | |
5fc9eb7c DL |
153 | ;; coding.c |
154 | (inhibit-eol-conversion mule boolean) | |
de0d1fc5 | 155 | (eol-mnemonic-undecided mule string) |
57c3bd01 GM |
156 | ;; startup.el fiddles with the values. IMO, would be |
157 | ;; simpler to just use #ifdefs in coding.c. | |
158 | (eol-mnemonic-unix mule string nil | |
159 | :standard | |
160 | (if (memq system-type '(ms-dos windows-nt)) | |
161 | "(Unix)" ":")) | |
162 | (eol-mnemonic-dos mule string nil | |
163 | :standard | |
164 | (if (memq system-type '(ms-dos windows-nt)) | |
165 | "\\" "(DOS)")) | |
166 | (eol-mnemonic-mac mule string nil | |
167 | :standard "(Mac)") | |
13eb63ff DL |
168 | (file-coding-system-alist |
169 | mule | |
170 | (alist | |
171 | :key-type (regexp :tag "File regexp") | |
172 | :value-type (choice | |
173 | :value (undecided . undecided) | |
174 | (cons :tag "Encoding/decoding pair" | |
175 | :value (undecided . undecided) | |
176 | (coding-system :tag "Decoding") | |
177 | (coding-system :tag "Encoding")) | |
70c2811c KY |
178 | (coding-system |
179 | :tag "Single coding system" | |
180 | :value undecided | |
181 | :match (lambda (widget value) | |
182 | (and value (not (functionp value))))) | |
13eb63ff | 183 | (function :value ignore)))) |
1444b0c0 | 184 | ;; dired.c |
71296446 | 185 | (completion-ignored-extensions dired |
1444b0c0 | 186 | (repeat (string :format "%v"))) |
0849a37e | 187 | ;; dispnew.c |
1444b0c0 PA |
188 | (baud-rate display integer) |
189 | (inverse-video display boolean) | |
190 | (visible-bell display boolean) | |
191 | (no-redraw-on-reenter display boolean) | |
2bc356d7 CY |
192 | |
193 | ;; dosfns.c | |
194 | (dos-display-scancodes display boolean) | |
195 | (dos-hyper-key keyboard integer) | |
196 | (dos-super-key keyboard integer) | |
197 | (dos-keypad-mode keyboard integer) | |
198 | ||
1444b0c0 PA |
199 | ;; editfns.c |
200 | (user-full-name mail string) | |
201 | ;; eval.c | |
202 | (max-specpdl-size limits integer) | |
203 | (max-lisp-eval-depth limits integer) | |
f8add097 RS |
204 | (max-mini-window-height limits |
205 | (choice (const :tag "quarter screen" nil) | |
6671cab3 | 206 | number) "23.1") |
71296446 | 207 | (debug-on-error debug |
1444b0c0 PA |
208 | (choice (const :tag "off") |
209 | (repeat :menu-tag "When" | |
210 | :value (nil) | |
211 | (symbol :format "%v")) | |
212 | (const :tag "always" t))) | |
213 | (debug-ignored-errors debug (repeat (choice symbol regexp))) | |
21ce8245 | 214 | (debug-on-quit debug boolean) |
2bc356d7 CY |
215 | (debug-on-signal debug boolean) |
216 | ;; fileio.c | |
217 | (delete-by-moving-to-trash auto-save boolean "23.1") | |
6ba7a6f0 | 218 | (auto-save-visited-file-name auto-save boolean) |
e088c02a | 219 | ;; filelock.c |
2a1e2476 | 220 | (create-lockfiles files boolean "24.3") |
e088c02a GM |
221 | (temporary-file-directory |
222 | ;; Darwin section added 24.1, does not seem worth :version bump. | |
223 | files directory nil | |
c8c59954 | 224 | :standard |
e088c02a GM |
225 | (file-name-as-directory |
226 | ;; FIXME ? Should there be Ftemporary_file_directory to do this | |
227 | ;; more robustly (cf set_local_socket in emacsclient.c). | |
228 | ;; It could be used elsewhere, eg Fcall_process_region, | |
229 | ;; server-socket-dir. See bug#7135. | |
230 | (cond ((memq system-type '(ms-dos windows-nt)) | |
231 | (or (getenv "TEMP") (getenv "TMPDIR") (getenv "TMP") | |
232 | "c:/temp")) | |
233 | ((eq system-type 'darwin) | |
234 | (or (getenv "TMPDIR") (getenv "TMP") (getenv "TEMP") | |
235 | ;; See bug#7135. | |
236 | (let ((tmp (ignore-errors | |
237 | (shell-command-to-string | |
238 | "getconf DARWIN_USER_TEMP_DIR")))) | |
239 | (and (stringp tmp) | |
240 | (setq tmp (replace-regexp-in-string | |
241 | "\n\\'" "" tmp)) | |
242 | ;; Handles "getconf: Unrecognized variable..." | |
243 | (file-directory-p tmp) | |
244 | tmp)) | |
245 | "/tmp")) | |
246 | (t | |
247 | (or (getenv "TMPDIR") (getenv "TMP") (getenv "TEMP") | |
248 | "/tmp")))) | |
249 | :initialize custom-initialize-delay) | |
78976e0a | 250 | ;; fns.c |
37328bcd | 251 | (use-dialog-box menu boolean "21.1") |
bf247b6e | 252 | (use-file-dialog menu boolean "22.1") |
f4c307a5 | 253 | (focus-follows-mouse frames boolean "20.3") |
2bc356d7 | 254 | ;; fontset.c |
a931698a GM |
255 | ;; FIXME nil is the initial value, fontset.el setqs it. |
256 | (vertical-centering-font-regexp display | |
257 | (choice (const nil) regexp)) | |
1444b0c0 PA |
258 | ;; frame.c |
259 | (default-frame-alist frames | |
260 | (repeat (cons :format "%v" | |
261 | (symbol :tag "Parameter") | |
262 | (sexp :tag "Value")))) | |
140fb7ff KS |
263 | (mouse-highlight mouse (choice (const :tag "disabled" nil) |
264 | (const :tag "always shown" t) | |
6671cab3 MR |
265 | (other :tag "hidden by keypress" 1)) |
266 | "22.1") | |
e044e4fc | 267 | (make-pointer-invisible mouse boolean "23.2") |
c8c59954 | 268 | (menu-bar-mode frames boolean nil |
88f43c67 GM |
269 | ;; FIXME? |
270 | ; :initialize custom-initialize-default | |
271 | :set custom-set-minor-mode) | |
c8c59954 | 272 | (tool-bar-mode (frames mouse) boolean nil |
88f43c67 GM |
273 | ; :initialize custom-initialize-default |
274 | :set custom-set-minor-mode) | |
880e6158 | 275 | (frame-resize-pixelwise windows boolean "24.4") |
48d707c5 | 276 | ;; fringe.c |
516b77a3 | 277 | (overflow-newline-into-fringe fringe boolean) |
af008560 GM |
278 | ;; image.c |
279 | (imagemagick-render-type image integer "24.1") | |
1444b0c0 | 280 | ;; indent.c |
01892a52 | 281 | (indent-tabs-mode indent boolean) |
1444b0c0 PA |
282 | ;; keyboard.c |
283 | (meta-prefix-char keyboard character) | |
284 | (auto-save-interval auto-save integer) | |
285 | (auto-save-timeout auto-save (choice (const :tag "off" nil) | |
286 | (integer :format "%v"))) | |
ac1b1728 | 287 | (echo-keystrokes minibuffer number) |
1444b0c0 | 288 | (polling-period keyboard integer) |
4db2b1c7 RS |
289 | (double-click-time mouse (restricted-sexp |
290 | :match-alternatives (integerp 'nil 't))) | |
6671cab3 | 291 | (double-click-fuzz mouse integer "22.1") |
1444b0c0 PA |
292 | (help-char keyboard character) |
293 | (help-event-list keyboard (repeat (sexp :format "%v"))) | |
294 | (menu-prompting menu boolean) | |
9852377f | 295 | (select-active-regions killing |
7c23dd44 CY |
296 | (choice (const :tag "always" t) |
297 | (const :tag "only shift-selection or mouse-drag" only) | |
9852377f CY |
298 | (const :tag "off" nil)) |
299 | "24.1") | |
0438ce91 DC |
300 | (debug-on-event debug |
301 | (choice (const :tag "None" nil) | |
302 | (const :tag "When sent SIGUSR1" sigusr1) | |
303 | (const :tag "When sent SIGUSR2" sigusr2)) | |
304 | "24.1") | |
5f537e54 | 305 | |
99d0d6dc SM |
306 | ;; This is not good news because it will use the wrong |
307 | ;; version-specific directories when you upgrade. We need | |
308 | ;; customization of the front of the list, maintaining the | |
309 | ;; standard value intact at the back. | |
310 | ;;(load-path environment | |
311 | ;; (repeat (choice :tag "[Current dir?]" | |
312 | ;; :format "%[Current dir?%] %v" | |
313 | ;; (const :tag " current dir" nil) | |
314 | ;; (directory :format "%v")))) | |
1f41ee56 | 315 | (load-prefer-newer lisp boolean "24.4") |
1444b0c0 | 316 | ;; minibuf.c |
1444b0c0 | 317 | (enable-recursive-minibuffers minibuffer boolean) |
408f56b2 | 318 | (history-length minibuffer |
6671cab3 MR |
319 | (choice (const :tag "Infinite" t) integer) |
320 | "22.1") | |
321 | (history-delete-duplicates minibuffer boolean "22.1") | |
ed278e5d CY |
322 | (read-buffer-completion-ignore-case minibuffer boolean "23.1") |
323 | ||
8f62f2b8 MB |
324 | (minibuffer-prompt-properties |
325 | minibuffer | |
326 | (list | |
327 | (checklist :inline t | |
328 | (const :tag "Read-Only" | |
329 | :doc "Prevent prompt from being modified" | |
330 | :format "%t%n%h" | |
331 | :inline t | |
332 | (read-only t)) | |
c9133fa6 | 333 | (const :tag "Don't Enter" |
8f62f2b8 MB |
334 | :doc "Prevent point from ever entering prompt" |
335 | :format "%t%n%h" | |
336 | :inline t | |
337 | (point-entered minibuffer-avoid-prompt))) | |
338 | (repeat :inline t | |
339 | :tag "Other Properties" | |
340 | (list :inline t | |
341 | :format "%v" | |
342 | (symbol :tag "Property") | |
ecf5279a DL |
343 | (sexp :tag "Value")))) |
344 | "21.1") | |
1444b0c0 | 345 | (minibuffer-auto-raise minibuffer boolean) |
ecf5279a | 346 | ;; options property set at end |
a8a1b05d DL |
347 | (read-buffer-function minibuffer |
348 | (choice (const nil) | |
349 | (function-item iswitchb-read-buffer) | |
350 | function)) | |
b78fba02 EZ |
351 | ;; msdos.c |
352 | (dos-unsupported-char-glyph display integer) | |
bc9ebf41 | 353 | ;; nsterm.m |
77346ecd | 354 | (ns-control-modifier |
ae2349fe | 355 | ns |
bc9ebf41 DR |
356 | (choice (const :tag "No modifier" nil) |
357 | (const control) (const meta) | |
358 | (const alt) (const hyper) | |
359 | (const super)) "23.1") | |
b7d1e144 JD |
360 | (ns-right-control-modifier |
361 | ns | |
362 | (choice (const :tag "No modifier (work as control)" none) | |
363 | (const :tag "Use the value of ns-control-modifier" | |
364 | left) | |
365 | (const control) (const meta) | |
366 | (const alt) (const hyper) | |
18348234 | 367 | (const super)) "24.1") |
77346ecd | 368 | (ns-command-modifier |
ae2349fe | 369 | ns |
bc9ebf41 DR |
370 | (choice (const :tag "No modifier" nil) |
371 | (const control) (const meta) | |
372 | (const alt) (const hyper) | |
373 | (const super)) "23.1") | |
b7d1e144 JD |
374 | (ns-right-command-modifier |
375 | ns | |
376 | (choice (const :tag "No modifier (work as command)" none) | |
377 | (const :tag "Use the value of ns-command-modifier" | |
378 | left) | |
379 | (const control) (const meta) | |
380 | (const alt) (const hyper) | |
18348234 | 381 | (const super)) "24.1") |
77346ecd | 382 | (ns-alternate-modifier |
ae2349fe | 383 | ns |
bc9ebf41 DR |
384 | (choice (const :tag "No modifier (work as alternate/option)" none) |
385 | (const control) (const meta) | |
386 | (const alt) (const hyper) | |
387 | (const super)) "23.1") | |
a2e35ef5 JD |
388 | (ns-right-alternate-modifier |
389 | ns | |
390 | (choice (const :tag "No modifier (work as alternate/option)" none) | |
391 | (const :tag "Use the value of ns-alternate-modifier" | |
392 | left) | |
393 | (const control) (const meta) | |
394 | (const alt) (const hyper) | |
395 | (const super)) "23.3") | |
77346ecd | 396 | (ns-function-modifier |
ae2349fe | 397 | ns |
bc9ebf41 DR |
398 | (choice (const :tag "No modifier (work as function)" none) |
399 | (const control) (const meta) | |
400 | (const alt) (const hyper) | |
401 | (const super)) "23.1") | |
402 | (ns-antialias-text ns boolean "23.1") | |
18348234 | 403 | (ns-auto-hide-menu-bar ns boolean "24.1") |
6871e574 | 404 | (ns-use-native-fullscreen ns boolean "24.4") |
41cf3d11 | 405 | (ns-use-srgb-colorspace ns boolean "24.4") |
1444b0c0 | 406 | ;; process.c |
4883633e | 407 | (delete-exited-processes processes-basics boolean) |
1444b0c0 PA |
408 | ;; syntax.c |
409 | (parse-sexp-ignore-comments editing-basics boolean) | |
410 | (words-include-escapes editing-basics boolean) | |
6b61353c KH |
411 | (open-paren-in-column-0-is-defun-start editing-basics boolean |
412 | "21.1") | |
98e071b5 SM |
413 | ;; term.c |
414 | (visible-cursor cursor boolean "22.1") | |
0f08b956 LT |
415 | ;; undo.c |
416 | (undo-limit undo integer) | |
417 | (undo-strong-limit undo integer) | |
418 | (undo-outer-limit undo | |
419 | (choice integer | |
420 | (const :tag "No limit" | |
421 | :format "%t\n%d" | |
422 | :doc | |
423 | "With this choice, \ | |
424 | the undo info for the current command never gets discarded. | |
425 | This should only be chosen under exceptional circumstances, | |
426 | since it could result in memory overflow and make Emacs crash." | |
427 | nil)) | |
428 | "22.1") | |
1444b0c0 | 429 | ;; window.c |
4cb464b7 | 430 | (temp-buffer-show-function windows (choice (const nil) function)) |
74f54b54 | 431 | (next-screen-context-lines windows integer) |
7704b6b1 KS |
432 | (scroll-preserve-screen-position |
433 | windows (choice | |
434 | (const :tag "Off (nil)" :value nil) | |
435 | (const :tag "Full screen (t)" :value t) | |
6671cab3 | 436 | (other :tag "Always" 1)) "22.1") |
562dd5e9 MR |
437 | (recenter-redisplay |
438 | windows (choice | |
439 | (const :tag "Never (nil)" :value nil) | |
440 | (const :tag "Only on ttys" :value tty) | |
441 | (other :tag "Always" t)) "23.1") | |
a0c2d0ae | 442 | (window-combination-resize windows boolean "24.1") |
8e17c9ba MR |
443 | (window-combination-limit |
444 | windows (choice | |
445 | (const :tag "Never (nil)" :value nil) | |
446 | (const :tag "For Temp Buffer Resize mode (temp-buffer-resize)" | |
447 | :value temp-buffer-resize) | |
448 | (const :tag "For temporary buffers (temp-buffer)" | |
449 | :value temp-buffer) | |
450 | (const :tag "For buffer display (display-buffer)" | |
451 | :value display-buffer) | |
452 | (other :tag "Always (t)" :value t)) | |
453 | "24.3") | |
880e6158 | 454 | (window-resize-pixelwise windows boolean "24.4") |
1444b0c0 | 455 | ;; xdisp.c |
ed8be7ff GM |
456 | ;; The whitespace group is for whitespace.el. |
457 | (show-trailing-whitespace editing-basics boolean nil | |
ec514007 | 458 | :safe booleanp) |
1444b0c0 | 459 | (scroll-step windows integer) |
ccbb360e RS |
460 | (scroll-conservatively windows integer) |
461 | (scroll-margin windows integer) | |
4e371ce8 EZ |
462 | (hscroll-margin windows integer "22.1") |
463 | (hscroll-step windows number "22.1") | |
f0024d8c GM |
464 | (truncate-partial-width-windows |
465 | display | |
466 | (choice (integer :tag "Truncate if narrower than") | |
467 | (const :tag "Respect `truncate-lines'" nil) | |
468 | (other :tag "Truncate if not full-width" t)) | |
469 | "23.1") | |
2bc356d7 | 470 | (make-cursor-line-fully-visible windows boolean) |
e45db0fb | 471 | (mode-line-in-non-selected-windows mode-line boolean "22.1") |
37328bcd DL |
472 | (line-number-display-limit display |
473 | (choice integer | |
474 | (const :tag "No limit" nil))) | |
6671cab3 | 475 | (line-number-display-limit-width display integer "22.1") |
1444b0c0 PA |
476 | (highlight-nonselected-windows display boolean) |
477 | (message-log-max debug (choice (const :tag "Disable" nil) | |
478 | (integer :menu-tag "lines" | |
479 | :format "%v") | |
57f1dee4 GM |
480 | (other :tag "Unlimited" t)) |
481 | "24.3") | |
daba3e25 | 482 | (unibyte-display-via-language-environment mule boolean) |
bf247b6e | 483 | (blink-cursor-alist cursor alist "22.1") |
03c25271 | 484 | (overline-margin display integer "22.1") |
2a3bd2e1 | 485 | (underline-minimum-offset display integer "23.1") |
612c16f1 CY |
486 | (mouse-autoselect-window |
487 | display (choice | |
488 | (const :tag "Off (nil)" :value nil) | |
489 | (const :tag "Immediate" :value t) | |
490 | (number :tag "Delay by secs" :value 0.5)) "22.1") | |
f904c0f9 JD |
491 | (tool-bar-style |
492 | frames (choice | |
493 | (const :tag "Images" :value image) | |
494 | (const :tag "Text" :value text) | |
495 | (const :tag "Both" :value both) | |
496 | (const :tag "Both-horiz" :value both-horiz) | |
8a52f00a | 497 | (const :tag "Text-image-horiz" :value text-image-horiz) |
0c3461de GM |
498 | (const :tag "System default" :value nil)) "24.1") |
499 | (tool-bar-max-label-size frames integer "24.1") | |
ec514007 | 500 | (auto-hscroll-mode scrolling boolean "21.1") |
2bc356d7 CY |
501 | (void-text-area-pointer cursor |
502 | (choice | |
503 | (const :tag "Standard (text pointer)" :value nil) | |
504 | (const :tag "Arrow" :value arrow) | |
505 | (const :tag "Text pointer" :value text) | |
506 | (const :tag "Hand" :value hand) | |
507 | (const :tag "Vertical dragger" :value vdrag) | |
508 | (const :tag "Horizontal dragger" :value hdrag) | |
509 | (const :tag "Same as mode line" :value modeline) | |
510 | (const :tag "Hourglass" :value hourglass))) | |
ec514007 GM |
511 | (display-hourglass cursor boolean) |
512 | (hourglass-delay cursor number) | |
f904c0f9 | 513 | |
e5f51929 | 514 | ;; xfaces.c |
6671cab3 | 515 | (scalable-fonts-allowed display boolean "22.1") |
1444b0c0 PA |
516 | ;; xfns.c |
517 | (x-bitmap-file-path installation | |
0849a37e | 518 | (repeat (directory :format "%v"))) |
c4823934 | 519 | (x-gtk-use-old-file-dialog menu boolean "22.1") |
91b5a204 | 520 | (x-gtk-show-hidden-files menu boolean "22.1") |
c4823934 | 521 | (x-gtk-file-dialog-help-text menu boolean "22.1") |
0dd95b49 | 522 | (x-gtk-whole-detached-tool-bar x boolean "22.1") |
aa1859f5 | 523 | (x-gtk-use-system-tooltips tooltip boolean "23.3") |
0849a37e | 524 | ;; xterm.c |
4e371ce8 | 525 | (x-use-underline-position-properties display boolean "22.1") |
03c25271 | 526 | (x-underline-at-descent-line display boolean "22.1") |
dfb3c4c6 | 527 | (x-stretch-cursor display boolean "21.1") |
616763d5 | 528 | (scroll-bar-adjust-thumb-portion windows boolean "24.4") |
c1ca42b4 CY |
529 | ;; xselect.c |
530 | (x-select-enable-clipboard-manager killing boolean "24.1") | |
dfb3c4c6 JD |
531 | ;; xsettings.c |
532 | (font-use-system-font font-selection boolean "23.2"))) | |
ec514007 | 533 | this symbol group type standard version native-p rest prop propval |
4883633e RS |
534 | ;; This function turns a value |
535 | ;; into an expression which produces that value. | |
536 | (quoter (lambda (sexp) | |
537 | (if (or (memq sexp '(t nil)) | |
017266f8 | 538 | (keywordp sexp) |
4883633e RS |
539 | (and (listp sexp) |
540 | (memq (car sexp) '(lambda))) | |
541 | (stringp sexp) | |
37328bcd | 542 | (numberp sexp)) |
4883633e RS |
543 | sexp |
544 | (list 'quote sexp))))) | |
71296446 | 545 | (while all |
1444b0c0 PA |
546 | (setq this (car all) |
547 | all (cdr all) | |
548 | symbol (nth 0 this) | |
549 | group (nth 1 this) | |
00377857 | 550 | type (nth 2 this) |
37328bcd | 551 | version (nth 3 this) |
c8c59954 | 552 | rest (nthcdr 4 this) |
a200d998 RS |
553 | ;; If we did not specify any standard value expression above, |
554 | ;; use the current value as the standard value. | |
c8c59954 GM |
555 | standard (if (setq prop (memq :standard rest)) |
556 | (cadr prop) | |
557 | (if (default-boundp symbol) | |
558 | (funcall quoter (default-value symbol)))) | |
00377857 EZ |
559 | ;; Don't complain about missing variables which are |
560 | ;; irrelevant to this platform. | |
561 | native-p (save-match-data | |
562 | (cond | |
563 | ((string-match "\\`dos-" (symbol-name symbol)) | |
564 | (eq system-type 'ms-dos)) | |
565 | ((string-match "\\`w32-" (symbol-name symbol)) | |
566 | (eq system-type 'windows-nt)) | |
77346ecd EZ |
567 | ((string-match "\\`ns-" (symbol-name symbol)) |
568 | (featurep 'ns)) | |
2702394e | 569 | ((string-match "\\`x-.*gtk" (symbol-name symbol)) |
79cf2123 | 570 | (featurep 'gtk)) |
78e8b10a CY |
571 | ((string-match "clipboard-manager" (symbol-name symbol)) |
572 | (boundp 'x-select-enable-clipboard-manager)) | |
197a09bf EZ |
573 | ((string-match "\\`x-" (symbol-name symbol)) |
574 | (fboundp 'x-create-frame)) | |
6eb33acb EZ |
575 | ((string-match "selection" (symbol-name symbol)) |
576 | (fboundp 'x-selection-exists-p)) | |
577 | ((string-match "fringe" (symbol-name symbol)) | |
578 | (fboundp 'define-fringe-bitmap)) | |
af008560 GM |
579 | ((string-match "\\`imagemagick" (symbol-name symbol)) |
580 | (fboundp 'imagemagick-types)) | |
8b571bf3 JD |
581 | ((equal "font-use-system-font" (symbol-name symbol)) |
582 | (featurep 'system-font-setting)) | |
c0162ade EZ |
583 | ;; Conditioned on x-create-frame, because that's |
584 | ;; the condition for loadup.el to preload tool-bar.el. | |
585 | ((string-match "tool-bar-" (symbol-name symbol)) | |
586 | (fboundp 'x-create-frame)) | |
f31237a4 EZ |
587 | ((equal "vertical-centering-font-regexp" |
588 | (symbol-name symbol)) | |
589 | ;; Any function from fontset.c will do. | |
590 | (fboundp 'new-fontset)) | |
ad33a799 EZ |
591 | ((equal "scroll-bar-adjust-thumb-portion" |
592 | (symbol-name symbol)) | |
593 | (featurep 'x)) | |
00377857 | 594 | (t t)))) |
1444b0c0 PA |
595 | (if (not (boundp symbol)) |
596 | ;; If variables are removed from C code, give an error here! | |
00377857 EZ |
597 | (and native-p |
598 | (message "Note, built-in variable `%S' not bound" symbol)) | |
4883633e RS |
599 | ;; Save the standard value, unless we already did. |
600 | (or (get symbol 'standard-value) | |
a200d998 | 601 | (put symbol 'standard-value (list standard))) |
ec514007 GM |
602 | ;; We need these properties independent of whether cus-start is loaded. |
603 | (if (setq prop (memq :safe rest)) | |
604 | (put symbol 'safe-local-variable (cadr prop))) | |
605 | (if (setq prop (memq :risky rest)) | |
606 | (put symbol 'risky-local-variable (cadr prop))) | |
88f43c67 GM |
607 | (if (setq prop (memq :set rest)) |
608 | (put symbol 'custom-set (cadr prop))) | |
9d794026 GM |
609 | ;; Note this is the _only_ initialize property we handle. |
610 | (if (eq (cadr (memq :initialize rest)) 'custom-initialize-delay) | |
611 | (push symbol custom-delayed-init-variables)) | |
88f43c67 GM |
612 | ;; If this is NOT while dumping Emacs, set up the rest of the |
613 | ;; customization info. This is the stuff that is not needed | |
614 | ;; until someone does M-x customize etc. | |
4883633e | 615 | (unless purify-flag |
9d794026 GM |
616 | ;; Add it to the right group(s). |
617 | (if (listp group) | |
618 | (dolist (g group) | |
619 | (custom-add-to-group g symbol 'custom-variable)) | |
620 | (custom-add-to-group group symbol 'custom-variable)) | |
4883633e | 621 | ;; Set the type. |
37328bcd | 622 | (put symbol 'custom-type type) |
c8c59954 | 623 | (if version (put symbol 'custom-version version)) |
ec514007 GM |
624 | (while rest |
625 | (setq prop (car rest) | |
626 | propval (cadr rest) | |
627 | rest (nthcdr 2 rest)) | |
c8c59954 | 628 | (cond ((memq prop '(:standard :risky :safe :set))) ; handled above |
ec514007 GM |
629 | ((eq prop :tag) |
630 | (put symbol 'custom-tag propval)))))))) | |
4883633e | 631 | |
ecf5279a | 632 | (custom-add-to-group 'iswitchb 'read-buffer-function 'custom-variable) |
6b61353c KH |
633 | (custom-add-to-group 'font-lock 'open-paren-in-column-0-is-defun-start |
634 | 'custom-variable) | |
ecf5279a | 635 | |
ec514007 GM |
636 | ;; Record cus-start as loaded if we have set up all the info that we can. |
637 | ;; Don't record it as loaded if we have only set up the standard values | |
638 | ;; and safe/risky properties. | |
4883633e RS |
639 | (unless purify-flag |
640 | (provide 'cus-start)) | |
1444b0c0 | 641 | |
1cd7adc6 | 642 | ;;; cus-start.el ends here |