diff options
| author | Eli Zaretskii | 2000-10-28 17:07:51 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2000-10-28 17:07:51 +0000 |
| commit | 70de9f065a0515b43137df5a62a9d4b151c53bdf (patch) | |
| tree | 9934974a65247a78ddef5273b976aec66a59c069 /src | |
| parent | a00b77f9ade3ed1d4e6cbd6b48fe71d18bd1c6fa (diff) | |
| download | emacs-70de9f065a0515b43137df5a62a9d4b151c53bdf.tar.gz emacs-70de9f065a0515b43137df5a62a9d4b151c53bdf.zip | |
(Fframe_parameters): Fix the change from 2000-10-16:
don't override the colors in frame's param_alist, unless they are
unspecified.
Diffstat (limited to 'src')
| -rw-r--r-- | src/frame.c | 34 |
1 files changed, 22 insertions, 12 deletions
diff --git a/src/frame.c b/src/frame.c index d495846fcdf..644e7a5347a 100644 --- a/src/frame.c +++ b/src/frame.c | |||
| @@ -2059,21 +2059,31 @@ If FRAME is omitted, return information on the currently selected frame.") | |||
| 2059 | unspecified and reversed, take the frame's background pixel | 2059 | unspecified and reversed, take the frame's background pixel |
| 2060 | for foreground and vice versa. */ | 2060 | for foreground and vice versa. */ |
| 2061 | elt = Fassq (Qforeground_color, alist); | 2061 | elt = Fassq (Qforeground_color, alist); |
| 2062 | if (!NILP (elt) && CONSP (elt) | 2062 | if (!NILP (elt) && CONSP (elt) && STRINGP (XCDR (elt))) |
| 2063 | && STRINGP (XCDR (elt)) | 2063 | { |
| 2064 | && strncmp (XSTRING (XCDR (elt))->data, | 2064 | if (strncmp (XSTRING (XCDR (elt))->data, |
| 2065 | unspecified_bg, | 2065 | unspecified_bg, |
| 2066 | XSTRING (XCDR (elt))->size) == 0) | 2066 | XSTRING (XCDR (elt))->size) == 0) |
| 2067 | store_in_alist (&alist, Qforeground_color, tty_color_name (f, bg)); | 2067 | store_in_alist (&alist, Qforeground_color, tty_color_name (f, bg)); |
| 2068 | else if (strncmp (XSTRING (XCDR (elt))->data, | ||
| 2069 | unspecified_fg, | ||
| 2070 | XSTRING (XCDR (elt))->size) == 0) | ||
| 2071 | store_in_alist (&alist, Qforeground_color, tty_color_name (f, fg)); | ||
| 2072 | } | ||
| 2068 | else | 2073 | else |
| 2069 | store_in_alist (&alist, Qforeground_color, tty_color_name (f, fg)); | 2074 | store_in_alist (&alist, Qforeground_color, tty_color_name (f, fg)); |
| 2070 | elt = Fassq (Qbackground_color, alist); | 2075 | elt = Fassq (Qbackground_color, alist); |
| 2071 | if (!NILP (elt) && CONSP (elt) | 2076 | if (!NILP (elt) && CONSP (elt) && STRINGP (XCDR (elt))) |
| 2072 | && STRINGP (XCDR (elt)) | 2077 | { |
| 2073 | && strncmp (XSTRING (XCDR (elt))->data, | 2078 | if (strncmp (XSTRING (XCDR (elt))->data, |
| 2074 | unspecified_fg, | 2079 | unspecified_fg, |
| 2075 | XSTRING (XCDR (elt))->size) == 0) | 2080 | XSTRING (XCDR (elt))->size) == 0) |
| 2076 | store_in_alist (&alist, Qbackground_color, tty_color_name (f, fg)); | 2081 | store_in_alist (&alist, Qbackground_color, tty_color_name (f, fg)); |
| 2082 | else if (strncmp (XSTRING (XCDR (elt))->data, | ||
| 2083 | unspecified_bg, | ||
| 2084 | XSTRING (XCDR (elt))->size) == 0) | ||
| 2085 | store_in_alist (&alist, Qbackground_color, tty_color_name (f, bg)); | ||
| 2086 | } | ||
| 2077 | else | 2087 | else |
| 2078 | store_in_alist (&alist, Qbackground_color, tty_color_name (f, bg)); | 2088 | store_in_alist (&alist, Qbackground_color, tty_color_name (f, bg)); |
| 2079 | store_in_alist (&alist, intern ("font"), | 2089 | store_in_alist (&alist, intern ("font"), |