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

User Themes #22

Open
ceuk opened this issue May 31, 2021 · 1 comment
Open

User Themes #22

ceuk opened this issue May 31, 2021 · 1 comment
Labels

Comments

@ceuk
Copy link
Owner

ceuk commented May 31, 2021

Using the existing patterns in config.py and colors.py implement a new config section: "theme" that allows users to define the terminal color using the ncurses constant names. These config values should be plugged into colors.py (replacing the hardcoded values) if they are present.

e.g.

[theme]
progress_bar_fg = "COLOR_GREEN"
progress_bar_bg = "COLOR_BLACK"
border_fg = "COLOR_WHITE"
border_bg = "COLOR_BLACK"
border_active_fg = "COLOR_YELLOW"
# ...etc

We will also need to define a set of themeable colors as currently the colors file and use thereof isn't very organised (Basically, we need to make sure that we have a pair defined for each semantic UI element: e.g. progress bar etc - and that we update the pairs being used by these elements accordingly)

@octoshrimpy
Copy link
Contributor

Hey! glad you're still around! This project is awesome and your code has been wonderful to work with. Honestly, I was expecting the usual "other dev's code is hard to read" but your python/curses is legitimately fun to read and tweak.

I've implemented the theme engine, as well as transparency (if the terminal has it) and x_2256_colors on top. see
https://github.com/octoshrimpy/spotui/commits/master and
https://github.com/octoshrimpy/spotui/commits/master

I'm working on setting up a config updater for those who are already using spotui so that the update to the new config with more values goes by smoothly.

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