diff options
| author | Richard M. Stallman | 1996-01-05 07:22:20 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1996-01-05 07:22:20 +0000 |
| commit | a8840283de12e1073a6da9c35be1dd89feb64ac3 (patch) | |
| tree | f240c3886e1409d6d49b1bfd73599109ca2a3b5c | |
| parent | 5d0ba25bace0692c9eac5fb54aa6167a5436a32c (diff) | |
| download | emacs-a8840283de12e1073a6da9c35be1dd89feb64ac3.tar.gz emacs-a8840283de12e1073a6da9c35be1dd89feb64ac3.zip | |
(custom-default-validate): Fix message spelling.
(rear-nonsticky, custom-property-set, custom-field-accept,
custom-repeat-extract, custom-pair-extract, custom-list-extract,
custom-choice-extract, custom-choice-validate, custom-mode-map): Doc fix.
(custom-file): Use convert-standard-filename.
| -rw-r--r-- | lisp/custom.el | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/lisp/custom.el b/lisp/custom.el index c4e7a4a870a..7e9425fd466 100644 --- a/lisp/custom.el +++ b/lisp/custom.el | |||
| @@ -15,7 +15,7 @@ | |||
| 15 | ;; editing a text file in some arcane syntax is user hostile in the | 15 | ;; editing a text file in some arcane syntax is user hostile in the |
| 16 | ;; extreme, and to most users emacs lisp definitely count as arcane. | 16 | ;; extreme, and to most users emacs lisp definitely count as arcane. |
| 17 | ;; | 17 | ;; |
| 18 | ;; The intension is that authors of emacs lisp packages declare the | 18 | ;; The intent is that authors of emacs lisp packages declare the |
| 19 | ;; variables intended for user customization with `custom-declare'. | 19 | ;; variables intended for user customization with `custom-declare'. |
| 20 | ;; Custom can then automatically generate a customization buffer with | 20 | ;; Custom can then automatically generate a customization buffer with |
| 21 | ;; `custom-buffer-create' where the user can edit the package | 21 | ;; `custom-buffer-create' where the user can edit the package |
| @@ -46,7 +46,7 @@ | |||
| 46 | ;; - Make it possible to declare default value and type for a single | 46 | ;; - Make it possible to declare default value and type for a single |
| 47 | ;; variable, storing the data in a symbol property. | 47 | ;; variable, storing the data in a symbol property. |
| 48 | ;; - Syntactic sugar for CUSTOM declarations. | 48 | ;; - Syntactic sugar for CUSTOM declarations. |
| 49 | ;; - Use W3 for variable documenation. | 49 | ;; - Use W3 for variable documentation. |
| 50 | 50 | ||
| 51 | ;;; Code: | 51 | ;;; Code: |
| 52 | 52 | ||
| @@ -244,12 +244,12 @@ If called interactively, prompts for a face and face attributes." | |||
| 244 | (> emacs-minor-version 28)))) | 244 | (> emacs-minor-version 28)))) |
| 245 | (setq intangible 'intangible) | 245 | (setq intangible 'intangible) |
| 246 | (setq intangible 'intangible-if-it-had-been-working)) | 246 | (setq intangible 'intangible-if-it-had-been-working)) |
| 247 | "The symbol making text intangible") | 247 | "The symbol making text intangible.") |
| 248 | 248 | ||
| 249 | (defconst rear-nonsticky (if (string-match "XEmacs" emacs-version) | 249 | (defconst rear-nonsticky (if (string-match "XEmacs" emacs-version) |
| 250 | 'end-open | 250 | 'end-open |
| 251 | 'rear-nonsticky) | 251 | 'rear-nonsticky) |
| 252 | "The symbol making text proeprties non-sticky in the rear end.") | 252 | "The symbol making text properties non-sticky in the rear end.") |
| 253 | 253 | ||
| 254 | (defconst front-sticky (if (string-match "XEmacs" emacs-version) | 254 | (defconst front-sticky (if (string-match "XEmacs" emacs-version) |
| 255 | 'front-closed | 255 | 'front-closed |
| @@ -394,14 +394,14 @@ If called interactively, prompts for a face and face attributes." | |||
| 394 | ;; The following functions are part of the public interface to the | 394 | ;; The following functions are part of the public interface to the |
| 395 | ;; CUSTOM datastructure. Each CUSTOM describes a group of variables, | 395 | ;; CUSTOM datastructure. Each CUSTOM describes a group of variables, |
| 396 | ;; a single variable, or a component of a structured variable. The | 396 | ;; a single variable, or a component of a structured variable. The |
| 397 | ;; CUSTOM instances are part of two hiearachies, the first is the | 397 | ;; CUSTOM instances are part of two hierarchies, the first is the |
| 398 | ;; `part-of' hierarchy in which each CUSTOM is a component of another | 398 | ;; `part-of' hierarchy in which each CUSTOM is a component of another |
| 399 | ;; CUSTOM, except for the top level CUSTOM which is contained in | 399 | ;; CUSTOM, except for the top level CUSTOM which is contained in |
| 400 | ;; `custom-data'. The second hiearachy is a `is-a' type hierarchy | 400 | ;; `custom-data'. The second hierarchy is a `is-a' type hierarchy |
| 401 | ;; where each CUSTOM is a leaf in the hierarchy defined by the `type' | 401 | ;; where each CUSTOM is a leaf in the hierarchy defined by the `type' |
| 402 | ;; property and `custom-type-properties'. | 402 | ;; property and `custom-type-properties'. |
| 403 | 403 | ||
| 404 | (defvar custom-file "~/.custom.el" | 404 | (defvar custom-file (convert-standard-filename "~/.custom.el") |
| 405 | "Name of file with customization information.") | 405 | "Name of file with customization information.") |
| 406 | 406 | ||
| 407 | (defconst custom-data | 407 | (defconst custom-data |
| @@ -729,7 +729,7 @@ Entries in this list take precedence over `custom-type-properties'.") | |||
| 729 | (cdr entry))) | 729 | (cdr entry))) |
| 730 | 730 | ||
| 731 | (defun custom-property-set (custom property value) | 731 | (defun custom-property-set (custom property value) |
| 732 | "Set CUSTOM PROPERY to VALUE by side effect. | 732 | "Set CUSTOM PROPERTY to VALUE by side effect. |
| 733 | CUSTOM must have at least one property already." | 733 | CUSTOM must have at least one property already." |
| 734 | (let ((entry (assq property custom))) | 734 | (let ((entry (assq property custom))) |
| 735 | (if entry | 735 | (if entry |
| @@ -878,7 +878,7 @@ position of the error, and the cdr is a text describing the error." | |||
| 878 | ;; FIELD datatype. The FIELD instance hold information about a | 878 | ;; FIELD datatype. The FIELD instance hold information about a |
| 879 | ;; specific editing field in the customization buffer. | 879 | ;; specific editing field in the customization buffer. |
| 880 | ;; | 880 | ;; |
| 881 | ;; Each FIELD can be seen as an instanciation of a CUSTOM. | 881 | ;; Each FIELD can be seen as an instantiation of a CUSTOM. |
| 882 | 882 | ||
| 883 | (defvar custom-field-last nil) | 883 | (defvar custom-field-last nil) |
| 884 | ;; Last field containing point. | 884 | ;; Last field containing point. |
| @@ -937,7 +937,7 @@ START and END are markers to the start and end of the field." | |||
| 937 | 937 | ||
| 938 | (defun custom-field-accept (field value &optional original) | 938 | (defun custom-field-accept (field value &optional original) |
| 939 | "Store a new value into field FIELD, taking it from VALUE. | 939 | "Store a new value into field FIELD, taking it from VALUE. |
| 940 | If optional ORIGINAL is non-nil, concider VALUE for the original value." | 940 | If optional ORIGINAL is non-nil, consider VALUE for the original value." |
| 941 | (let ((inhibit-point-motion-hooks t)) | 941 | (let ((inhibit-point-motion-hooks t)) |
| 942 | (funcall (custom-property (custom-field-custom field) 'accept) | 942 | (funcall (custom-property (custom-field-custom field) 'accept) |
| 943 | field value original))) | 943 | field value original))) |
| @@ -1100,7 +1100,7 @@ If optional ORIGINAL is non-nil, concider VALUE for the original value." | |||
| 1100 | (cons (nreverse matches) values))) | 1100 | (cons (nreverse matches) values))) |
| 1101 | 1101 | ||
| 1102 | (defun custom-repeat-extract (custom field) | 1102 | (defun custom-repeat-extract (custom field) |
| 1103 | "Extract list of childrens values." | 1103 | "Extract list of children's values." |
| 1104 | (let ((values (custom-field-value field)) | 1104 | (let ((values (custom-field-value field)) |
| 1105 | (data (custom-data custom)) | 1105 | (data (custom-data custom)) |
| 1106 | result) | 1106 | result) |
| @@ -1147,7 +1147,7 @@ If optional ORIGINAL is non-nil, concider VALUE for the original value." | |||
| 1147 | (custom-default-quote custom value))) | 1147 | (custom-default-quote custom value))) |
| 1148 | 1148 | ||
| 1149 | (defun custom-pair-extract (custom field) | 1149 | (defun custom-pair-extract (custom field) |
| 1150 | "Extract cons of childrens values." | 1150 | "Extract cons of children's values." |
| 1151 | (let ((values (custom-field-value field)) | 1151 | (let ((values (custom-field-value field)) |
| 1152 | (data (custom-data custom)) | 1152 | (data (custom-data custom)) |
| 1153 | result) | 1153 | result) |
| @@ -1168,7 +1168,7 @@ If optional ORIGINAL is non-nil, concider VALUE for the original value." | |||
| 1168 | (custom-default-quote custom value))) | 1168 | (custom-default-quote custom value))) |
| 1169 | 1169 | ||
| 1170 | (defun custom-list-extract (custom field) | 1170 | (defun custom-list-extract (custom field) |
| 1171 | "Extract list of childrens values." | 1171 | "Extract list of children's values." |
| 1172 | (let ((values (custom-field-value field)) | 1172 | (let ((values (custom-field-value field)) |
| 1173 | (data (custom-data custom)) | 1173 | (data (custom-data custom)) |
| 1174 | result) | 1174 | result) |
| @@ -1373,12 +1373,12 @@ If optional ORIGINAL is non-nil, concider VALUE for the original value." | |||
| 1373 | (custom-field-move field from end)))) | 1373 | (custom-field-move field from end)))) |
| 1374 | 1374 | ||
| 1375 | (defun custom-choice-extract (custom field) | 1375 | (defun custom-choice-extract (custom field) |
| 1376 | "Extract childs value." | 1376 | "Extract child's value." |
| 1377 | (let ((value (custom-field-value field))) | 1377 | (let ((value (custom-field-value field))) |
| 1378 | (custom-field-extract (custom-field-custom value) value))) | 1378 | (custom-field-extract (custom-field-custom value) value))) |
| 1379 | 1379 | ||
| 1380 | (defun custom-choice-validate (custom field) | 1380 | (defun custom-choice-validate (custom field) |
| 1381 | "Validate childs value." | 1381 | "Validate child's value." |
| 1382 | (let ((value (custom-field-value field)) | 1382 | (let ((value (custom-field-value field)) |
| 1383 | (custom (custom-field-custom field))) | 1383 | (custom (custom-field-custom field))) |
| 1384 | (if (or (eq value custom-nil) | 1384 | (if (or (eq value custom-nil) |
| @@ -1666,7 +1666,7 @@ FG BG STIPPLE BOLD ITALIC UNDERLINE" | |||
| 1666 | (cond ((eq value custom-nil) | 1666 | (cond ((eq value custom-nil) |
| 1667 | (cons start "Uninitialized field")) | 1667 | (cons start "Uninitialized field")) |
| 1668 | ((and (consp value) (eq (car value) custom-invalid)) | 1668 | ((and (consp value) (eq (car value) custom-invalid)) |
| 1669 | (cons start "Unparseable field content")) | 1669 | (cons start "Unparsable field content")) |
| 1670 | ((custom-valid custom value) | 1670 | ((custom-valid custom value) |
| 1671 | nil) | 1671 | nil) |
| 1672 | (t | 1672 | (t |
| @@ -1830,7 +1830,7 @@ If the optional argument SAVE is non-nil, use that for saving changes." | |||
| 1830 | ;; The Customization major mode and interactive commands. | 1830 | ;; The Customization major mode and interactive commands. |
| 1831 | 1831 | ||
| 1832 | (defvar custom-mode-map nil | 1832 | (defvar custom-mode-map nil |
| 1833 | "Keymap for Custum Mode.") | 1833 | "Keymap for Custom Mode.") |
| 1834 | (if custom-mode-map | 1834 | (if custom-mode-map |
| 1835 | nil | 1835 | nil |
| 1836 | (setq custom-mode-map (make-sparse-keymap)) | 1836 | (setq custom-mode-map (make-sparse-keymap)) |