Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] Change color of 'highlight' indicator in inbox view?
@ 2009-09-06  9:42 Richard Sandilands
  2009-09-06 13:07 ` William Morgan
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Sandilands @ 2009-09-06  9:42 UTC (permalink / raw)


Hi there

Am just playing with colors.yaml and was looking to change the colors of the
highlight line that indicates a selected thread in inbox view.

Is there a setting for this element?

-- 
Richard Sandilands


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [sup-talk] Change color of 'highlight' indicator in inbox view?
  2009-09-06  9:42 [sup-talk] Change color of 'highlight' indicator in inbox view? Richard Sandilands
@ 2009-09-06 13:07 ` William Morgan
  2009-09-08 20:50   ` Carl Worth
  0 siblings, 1 reply; 4+ messages in thread
From: William Morgan @ 2009-09-06 13:07 UTC (permalink / raw)


Reformatted excerpts from Richard Sandilands's message of 2009-09-06:
> Am just playing with colors.yaml and was looking to change the colors
> of the highlight line that indicates a selected thread in inbox view.
> 
> Is there a setting for this element?

Currently the highlight color is generated programmatically, so there's
no setting in colors.yaml. You can edit colormap.rb#highlight_for (circa
line 82) if you want.

Ideas on how to move this configuration to colors.yaml (or some other
configuration mechanism) welcome.
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [sup-talk] Change color of 'highlight' indicator in inbox view?
  2009-09-06 13:07 ` William Morgan
@ 2009-09-08 20:50   ` Carl Worth
  2009-09-09 14:30     ` William Morgan
  0 siblings, 1 reply; 4+ messages in thread
From: Carl Worth @ 2009-09-08 20:50 UTC (permalink / raw)


Excerpts from William Morgan's message of Sun Sep 06 06:07:48 -0700 2009:
> Reformatted excerpts from Richard Sandilands's message of 2009-09-06:
> > Is there a setting for this element?
> 
> Currently the highlight color is generated programmatically, so there's
> no setting in colors.yaml. You can edit colormap.rb#highlight_for (circa
> line 82) if you want.

Thanks for pointing this out. The highlight color has been one of the
last color annoyances for me, but I hadn't done the effort to find
this in the code yet.

> Ideas on how to move this configuration to colors.yaml (or some other
> configuration mechanism) welcome.

What I think I would really like is a mode where none of the
foreground colors/attributes change at all, (it seems distracting to
have the text invert while trying to process mail quickly).

Instead, I'd like the highlight to be a subtle change in the
background color, (but still light or dark like the background so that
the foreground colors are all still readable).

I poked around at this, and my terminal does have two variants of each
of 8 colors available (one brighter than the other), so it seemed like
I should be able to use one as the normal background and one as the
highlight background. But on looking closer, it appears that the
terminal color support here is to name the 8 different colors and to
select the variant for each with the bold attribute. So if I'm
understanding that correctly, that's 16 colors available for the
foreground, but only 8 for the background. That's frustrating.

Such a limited color selection is almost unimaginable with hardware
capability today. (I do see references to "xterm-256color"[*] terminal
definitions. Could sup start depending on things like that? Are there
users of sup using the Linux console or so, and does that support
256-color escape codes?).

Anyway, I gave up for now and decided not to use color for highlight
at all. Instead, I did:

  def highlight_for fg, bg, attrs
    [fg, bg, attrs + [Curses::A_UNDERLINE]]

I should figure out how to make the underline vs. color choice for
highlighting to be a configuration option in order to propose this as
a proper patch. But I still would prefer a subtle change in the
background color instead of an underline if anyone can figure out how
to give me that[**].

-Car

[*] And even 256 colors is antiquated. Anything requiring a fixed
palette is very constraining on an application author today.

[**] Of course, one way is to go away from a curses-based
interface. That might very well make sense in the future where sup is
implemented as a protocol and we can easily have multiple clients. For
me, a graphical client won't be of any interest unless it allows full
keyboard control exactly as sup does, but if it does that and renders
text as well as my terminal, I could imagine using it.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [sup-talk] Change color of 'highlight' indicator in inbox view?
  2009-09-08 20:50   ` Carl Worth
@ 2009-09-09 14:30     ` William Morgan
  0 siblings, 0 replies; 4+ messages in thread
From: William Morgan @ 2009-09-09 14:30 UTC (permalink / raw)


Reformatted excerpts from Carl Worth's message of 2009-09-08:
> So if I'm understanding that correctly, that's 16 colors available for
> the foreground, but only 8 for the background. That's frustrating.

Yup. Curses is happy to welcome you to 1982!

> Such a limited color selection is almost unimaginable with hardware
> capability today.

FWIW, most terminal emulators allow you to tweak the actual colors that
the curses colors refer to. So you have some flexibility about the
actual colors, just a small palette.

> (I do see references to "xterm-256color"[*] terminal definitions.
> Could sup start depending on things like that? Are there users of sup
> using the Linux console or so, and does that support 256-color escape
> codes?).

I'm not sure. I suspect no, but I would be interested in learning more.

> I should figure out how to make the underline vs. color choice for
> highlighting to be a configuration option in order to propose this as
> a proper patch.

I think the only patch I would accept at this point for tweaking the
highlight would be a new hook.

> Of course, one way is to go away from a curses-based interface. That
> might very well make sense in the future where sup is implemented as a
> protocol and we can easily have multiple clients.

That is one of the goals.

> For me, a graphical client won't be of any interest unless it allows
> full keyboard control exactly as sup does, but if it does that and
> renders text as well as my terminal, I could imagine using it.

I agree completely.
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-09-09 14:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-06  9:42 [sup-talk] Change color of 'highlight' indicator in inbox view? Richard Sandilands
2009-09-06 13:07 ` William Morgan
2009-09-08 20:50   ` Carl Worth
2009-09-09 14:30     ` William Morgan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox