1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-11 09:20:51 +00:00
Commit Graph

49 Commits

Author SHA1 Message Date
Chong Yidong
c5dd5a516c Print theme summaries in *Custom Themes* buffer.
* lisp/cus-theme.el (describe-theme-1): Use custom-theme-p.
(custom-theme-summary): New function.
(customize-themes): Use it.

* etc/themes/light-blue-theme.el:
* etc/themes/misterioso-theme.el:
* etc/themes/tango-dark-theme.el:
* etc/themes/tango-theme.el:
* etc/themes/tsdh-dark-theme.el:
* etc/themes/tsdh-light-theme.el:
* etc/themes/wheatgrass-theme.el:
* etc/themes/wombat-theme.el: Tweak summaries for better listability.
2011-06-14 01:06:26 -04:00
Juanma Barranquero
06b605171f lisp/*.el: Lexical-binding cleanup. 2011-04-19 15:44:55 +02:00
Chong Yidong
4359915b86 Several fixes to cus-theme.el.
* lisp/cus-theme.el: Add missing provide statement.
(customize-create-theme): Extract theme value correctly.
(custom-theme-visit-theme): Autoload.
(customize-create-theme): Prompt before inserting default faces.
2011-03-21 00:30:55 -04:00
Chong Yidong
928f4e732d Drop use of unsafep for checking Custom themes; bugfixes.
* lisp/custom.el (load-theme): Define return value.  Drop use of
unsafep; call custom-theme-load-confirm for non-known-safe themes.
(custom-theme-load-confirm): Scroll in the correct window.
(custom-enabled-themes): Add custom-safe-themes to :set-after.

* lisp/cus-theme.el (custom-theme-checkbox-toggle): Don't activate the
checkbox if load-theme fails.
2011-02-01 12:34:07 -05:00
Glenn Morris
73b0cd5003 Convert consecutive FSF copyright years to ranges. 2011-01-24 20:08:28 -08:00
Glenn Morris
0d9f702fd0 Nuke arch-tags. 2011-01-15 15:16:57 -08:00
Stefan Monnier
77ab81d054 Merge from emacs-23 2011-01-14 12:18:41 -05:00
Chong Yidong
b2948a8779 * cus-theme.el (customize-themes): Use switch-to-buffer.
* menu-bar.el (menu-bar-custom-menu): Tweak Mule and Customize
menus.  Add menu item for customize-themes.
2011-01-12 14:10:00 -05:00
Glenn Morris
5df4f04cd3 Add 2011 to FSF/AIST copyright years. 2011-01-02 15:50:46 -08:00
Chong Yidong
392f875a3b Fix a misleading widget message in the last checkin. 2010-10-16 20:05:20 -04:00
Chong Yidong
29a4c45b98 Allow Custom settings to be migrated into a custom theme.
* cus-theme.el (custom-theme--migrate-settings): New var.
(customize-create-theme): Allow editing the `user' theme.
(custom-theme-add-variable, custom-theme-add-var-1)
(custom-theme-add-face, custom-theme-add-face-1): Add a checkbox
to the front of each variable or face widget.
(custom-theme-write): Save theme settings in the correct order.
Optionally, remove saved settings from user customizations.
(custom-theme-write-variables, custom-theme-write-faces): Saved
only the checked widgets.
(customize-themes): Add a link for migrating custom settings.

* custom.el (custom-declare-theme, provide-theme): Use
custom-theme-name-valid-p.
(custom-theme-name-valid-p): Remove checks that are now
unnecessary since themes no longer obey load-path.

* cus-edit.el (custom-variable-value-create): For the simple
style, hide documentation string when hidden.
2010-10-16 20:00:34 -04:00
Chong Yidong
647bc5022f Allow hiding of modified custom widgets.
* cus-edit.el (custom-variable, custom-face): Combine the
:inhibit-magic and :display-style properties into a single
:custom-style property.
(custom-toggle-hide-variable, custom-toggle-hide-face): New
functions.  If hiding an edited value, save it to :shown-value.
(custom-variable-value-create, custom-face-value-create): Use
them.
(custom-magic-reset): Allow magic property to be unset.

* cus-theme.el (custom-theme-add-var-1)
(custom-theme-add-face-1): Use the :custom-style property.

* custom.el: (custom-theme-load-path): Doc fix.
2010-10-16 16:36:20 -04:00
Chong Yidong
782b5e8d92 Move built-in theme directory to etc/.
* custom.el: Custom themes no longer use load-path.
(custom-theme-load-path): New option.  Change built-in theme
directory to etc/.
(custom-enabled-themes): Add custom-theme-load-path dependency.
(custom-theme--load-path): New function.
(load-theme, custom-available-themes): Use it.

* cus-theme.el (describe-theme-1): Use custom-theme--load-path.
(customize-themes): Link to custom-theme-load-path variable.
2010-10-16 14:27:08 -04:00
Chong Yidong
da16abfc7e Bugfixes for `customize-create-theme'.
* cus-theme.el (customize-create-theme): Delete overlays after
erasing.  If given a THEME arg, display only the faces of that arg
instead of custom-theme--listed-faces.
(custom-theme-variable-menu, custom-theme-variable-action)
(custom-variable-reset-theme, custom-theme-delete-variable): Deleted.
(custom-theme-add-variable, custom-theme-add-face): Apply value
from the theme settings, instead of the current value.
(custom-theme-add-var-1, custom-theme-add-face-1): New functions.
(custom-theme-visit-theme): Allow calling outside theme buffers.
(custom-theme-merge-theme): Don't enable the theme when merging.
(custom-theme-write-variables, custom-theme-write-faces): Use the
:shown-value properties to save buffer values, not global ones.
(customize-themes): Display a warning about user customizations.

* cus-edit.el (custom-variable-value-create)
(custom-face-value-create): Obey new special properties
:shown-value and :inhibit-magic.
2010-10-15 20:16:34 -04:00
Chong Yidong
2919746c64 Add some default custom themes.
* cus-theme.el (custom-theme--listed-faces): Add cursor face.
(describe-theme-1): Extract doc from unloaded themes.

* custom.el (custom-theme-name-valid-p): Don't list color-themes.

* themes/tango-theme.el:
* themes/tango-dark-theme.el:
* themes/wheatgrass-theme.el: New files.
2010-10-12 16:06:20 -04:00
Chong Yidong
6b09b5d118 New interface for choosing Custom themes.
* lisp/cus-edit.el (custom--initialize-widget-variables): New function.
(Custom-mode): Use it.

* lisp/cus-face.el (custom-theme-set-faces): Remove dead code.  Obey
custom--inhibit-theme-enable.

* lisp/cus-theme.el (describe-theme, customize-themes)
(custom-theme-save): New commands.
(custom-new-theme-mode-map): Bind C-x C-s.
(custom-new-theme-mode): Use custom--initialize-widget-variables.
(customize-create-theme): New optional arg THEME.
(custom-theme-revert): Use it.
(custom-theme-visit-theme): Remove dead code.
(custom-theme-merge-theme): Use custom-available-themes.
(custom-theme-write): Make interactive.
(custom-theme-write): Use custom-theme-name-valid-p.
(describe-theme-1, custom-theme-choose-revert)
(custom-theme-checkbox-toggle, custom-theme-selections-toggle):
New funs.
(custom-theme-allow-multiple-selections): New option.
(custom-theme-choose-mode): New major mode.

* lisp/custom.el (custom-theme-set-variables): Remove dead code.  Obey
custom--inhibit-theme-enable.
(custom--inhibit-theme-enable): New var.
(provide-theme): Obey it.
(load-theme): Replace load with manual read/eval, in order to
check for correctness.  Use custom-theme-name-valid-p.
(custom-theme-name-valid-p): New function.
(custom-available-themes): Use it.

* lisp/help-mode.el (help-theme-def, help-theme-edit): New buttons.
2010-10-11 23:10:21 -04:00
Chong Yidong
76c16af806 Interface improvements to cus-theme.el.
* cus-edit.el (custom-face-widget-to-spec)
(custom-face-get-current-spec, custom-face-state): New functions.
(custom-face-set, custom-face-mark-to-save)
(custom-face-value-create, custom-face-state-set): Use them.

* cus-theme.el (custom-theme--listed-faces): New var.
(customize-create-theme): Use *Custom Theme* as the buffer name.
Set revert-buffer-function.  Optional arg BUFFER.  Insert all
faces listed in custom-theme--listed-faces.
(custom-theme-revert): New function.
(custom-theme-add-variable, custom-theme-add-face): Insert at the
bottom of the list.
(custom-theme-write): Prompt for theme name if empty.
(custom-theme-write-variables): Use dolist.
(custom-theme-write-faces): Handle hidden (collapsed) widgets.
2010-10-09 17:54:20 -04:00
Chong Yidong
bd78fa1d54 Add "Package:" file headers to denote built-in packages. 2010-08-29 12:17:13 -04:00
Glenn Morris
114f9c9679 Add 2010 to copyright years. 2010-01-13 00:35:10 -08:00
Glenn Morris
ae940284fa Add 2009 to copyright years. 2009-01-05 03:18:22 +00:00
Glenn Morris
eb3fa2cfcf Switch to recommended form of GPLv3 permissions notice. 2008-05-06 08:06:51 +00:00
Stefan Monnier
cbee283dd7 Fix up comment convention on the arch-tag lines. 2008-04-10 14:10:46 +00:00
Glenn Morris
409cc4a3ea Add 2008 to copyright years. 2008-01-07 02:45:14 +00:00
Glenn Morris
b4aa60262c Switch license to GPLv3 or later. 2007-07-25 04:50:21 +00:00
Glenn Morris
d7a0267c8d Add 2007 to copyright years. 2007-01-21 03:53:13 +00:00
Romain Francoise
e1a2960c07 * cus-theme.el (customize-create-theme)
(custom-theme-visit-theme): End `y-or-n-p' prompt with a space.

* filesets.el (filesets-add-buffer): Ditto.

* pcvs.el (cvs-change-cvsroot): Ditto.
2006-08-13 17:05:12 +00:00
Chong Yidong
50be33f562 * cus-theme.el (custom-new-theme-mode-map): Remove mouse-1
binding.
2006-02-15 02:42:10 +00:00
Thien-Thi Nguyen
aaef169dc6 Update years in copyright notice; nfc. 2006-02-06 15:23:23 +00:00
Chong Yidong
f354d94493 Minor fix. 2006-01-13 02:36:49 +00:00
Chong Yidong
c798b7e89b (custom-theme-add-variable): Don't add `custom-enabled-themes'. 2006-01-13 02:35:30 +00:00
Chong Yidong
4c92479f1b * cus-theme.el (custom-theme-add-variable, custom-theme-add-face):
Don't add widget if setting undefined.
2006-01-13 02:30:03 +00:00
Chong Yidong
d0f1e2f8e0 * cus-theme.el: Rewrite the Custom New Theme Mode interface.
(custom-new-theme-mode-map, custom-theme-insert-variable-marker)
	(custom-theme-insert-face-marker, custom-theme-variable-menu)
	(custom-theme-face-menu): New variables.
	(custom-theme-add-variable, custom-theme-variable-action)
	(custom-variable-reset-theme, custom-theme-delete-variable)
	(custom-face-reset-theme, custom-theme-face-action)
	(custom-theme-delete-face, custom-theme-merge-theme)
	(custom-theme-add-face, custom-theme-visit-theme): New functions.
2006-01-02 22:02:11 +00:00
Chong Yidong
85a5eb0eb0 * cus-edit.el (custom-button-mouse): New variable.
(custom-button-mouse): New face.
	(custom-raised-buttons, custom-mode): Use it.

	* cus-theme.el (custom-new-theme-mode): Use custom-button-mouse.
2005-12-31 16:26:01 +00:00
Chong Yidong
6e813c38e9 Remove obsolete comment 2005-12-31 02:05:04 +00:00
Chong Yidong
bdeaa675d1 * cus-theme.el (custom-new-theme-mode-map): New variable. 2005-12-31 02:04:03 +00:00
Chong Yidong
3a6c62dbcb *** empty log message *** 2005-12-31 01:59:02 +00:00
Chong Yidong
8314bdb836 * cus-theme.el (custom-new-theme-mode): Use cus-edit faces. 2005-12-31 01:58:07 +00:00
Chong Yidong
79a0aa1174 Custom Theme bugfixes. 2005-09-05 19:50:02 +00:00
Thien-Thi Nguyen
0d30b33766 Update years in copyright notice; nfc. 2005-08-06 22:13:43 +00:00
Lute Kamstra
086add1519 Update FSF's address. 2005-07-04 23:32:44 +00:00
Luc Teirlinck
2d859fe05c Update copyright years. 2005-07-03 19:02:02 +00:00
Luc Teirlinck
077ad61cf8 (custom-new-theme-mode): New function.
(custom-theme-name, custom-theme-variables, custom-theme-faces)
(custom-theme-description): Add compiler defvars.
(customize-create-theme): Add doc to the "*New Custom Theme*"
buffer.  Use `custom-new-theme-mode'.
(custom-theme-write): Put the created buffer in emacs-lisp-mode
and save it to the `custom-theme-directory'.  Make this the
default directory of the buffer.
2005-07-02 22:53:04 +00:00
David Kastrup
bbeb3055a1 (custom-theme-write-variables): Quote variables
where necessary.
2005-04-17 16:18:45 +00:00
Miles Bader
ab5796a9f9 Add arch taglines 2003-09-01 15:45:59 +00:00
John Paul Wallington
392cb21b2f (customize-create-theme): Call `customize-create-theme' in
Reset widget's notify function.  Blush.
2003-07-05 14:53:30 +00:00
John Paul Wallington
f560e69cee (customize-create-theme): Rename from
`custom-theme-create'.
2003-03-24 06:08:32 +00:00
John Paul Wallington
87e391a986 (custom-theme-create): Add autoload cookie. 2003-03-19 17:17:58 +00:00
Juanma Barranquero
71296446d3 Trailing whitespace deleted. 2003-02-04 11:26:42 +00:00
Richard M. Stallman
3656dac022 New file. 2002-12-23 18:41:50 +00:00