agnoster / agnoster-zsh-theme

A ZSH theme designed to disclose information contextually, with a powerline aesthetic
3.98k stars 585 forks source link

Support for light backrounds #2

Open jurf opened 8 years ago

jurf commented 8 years ago

Hey, as much as I love your theme, I cannot use it since most of the time I'm in a light terminal, and the legibility with agnoster is really bad there.

The solution is actually really simple, and that is to pull colours from the terminal configuration.

By playing a little with the terminal configuration I got from something like this:

snimka obrazovky z 2015-10-04 11-36-50

To something like this:

snimka obrazovky z 2015-10-04 11-34-18

It's far from perfect, since the same colour options controls both the background of the user part, and the text. If I was to set the text how it should be, then it would look like this:

snimka obrazovky z 2015-10-04 11-40-18

Also, ignore the rendering artefacts, I think I messed something up.

Cellophan commented 7 years ago

A minimalistic solution with #29

capi1O commented 5 years ago

A minimalistic solution with #29

Using this updated version with PRIMARY_FG="white" does not work in some terminals (such as VS code embedded terminal) :

PRIMARY_FG="white" :

Screenshot from 2019-03-22 10-56-13

PRIMARY_FG="black" :

Screenshot from 2019-03-22 10-56-30

One has to use the 256-color code PRIMARY_FG="255" :

Screenshot from 2019-03-22 11-32-52

capi1O commented 5 years ago

There is a WIP here : https://github.com/monkeydri/agnoster-light-zsh-theme for an alternative with light background colors instead.

Screenshot from 2019-03-22 11-21-34

The ideal would be to automatically use light colors based on terminal background color (PRIMARY_FG value is always black (tested in VS Code terminal).

fabb commented 5 years ago

Hm, I could not get the export PRIMARY_FG="255" workaround to work, it does not change anything. I tried putting it in my .zshrc, and also in VSCode "terminal.integrated.env.osx" setting. Any hints on how to use this?

Update: No wonder it did not work. I'm using oh-my-zsh which uses a completely different fork of this theme: https://github.com/robbyrussell/oh-my-zsh/commits/master/themes/agnoster.zsh-theme. There I can set SOLARIZED_THEME="light" to make it work.

istomyang commented 3 years ago

use latest and look:

image

[ you can use a compatiable color design ]

istomyang commented 3 years ago

color can accepts HEX with transparency

image image 【Well, I solve the problem which coming across. 】