[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Setting term-default-fg-color/term-default-bg-color has no effect
From: |
Dan Nicolaescu |
Subject: |
Re: Setting term-default-fg-color/term-default-bg-color has no effect |
Date: |
Tue, 31 Jul 2007 21:10:39 -0700 |
Peter Povinec <pp_publiclists@yahoo.com> writes:
> > Can you please describe exactly what are you doing and how? How did
> > you test your patch?
>
> The basic idea is the same as it was in Emacs 21. Take the user preferences
> in terms of fg/bg colors as stored in term-default-fg-color and
> term-default-bg-color and apply them consistently every time
term-current-face
> is set. This is done for the initial value of term-current-face, when the
> terminal is reset in term-reset-terminal, and when the escape sequences
> setting the default fg/bg colors are interpreted in
term-handle-color-array.
> Note that this was partially done already in term-handle-color-array, e.g.
in
> the case of setting reverse+invisible.
>
> For the testing, I've tested with my color customizations, including colored
> terminal prompt in csh. I verified the reverse video logic by running 'top'
> and 'emacs -nw' inside an ansi-term, both with my customizations, and plain
> emacs. Customizations to term-default-fg-color or term-default-bg-color
while
> one or more term sessions are running take effect as expected, e.g. by
running
> 'reset'.
I tested your changes by setting term-default-fg-color to blue and
term-default-bg-color to red on an emacs run with -Q and comparing
with running various curses applications in M-x term and "xterm -fg
blue -bg red". The results are not the same.
The problem is that the screen is updated in a lot of places in
term.el not only term-handle-colors-array. So this could not have
worked correctly in emacs 21 either.
Given that AFAIK nothing else in emacs changes the default foreground
and background for a buffer, it's kind of hard to find a convincing
argument that such a feature is needed for term.el. It can probably be
done with some effort, but is it worth the added complexity? Not
sure...
- Re: Setting term-default-fg-color/term-default-bg-color has no effect,
Dan Nicolaescu <=