1 ;;; cus-start.el --- define customization properties of builtins
3 ;; Copyright (C) 1997, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
5 ;; Author: Per Abrahamsen <abraham@dina.kvl.dk>
8 ;; This file is part of GNU Emacs.
10 ;; GNU Emacs is free software; you can redistribute it and/or modify
11 ;; it under the terms of the GNU General Public License as published by
12 ;; the Free Software Foundation; either version 2, or (at your option)
15 ;; GNU Emacs is distributed in the hope that it will be useful,
16 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;; GNU General Public License for more details.
20 ;; You should have received a copy of the GNU General Public License
21 ;; along with GNU Emacs; see the file COPYING. If not, write to the
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
23 ;; Boston, MA 02111-1307, USA.
27 ;; This file adds customize support for built-in variables.
29 ;; While dumping Emacs, this file is loaded, but it only records
30 ;; the standard values; it does not do the rest of the job.
31 ;; Later on, if the user makes a customization buffer,
32 ;; this file is loaded again with (require 'cus-start);
33 ;; then it does the whole job.
37 (let ((all '(;; abbrev.c
38 (abbrev-all-caps abbrev-mode boolean
)
39 (pre-abbrev-expand-hook abbrev-mode hook
)
41 (gc-cons-threshold alloc integer
)
42 (undo-limit undo integer
)
43 (undo-strong-limit undo integer
)
44 (garbage-collection-messages alloc boolean
)
46 (mode-line-format modeline sexp
) ;Hard to do right.
47 (default-major-mode internal function
)
48 (enable-multibyte-characters mule boolean
)
49 (case-fold-search matching boolean
)
50 (fill-column fill integer
)
51 (left-margin fill integer
)
52 (tab-width editing-basics integer
)
53 (ctl-arrow display boolean
)
54 (truncate-lines display boolean
)
55 (selective-display-ellipses display boolean
)
56 (transient-mark-mode editing-basics boolean
)
57 (indicate-empty-lines display boolean
"21.1")
58 (scroll-up-aggressively windows boolean
"21.1")
59 (scroll-down-aggressively windows boolean
"21.1")
61 (mark-even-if-inactive editing-basics boolean
)
63 (shell-file-name execute file
)
65 (repeat (choice (const :tag
"default" nil
)
66 (file :format
"%v"))))
68 (charset-map-directory installation directory
)
70 (inhibit-eol-conversion mule boolean
)
71 (eol-mnemonic-undecided mule string
)
72 (eol-mnemonic-unix mule string
)
73 (eol-mnemonic-dos mule string
)
74 (eol-mnemonic-mac mule string
)
75 (file-coding-system-alist
78 :key-type
(regexp :tag
"File regexp")
80 :value
(undecided . undecided
)
81 (cons :tag
"Encoding/decoding pair"
82 :value
(undecided . undecided
)
83 (coding-system :tag
"Decoding")
84 (coding-system :tag
"Encoding"))
85 (coding-system :tag
"Single coding system"
87 (function :value ignore
))))
89 (completion-ignored-extensions dired
90 (repeat (string :format
"%v")))
92 (baud-rate display integer
)
93 (inverse-video display boolean
)
94 (visible-bell display boolean
)
95 (no-redraw-on-reenter display boolean
)
97 (user-full-name mail string
)
99 (max-specpdl-size limits integer
)
100 (max-lisp-eval-depth limits integer
)
101 (stack-trace-on-error debug
102 (choice (const :tag
"off")
103 (repeat :menu-tag
"When"
105 (symbol :format
"%v"))
106 (const :tag
"always" t
)))
107 (debug-on-error debug
108 (choice (const :tag
"off")
109 (repeat :menu-tag
"When"
111 (symbol :format
"%v"))
112 (const :tag
"always" t
)))
113 (debug-ignored-errors debug
(repeat (choice symbol regexp
)))
115 (choice (const :tag
"off")
116 (repeat :menu-tag
"When"
118 (symbol :format
"%v"))
119 (const :tag
"always" t
)))
121 (insert-default-directory minibuffer boolean
)
123 (use-dialog-box menu boolean
"21.1")
125 (default-frame-alist frames
126 (repeat (cons :format
"%v"
127 (symbol :tag
"Parameter")
128 (sexp :tag
"Value"))))
129 (mouse-highlight mouse
(choice (const :tag
"disabled" nil
)
130 (const :tag
"always shown" t
)
131 (other :tag
"hidden by keypress" 1)))
133 (indent-tabs-mode fill boolean
)
135 (meta-prefix-char keyboard character
)
136 (auto-save-interval auto-save integer
)
137 (auto-save-timeout auto-save
(choice (const :tag
"off" nil
)
138 (integer :format
"%v")))
139 (echo-keystrokes minibuffer number
)
140 (polling-period keyboard integer
)
141 (double-click-time mouse
(restricted-sexp
142 :match-alternatives
(integerp 'nil
't
)))
143 (inhibit-local-menu-bar-menus menu boolean
)
144 (help-char keyboard character
)
145 (help-event-list keyboard
(repeat (sexp :format
"%v")))
146 (menu-prompting menu boolean
)
147 (suggest-key-bindings keyboard
(choice (const :tag
"off" nil
)
148 (integer :tag
"time" 2)
151 ;; This is not good news because it will use the wrong
152 ;; version-specific directories when you upgrade. We need
153 ;; customization of the front of the list, maintaining the standard
154 ;; value intact at the back.
155 ;;; (load-path environment
156 ;;; (repeat (choice :tag "[Current dir?]"
157 ;;; :format "%[Current dir?%] %v"
158 ;;; (const :tag " current dir" nil)
159 ;;; (directory :format "%v"))))
161 (completion-auto-help minibuffer boolean
)
162 (enable-recursive-minibuffers minibuffer boolean
)
163 (history-length minibuffer
164 (choice (const :tag
"Infinite" t
)
166 (minibuffer-prompt-properties
170 (const :tag
"Read-Only"
171 :doc
"Prevent prompt from being modified"
175 (const :tag
"Inviolable"
176 :doc
"Prevent point from ever entering prompt"
179 (point-entered minibuffer-avoid-prompt
)))
181 :tag
"Other Properties"
184 (symbol :tag
"Property")
185 (sexp :tag
"Value"))))
187 (minibuffer-auto-raise minibuffer boolean
)
188 ;; options property set at end
189 (read-buffer-function minibuffer
191 (function-item iswitchb-read-buffer
)
194 (dos-unsupported-char-glyph display integer
)
196 (delete-exited-processes processes-basics boolean
)
198 (parse-sexp-ignore-comments editing-basics boolean
)
199 (words-include-escapes editing-basics boolean
)
201 (temp-buffer-show-function windows
(choice (const nil
) function
))
202 (display-buffer-function windows
(choice (const nil
) function
))
203 (pop-up-frames frames boolean
)
204 (pop-up-frame-function frames function
)
205 (special-display-buffer-names
207 (repeat (choice :tag
"Buffer"
209 (string :format
"%v")
210 (cons :tag
"With attributes"
213 (string :format
"%v")
214 (repeat :tag
"Attributes"
216 (symbol :tag
"Parameter")
217 (sexp :tag
"Value")))))))
218 (special-display-regexps
220 (repeat (choice :tag
"Buffer"
222 (regexp :format
"%v")
223 (cons :tag
"With attributes"
226 (regexp :format
"%v")
227 (repeat :tag
"Attributes"
229 (symbol :tag
"Parameter")
230 (sexp :tag
"Value")))))))
231 (special-display-function frames function
)
232 (same-window-buffer-names windows
(repeat (string :format
"%v")))
233 (same-window-regexps windows
(repeat (regexp :format
"%v")))
234 (pop-up-windows windows boolean
)
235 (even-window-heights windows boolean
)
236 (next-screen-context-lines windows integer
)
237 (split-height-threshold windows integer
)
238 (window-min-height windows integer
)
239 (window-min-width windows integer
)
240 (scroll-preserve-screen-position windows boolean
)
241 (display-buffer-reuse-frames windows boolean
"21.1")
243 (scroll-step windows integer
)
244 (scroll-conservatively windows integer
)
245 (scroll-margin windows integer
)
246 (automatic-hscroll-margin windows integer
"21.3")
247 (automatic-hscroll-step windows number
"21.3")
248 (truncate-partial-width-windows display boolean
)
249 (mode-line-inverse-video modeline boolean
)
250 (mode-line-in-non-selected-windows modeline boolean
"21.3")
251 (line-number-display-limit display
253 (const :tag
"No limit" nil
)))
254 (highlight-nonselected-windows display boolean
)
255 (message-log-max debug
(choice (const :tag
"Disable" nil
)
256 (integer :menu-tag
"lines"
258 (other :tag
"Unlimited" t
)))
259 (unibyte-display-via-language-environment mule boolean
)
261 (x-bitmap-file-path installation
262 (repeat (directory :format
"%v")))
264 (x-autoselect-window display boolean
"21.3")
265 (x-use-underline-position-properties display boolean
"21.3")
266 (x-stretch-cursor display boolean
"21.1")))
267 this symbol group type native-p version
268 ;; This function turns a value
269 ;; into an expression which produces that value.
270 (quoter (lambda (sexp)
271 (if (or (memq sexp
'(t nil
))
274 (memq (car sexp
) '(lambda)))
276 ;; (and (fboundp 'characterp)
277 ;; (characterp sexp))
280 (list 'quote sexp
)))))
288 ;; Don't complain about missing variables which are
289 ;; irrelevant to this platform.
290 native-p
(save-match-data
292 ((string-match "\\`dos-" (symbol-name symbol
))
293 (eq system-type
'ms-dos
))
294 ((string-match "\\`w32-" (symbol-name symbol
))
295 (eq system-type
'windows-nt
))
296 ((string-match "\\`x-" (symbol-name symbol
))
297 (fboundp 'x-create-frame
))
299 (if (not (boundp symbol
))
300 ;; If variables are removed from C code, give an error here!
302 (message "Note, built-in variable `%S' not bound" symbol
))
303 ;; Save the standard value, unless we already did.
304 (or (get symbol
'standard-value
)
305 (put symbol
'standard-value
306 (list (funcall quoter
(default-value symbol
)))))
307 ;; If this is NOT while dumping Emacs,
308 ;; set up the rest of the customization info.
310 ;; Add it to the right group.
311 (custom-add-to-group group symbol
'custom-variable
)
313 (put symbol
'custom-type type
)
314 (put symbol
'custom-version version
)))))
316 (custom-add-to-group 'iswitchb
'read-buffer-function
'custom-variable
)
318 ;; Record cus-start as loaded
319 ;; if we have set up all the info that we can set up.
320 ;; Don't record cus-start as loaded
321 ;; if we have set up only the standard values.
323 (provide 'cus-start
))
325 ;;; cus-start.el ends here