Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Terminal theme tool – a workaround for lack of 24-bit color in Zsh?



This is an update to the first post. I've done a research on iTerm and
it turned out it can change all the 256 colors and also terminal's
background and foreground color. So the following isn't true:

On Mon, 15 Oct 2018 at 17:28, Sebastian Gniazdowski
<sgniazdowski@xxxxxxxxx> wrote:
> Hello!
> There are 2 escape sequences, ESC]4;n;#rrggbb\a and ESC]Pnrrggbb, that
> allow to change terminal's current palette. First works on most
> OpenSource / Linux terminals and supports 256 colors, second one on OS
> X iTerm, supporting first 16 colors only.

The new iTerm2 sequence is:

    \e]4; index ;rgb: red / green / blue \a

An example that changes 1st color (index=1), i.e. the red (try also 2
for the green, for example).

    echo -en '\e]4;1;rgb:aa/ff/00\a'

More details are in the iTerm2 gitlab's issue:

https://gitlab.com/gnachman/iterm2/issues/7221


-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org



Messages sorted by: Reverse Date, Date, Thread, Author