Re: [code] [textadept] How to set "bright" ansi colors as background color in curses mode?

From: Mitchell <m.att.foicica.com>
Date: Tue, 2 Apr 2013 01:57:09 -0400 (EDT)

Hi Pete,

On Mon, 1 Apr 2013, Pete Kazmier wrote:

> I'm trying to figure out how to configure text adept to use a "bright" or
> "bold" ansi color for my background. Is there a way to specify that the
> background color should use the bright/bold version?
>
> I use a terminal based solarized theme that relies on 16 colors. In the
> solarized world, bright black is supposed to be the background color. (And
> yes, I configure my terminal application to display the 16 ansi colors
> using the solarized palette.)
>
> Where in the code should I look if I wanted to investigate further? I tried
> looking through the codebase but didn't see any obvious place where these
> colors are used.

This is tricky. Only 64 color pairs can be defined at once (using the 8
basic colors), e.g. White-Black, Red-Black, Green-Black, etc. So
combinations like White-Black|Bold are not possible, at least for
background colors. (However, a combination like White|Bold-Black is
perfectly legitimate and does not count as a pair due to the current
implementation.) The only way to get around this is, in your terminal
application, to define Black as your "Bright Black" and Black|Bold as your
"Normal Black", which may seem counter intuitive.

On a side note, changing color definitions in Textadept is done in
themes[1]. See themes/term/lexer.lua.

Cheers,
Mitchell

[1]: http://foicica.com/textadept/09_Themes.html#Lexer

-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Tue 02 Apr 2013 - 01:57:09 EDT

This archive was generated by hypermail 2.2.0 : Tue 02 Apr 2013 - 06:30:52 EDT