<<< Date Index >>>     <<< Thread Index >>>

Re: indexcolor + color index = interesting highlighting



Hi Christian,

Thanks for your reply.
Please see my comments below.

On Tue, Apr 26, 2005 at 09:13 PM PDT, Christian Aichinger wrote:
CA> On Wed, Apr 13, 2005 at 04:52:06PM -0700, Mun Johl wrote:
CA> > Hi,
CA> > 
CA> > Particulars:
CA> >    Solaris 8
CA> >    Mutt 1.5.9 (configured with curses: --with-curses)
CA> >    Rxvt 2.7.10
CA> > 
CA> [...]
CA> > Anyway, if I use indexcolor to highlight the author field using a
CA> > non-bright color, it works fine unless I use a "color index" command to
CA> > change the highlighting of the index line to a bright color.  In that
CA> > case, the index_author highlighting is changed to the bright variant as
CA> > well.  That caught me by surprise.
CA> > 
CA> > On the other hand, if I highlight the author field using a bright
CA> > color, that color sticks no matter what the "color index" tries to do.
CA> > 
CA> > On a side note, it seems indexcolor takes precedence over "color index";
CA> > I'm not sure if that is expected or not.
CA> 
CA> This is all expected. It comes from the fact that I use attron() to
CA> set the color of the single fields, instead of attrset(). The reason
CA> I did this was to get the behavior as seen on
CA> <URL:http://greek0.net/~greek0/mutt/mutt-indexcolor-1.png>.
CA> 
CA> Notice that unread lines are bright throughout. This is accomplished
CA> by having something like "color index brightdefault default ~N" in
CA> my muttrc.
CA> 
CA> If indexcolor used attrset, the custom colored fields wouldn't be
CA> bright. You couldn't even fix this by adding ~N in more places,
CA> since not all index_* color options accept a pattern.
CA> 
CA> So it's a feature, not a bug :-).
CA> 
CA> Is this problematic for you? Perhaps we can find a solution if you
CA> tell me more about what you want to achieve.

I see, thanks for the explanation of your desired behavior.  I
misunderstood the functionality I guess.  Here's a description of how I
was planning on using this feature.

First of all, I do like how you've used the feature as shown in
mutt-indexcolor-1.png; however, I have assigned 16 unique colors to
my terminal emulator rather than using 8 normal and 8 bright variants.
I need as many colors as I can get.

Perhaps the main issue for me is that when I use a "color index" command
to over-ride the current coloring of the index line, it doesn't
over-ride the indexcolor coloring.  I was expecting the "color index"
command to take precedence regardless of whether or not indexcolor  was
highlighting a field with a normal or bright color.

Let me know if you need any additional information.  I don't expect you
to change the behavior of your patch, Christian.  But I do appreciate
your willingness to evaluate my usage requirements.

-- 
Mun