diff options
| author | Richard M. Stallman | 2005-12-30 22:58:31 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2005-12-30 22:58:31 +0000 |
| commit | 8913f945ec49e5f647ab5d405bab8c7aee40b183 (patch) | |
| tree | 8e6ec9a9bd6d93652f422a6a71d35d1ef0c2a029 | |
| parent | a8d6ee3c532d9bdc5925b49b0e589059393c3ca4 (diff) | |
| download | emacs-8913f945ec49e5f647ab5d405bab8c7aee40b183.tar.gz emacs-8913f945ec49e5f647ab5d405bab8c7aee40b183.zip | |
(custom-load-themes): Function deleted.
| -rw-r--r-- | lisp/ChangeLog | 2 | ||||
| -rw-r--r-- | lisp/custom.el | 37 |
2 files changed, 18 insertions, 21 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index aaadc554715..54bb2ee6687 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,7 @@ | |||
| 1 | 2005-12-30 Richard M. Stallman <rms@gnu.org> | 1 | 2005-12-30 Richard M. Stallman <rms@gnu.org> |
| 2 | 2 | ||
| 3 | * custom.el (custom-load-themes): Function deleted. | ||
| 4 | |||
| 3 | * cus-edit.el (custom-save-loaded-themes): Function deleted. | 5 | * cus-edit.el (custom-save-loaded-themes): Function deleted. |
| 4 | (custom-save-variables): Don't delete or add custom-load-themes call. | 6 | (custom-save-variables): Don't delete or add custom-load-themes call. |
| 5 | 7 | ||
diff --git a/lisp/custom.el b/lisp/custom.el index df2488bda40..66f6dc06c65 100644 --- a/lisp/custom.el +++ b/lisp/custom.el | |||
| @@ -1057,9 +1057,9 @@ The first one is always `user'.") | |||
| 1057 | (memq theme custom-enabled-themes)) | 1057 | (memq theme custom-enabled-themes)) |
| 1058 | 1058 | ||
| 1059 | (defun provide-theme (theme) | 1059 | (defun provide-theme (theme) |
| 1060 | "Indicate that this file provides THEME. | 1060 | "Indicate that this file provides THEME, and mark it as enabled. |
| 1061 | Add THEME to `custom-loaded-themes', and `provide' whatever | 1061 | Add THEME to `custom-loaded-themes' and `custom-enabled-themes', |
| 1062 | feature name is stored in THEME's property `theme-feature'. | 1062 | and `provide' the feature name stored in THEME's property `theme-feature'. |
| 1063 | 1063 | ||
| 1064 | Usually the `theme-feature' property contains a symbol created | 1064 | Usually the `theme-feature' property contains a symbol created |
| 1065 | by `custom-make-theme-feature'." | 1065 | by `custom-make-theme-feature'." |
| @@ -1120,12 +1120,6 @@ All the themes loaded for BY-THEME are recorded in BY-THEME's property | |||
| 1120 | (load-theme theme))) | 1120 | (load-theme theme))) |
| 1121 | (push theme themes-loaded)) | 1121 | (push theme themes-loaded)) |
| 1122 | (put by-theme 'theme-loads-themes themes-loaded))) | 1122 | (put by-theme 'theme-loads-themes themes-loaded))) |
| 1123 | |||
| 1124 | (defun custom-load-themes (&rest body) | ||
| 1125 | "Load themes for the USER theme as specified by BODY. | ||
| 1126 | |||
| 1127 | See `custom-theme-load-themes' for more information on BODY." | ||
| 1128 | (apply 'custom-theme-load-themes 'user body)) | ||
| 1129 | 1123 | ||
| 1130 | ;;; Enabling and disabling loaded themes. | 1124 | ;;; Enabling and disabling loaded themes. |
| 1131 | 1125 | ||
| @@ -1138,8 +1132,8 @@ This signals an error if THEME does not specify any theme | |||
| 1138 | settings. Theme settings are set using `load-theme'." | 1132 | settings. Theme settings are set using `load-theme'." |
| 1139 | (interactive "SEnable Custom theme: ") | 1133 | (interactive "SEnable Custom theme: ") |
| 1140 | (let ((settings (get theme 'theme-settings))) | 1134 | (let ((settings (get theme 'theme-settings))) |
| 1141 | (if (and (not (eq theme 'user)) (null settings)) | 1135 | (unless (or (eq theme 'user) (memq theme custom-loaded-themes)) |
| 1142 | (error "No theme settings defined in %s." (symbol-name theme))) | 1136 | (error "Theme %s not defined" (symbol-name theme))) |
| 1143 | (dolist (s settings) | 1137 | (dolist (s settings) |
| 1144 | (let* ((prop (car s)) | 1138 | (let* ((prop (car s)) |
| 1145 | (symbol (cadr s)) | 1139 | (symbol (cadr s)) |
| @@ -1157,17 +1151,18 @@ settings. Theme settings are set using `load-theme'." | |||
| 1157 | 1151 | ||
| 1158 | (defun disable-theme (theme) | 1152 | (defun disable-theme (theme) |
| 1159 | "Disable all variable and face settings defined by THEME. | 1153 | "Disable all variable and face settings defined by THEME. |
| 1160 | See `custom-known-themes' for a list of known themes." | 1154 | See `custom-enabled-themes' for a list of known themes." |
| 1161 | (interactive "SDisable Custom theme: ") | 1155 | (interactive "SDisable Custom theme: ") |
| 1162 | (let ((settings (get theme 'theme-settings))) | 1156 | (when (memq theme custom-enabled-themes) |
| 1163 | (dolist (s settings) | 1157 | (let ((settings (get theme 'theme-settings))) |
| 1164 | (let* ((prop (car s)) | 1158 | (dolist (s settings) |
| 1165 | (symbol (cadr s)) | 1159 | (let* ((prop (car s)) |
| 1166 | (spec-list (get symbol prop))) | 1160 | (symbol (cadr s)) |
| 1167 | (put symbol prop (assq-delete-all theme spec-list)) | 1161 | (spec-list (get symbol prop))) |
| 1168 | (if (eq prop 'theme-value) | 1162 | (put symbol prop (assq-delete-all theme spec-list)) |
| 1169 | (custom-theme-recalc-variable symbol) | 1163 | (if (eq prop 'theme-value) |
| 1170 | (custom-theme-recalc-face symbol))))) | 1164 | (custom-theme-recalc-variable symbol) |
| 1165 | (custom-theme-recalc-face symbol)))))) | ||
| 1171 | (setq custom-enabled-themes | 1166 | (setq custom-enabled-themes |
| 1172 | (delq theme custom-enabled-themes))) | 1167 | (delq theme custom-enabled-themes))) |
| 1173 | 1168 | ||