diff options
| author | Jan D | 2010-08-11 20:28:10 +0200 |
|---|---|---|
| committer | Jan D | 2010-08-11 20:28:10 +0200 |
| commit | 3a46642b081c504b6e25c65d81999fcc0dff5fb2 (patch) | |
| tree | a7f42c1836467e6c8539cef167977a48c182ad97 /lisp | |
| parent | 42ca463309fdb17f04a72dad92696312bf242328 (diff) | |
| download | emacs-3a46642b081c504b6e25c65d81999fcc0dff5fb2.tar.gz emacs-3a46642b081c504b6e25c65d81999fcc0dff5fb2.zip | |
Take colors for region face (selected text) from the Gtk+ theme.
* lisp/dynamic-setting.el (dynamic-setting-handle-config-changed-event):
Handle theme-name change.
* lisp/faces.el (region): Add type gtk that uses gtk colors.
* src/gtkutil.c (xg_check_special_colors, style_changed_cb): New functions.
(xg_create_frame_widgets): Connect theme name changes to
style_changed_cb.
* src/gtkutil.h (xg_check_special_colors): Declare.
* src/xfns.c (x_defined_color): If USE_GTK, call xg_check_special_colors
first.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog | 7 | ||||
| -rw-r--r-- | lisp/dynamic-setting.el | 5 | ||||
| -rw-r--r-- | lisp/faces.el | 3 |
3 files changed, 15 insertions, 0 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6f15ae942fc..763ffd0dd0f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2010-08-11 Jan Djärv <jan.h.d@swipnet.se> | ||
| 2 | |||
| 3 | * faces.el (region): Add type gtk that uses gtk colors. | ||
| 4 | |||
| 5 | * dynamic-setting.el (dynamic-setting-handle-config-changed-event): | ||
| 6 | Handle theme-name change. | ||
| 7 | |||
| 1 | 2010-08-10 Michael R. Mauger <mmaug@yahoo.com> | 8 | 2010-08-10 Michael R. Mauger <mmaug@yahoo.com> |
| 2 | 9 | ||
| 3 | * progmodes/sql.el: Version 2.5 | 10 | * progmodes/sql.el: Version 2.5 |
diff --git a/lisp/dynamic-setting.el b/lisp/dynamic-setting.el index f61a0078e17..790aaf7170e 100644 --- a/lisp/dynamic-setting.el +++ b/lisp/dynamic-setting.el | |||
| @@ -96,6 +96,11 @@ Changes can be | |||
| 96 | ((eq type 'font-render) | 96 | ((eq type 'font-render) |
| 97 | (font-setting-change-default-font display-name nil)) | 97 | (font-setting-change-default-font display-name nil)) |
| 98 | 98 | ||
| 99 | ;; This is a bit heavy, ideally we would just clear faces | ||
| 100 | ;; on the affected display, and perhaps only the relevant | ||
| 101 | ;; faces. Oh well. | ||
| 102 | ((eq type 'theme-name) (clear-face-cache)) | ||
| 103 | |||
| 99 | ((eq type 'tool-bar-style) (force-mode-line-update t))))) | 104 | ((eq type 'tool-bar-style) (force-mode-line-update t))))) |
| 100 | 105 | ||
| 101 | (define-key special-event-map [config-changed-event] | 106 | (define-key special-event-map [config-changed-event] |
diff --git a/lisp/faces.el b/lisp/faces.el index b7c238e14f3..d8b6f20035c 100644 --- a/lisp/faces.el +++ b/lisp/faces.el | |||
| @@ -2281,6 +2281,9 @@ terminal type to a different value." | |||
| 2281 | (defface region | 2281 | (defface region |
| 2282 | '((((class color) (min-colors 88) (background dark)) | 2282 | '((((class color) (min-colors 88) (background dark)) |
| 2283 | :background "blue3") | 2283 | :background "blue3") |
| 2284 | (((class color) (min-colors 88) (background light) (type gtk)) | ||
| 2285 | :foreground "gtk_selection_fg_color" | ||
| 2286 | :background "gtk_selection_bg_color") | ||
| 2284 | (((class color) (min-colors 88) (background light) (type ns)) | 2287 | (((class color) (min-colors 88) (background light) (type ns)) |
| 2285 | :background "ns_selection_color") | 2288 | :background "ns_selection_color") |
| 2286 | (((class color) (min-colors 88) (background light)) | 2289 | (((class color) (min-colors 88) (background light)) |