From: Juri Linkov <juri@jurta.org>
Cc: emacs-devel@gnu.org
Subject: Re: Diff mode faces
Date: Mon, 20 Jun 2005 07:48:08 +0300 [thread overview]
Message-ID: <87is09n00n.fsf@jurta.org> (raw)
In-Reply-To: <uslzeyv7n.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 19 Jun 2005 21:58:52 +0200")
> First, it calls an obsolete function frame-update-face-colors (it's an
> alias for backward compatibility; let's use the function it is aliased
> to).
Then it would be better to rename it in all C files to not create
Lisp symbols in C for both of them.
> Second, I think doing this unconditionally might not be a good idea:
> wouldn't it clash with what x_set_frame_parameters and
> IT_set_frame_parameters do for their respective displays?
It is called conditionally on non-window and non-dos systems
so it doesn't clash with x_set_frame_parameters or IT_set_frame_parameters.
> Third, please be sure to test this change with various ways one can
> use to set colors on a tty, including these few:
>
> . emacs -fg FOO
> . emacs -fg FOO -bg BAR
> . emacs -bg BAR
> . repeat the above 3 with -rv, and convince yourself that the above
> 4 tests produce expected results
I see there is a bug not caused by my patch:
emacs -q -nw -rv
sets the background mode to light on xterm. But since -rv switches
foreground and background, it should switch the background mode too
from light to dark on xterm.
> . modify the default color with set-background-color and verify that
> it is in effect for new frames created with "C-x 5 b" and the like
For frames with undefined backgrounds it reuses the background mode
specified with set-background-color. Is it right?
> . same as the last one above, but with set-face-background for the
> default face, both with and without the optional frame arg; verify
> that with an arg only the named frame is affected and without an
> arg all frames are affected, including the newly created ones
This works.
> Finally, could you please elaborate on your analysis of this issue; in
> particular, where is this handled on X?
On X this is handled in `if (EQ (param, Qbackground_color))' condition
in update_face_from_frame_parameter(xfaces.c) which is reached from
Fmodify_frame_parameters thru the following function calls:
update_face_from_frame_parameter at xfaces.c:4490
x_set_background_color at xfns.c:911
x_set_frame_parameters at frame.c:2738
Fmodify_frame_parameters at frame.c:2280
Finternal_set_lisp_face_attribute at xfaces.c:4434
But on tty it doesn't go past the function Fmodify_frame_parameters
due to the condition `if (FRAME_WINDOW_P (f))'. The explicit call
to `Qframe_update_face_colors' I added in Fmodify_frame_parameters
is on the else-branch of this condition.
--
Juri Linkov
http://www.jurta.org/emacs/
next prev parent reply other threads:[~2005-06-20 4:48 UTC|newest]
Thread overview: 59+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-17 11:47 Diff mode faces Juri Linkov
2005-06-17 13:11 ` Jason Rumney
2005-06-17 14:28 ` Stefan Monnier
2005-06-18 13:54 ` Juri Linkov
2005-06-17 14:34 ` Eli Zaretskii
2005-06-18 13:57 ` Juri Linkov
2005-06-18 15:27 ` Randal L. Schwartz
2005-06-18 16:46 ` Eli Zaretskii
2005-06-19 13:09 ` Juri Linkov
2005-06-19 19:58 ` Eli Zaretskii
2005-06-20 4:48 ` Juri Linkov [this message]
2005-06-20 20:18 ` Eli Zaretskii
2005-06-21 16:28 ` Background mode (was: Diff mode faces) Juri Linkov
2005-06-27 0:03 ` Background mode Juri Linkov
2005-06-27 16:46 ` Richard M. Stallman
2005-06-27 23:52 ` Juri Linkov
2005-06-28 18:47 ` Richard M. Stallman
2005-06-29 3:55 ` Stefan Monnier
2005-06-29 22:21 ` Miles Bader
2005-06-30 17:45 ` Stefan Monnier
2005-07-01 4:03 ` Richard M. Stallman
2005-07-01 15:01 ` Stefan Monnier
2005-06-27 23:55 ` Juri Linkov
2005-06-19 13:05 ` Diff mode faces Juri Linkov
2005-06-19 17:10 ` Luc Teirlinck
2005-06-19 17:34 ` Randal L. Schwartz
2005-06-27 23:55 ` Juri Linkov
2005-06-28 4:57 ` Miles Bader
2005-07-01 23:59 ` Juri Linkov
2005-07-02 3:37 ` Miles Bader
2005-07-05 19:11 ` Richard M. Stallman
2005-07-06 20:53 ` Juri Linkov
2005-07-07 4:05 ` Miles Bader
2005-07-07 6:03 ` Juri Linkov
2005-07-07 4:42 ` Eli Zaretskii
2005-07-09 20:56 ` Juri Linkov
2005-07-10 3:34 ` Eli Zaretskii
2005-07-11 0:06 ` Juri Linkov
2005-07-11 13:43 ` Stefan Monnier
2005-07-11 19:37 ` Eli Zaretskii
2005-07-11 19:46 ` Stefan Monnier
2005-07-12 3:33 ` Eli Zaretskii
2005-07-12 6:51 ` Juri Linkov
2005-07-16 11:17 ` Eli Zaretskii
2005-06-28 13:10 ` Randal L. Schwartz
2005-06-30 21:30 ` Richard M. Stallman
2005-06-30 21:30 ` Richard M. Stallman
2005-07-01 10:13 ` Eli Zaretskii
2005-07-01 23:59 ` Juri Linkov
2005-07-03 18:56 ` xterm colors (was: Diff mode faces) Gaëtan LEURENT
2005-07-04 5:59 ` Eli Zaretskii
2005-07-04 6:17 ` Richard M. Stallman
2005-07-01 23:59 ` Diff mode faces Juri Linkov
2005-06-20 0:25 ` Miles Bader
2005-06-18 2:21 ` Richard Stallman
2005-06-18 13:54 ` Juri Linkov
2005-06-19 3:51 ` Richard Stallman
2005-06-19 14:05 ` Juri Linkov
2005-06-20 3:50 ` Richard Stallman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87is09n00n.fsf@jurta.org \
--to=juri@jurta.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).