Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default theme should always be readable #1639

Closed
meeuw opened this issue Dec 8, 2023 · 1 comment · Fixed by #1640
Closed

Default theme should always be readable #1639

meeuw opened this issue Dec 8, 2023 · 1 comment · Fixed by #1640
Labels

Comments

@meeuw
Copy link
Contributor

meeuw commented Dec 8, 2023

This issue is related to #33

I've noticed alot doesn't work well on black-on-white terminals.

I know there are light themes available and I know how I can fix this for myself but I think alot should use a default theme which works well in dark and in light mode.

I think this is caused by using default foreground and background colors described as following in the urwid manual:

'default' may be specified as a foreground or background to use a terminal’s default color. For terminals with transparent backgrounds 'default' is the only way to show the transparent background. There is no way to tell what the default colors are, so it is best to use default foregrounds and backgrounds together (not with other colors) to ensure good contrast.

The default theme from alot uses default foregrounds and backgrounds with other colors, probably due to transparent backgrounds.

My suggestion is to make dedicated dark and light themes and make the default theme a bit more boring (limiting to only using default foreground with a default background and make more use of Bold, Underline, Standout "colors".

I'd gladly do create a PR for this, please let me know how you think about this.

I've created a simple test script to test a theme, I will share this as well if you like. It will show you what's barely/un-readable.

light
dark

@lucc
Copy link
Collaborator

lucc commented Dec 8, 2023

I don't have any attachment to the default themes as I use a custom solarized theme. I don't even know which the default theme is. So I would be fine with PRs to fix stuff.

My guess would be that trouble arises if the theme mixes explicit 256-palette colors and predefined 16 colors. This is because the 16 color palette can be configured in the terminal emulator and we can not know how these values contrast with any 256-palette value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants