[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: What is the best way to handle LS_COLORS ?
From: |
Nicholas Marriott |
Subject: |
Re: What is the best way to handle LS_COLORS ? |
Date: |
Mon, 30 Mar 2020 09:11:33 +0100 |
Hi
I don't know of many applications that use palette setting so I'd say it
is a very safe assumption. And now RGB colour has made it pretty much
obsolete.
tmux has a table of the xterm palette in colour_256toRGB in this file
that you may find useful, as well as a function to do the reverse
(colour_find_rgb): https://github.com/tmux/tmux/blob/master/colour.c
On Sat, Mar 28, 2020 at 04:29:09PM +1100, Tim Allen wrote:
> On Fri, Mar 27, 2020 at 10:35:35PM -0500, Bryan Christ wrote:
> > I read both of your replies. Thank you. Helpful as always! So just
> > to clarify... it's a pretty safe assumption that the palette is the
> > default xterm-color256 palette? Would that be nestled in the xterm
> > source code by chance?
>
> It probably is, but a web search for "xterm 256 palette" will dig up the
> goods. For example:
>
> https://jonasjacek.github.io/colors/
> https://github.com/sindresorhus/xterm-colors
>
> It's pretty simple to generate algorithmically:
>
> - 8 standard colours (dim)
> - 8 standard colours (bright)
> - 216 colours forming a 6×6×6 colour cube, where the value of each
> channel comes from the set (0x00, 0x5f, 0x87, 0xaf, 0xd7, 0xff).
> - 24 colours, the middle steps of a 26-step gradient from black to
> white (absolute black and absolute white can be found in the colour
> cube, they don't need to be in the greyscale gradient too)
>
> Tim.
>
- What is the best way to handle LS_COLORS ?, Bryan Christ, 2020/03/27
- Re: What is the best way to handle LS_COLORS ?, Thomas Dickey, 2020/03/27
- Re: What is the best way to handle LS_COLORS ?, Bryan Christ, 2020/03/27
- Re: What is the best way to handle LS_COLORS ?, Tim Allen, 2020/03/28
- Re: What is the best way to handle LS_COLORS ?,
Nicholas Marriott <=
- Re: What is the best way to handle LS_COLORS ?, Bryan Christ, 2020/03/30
- Re: What is the best way to handle LS_COLORS ?, Bryan Christ, 2020/03/30
- Re: What is the best way to handle LS_COLORS ?, Thomas Dickey, 2020/03/31
- Re: What is the best way to handle LS_COLORS ?, Bryan Christ, 2020/03/31
Re: What is the best way to handle LS_COLORS ?, Tim Allen, 2020/03/27