[GH-ISSUE #97] terminal ansi colors #34

Closed
opened 2026-03-02 23:43:52 +03:00 by kerem · 11 comments
Owner

Originally created by @sewnie on GitHub (Jan 5, 2023).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/97

Originally assigned to: @aome510 on GitHub.

by default, it seems that spotify_player uses it's own colors. for a CLI/TUI application i don't think this is a very good idea. spotify_player should use the terminal's colors - aka ANSI colors.

Originally created by @sewnie on GitHub (Jan 5, 2023). Original GitHub issue: https://github.com/aome510/spotify-player/issues/97 Originally assigned to: @aome510 on GitHub. by default, it seems that spotify_player uses it's own colors. for a CLI/TUI application i don't think this is a very good idea. spotify_player should use the terminal's colors - aka ANSI colors.
kerem 2026-03-02 23:43:52 +03:00
Author
Owner

@aome510 commented on GitHub (Jan 6, 2023):

By the app's own colors, I'll assume that you're referring to the required colors mentioned in theme's palette documentation.

I believe defining the app's own colors this way allows to define more custom themes. I'm not too sure about the approaches other CLI/TUI applications take. Any resources would be helpful.

<!-- gh-comment-id:1373610871 --> @aome510 commented on GitHub (Jan 6, 2023): By the app's own colors, I'll assume that you're referring to the required colors mentioned in [theme's palette documentation](https://github.com/aome510/spotify-player/blob/master/doc/config.md#palette). I believe defining the app's own colors this way allows to define more custom themes. I'm not too sure about the approaches other CLI/TUI applications take. Any resources would be helpful.
Author
Owner

@sewnie commented on GitHub (Jan 7, 2023):

thats not exactly what i meant; for example a program can use the current terminals colors, for example heres a simple printf that will use ANSI to ask the terminal to print the text in red, and then reset the colors:

printf '\033[31mi am in red\n\033[0m'

i believe many programs do this; such as spotify-tui.

<!-- gh-comment-id:1374501874 --> @sewnie commented on GitHub (Jan 7, 2023): thats not exactly what i meant; for example a program can use the current terminals colors, for example heres a simple printf that will use ANSI to ask the terminal to print the text in red, and then reset the colors: ```sh printf '\033[31mi am in red\n\033[0m' ``` i believe many programs do this; such as spotify-tui.
Author
Owner

@aome510 commented on GitHub (Jan 7, 2023):

thats not exactly what i meant; for example a program can use the current terminals colors,

Thanks for the clarification. Does that mean adding a new theme, e.g called "default", that uses the terminal's default colors should work?

<!-- gh-comment-id:1374513577 --> @aome510 commented on GitHub (Jan 7, 2023): > thats not exactly what i meant; for example a program can use the current terminals colors, Thanks for the clarification. Does that mean adding a new theme, e.g called "default", that uses the terminal's default colors should work?
Author
Owner

@sewnie commented on GitHub (Jan 7, 2023):

i guess?

<!-- gh-comment-id:1374516329 --> @sewnie commented on GitHub (Jan 7, 2023): i guess?
Author
Owner

@sewnie commented on GitHub (Jan 9, 2023):

IMO there shouldnt be themes built in into spotify-player. the default and the only default should be ANSI colors and supports themes via configuration; with templates/themes from the project repo.

<!-- gh-comment-id:1375220571 --> @sewnie commented on GitHub (Jan 9, 2023): IMO there shouldnt be themes built in into spotify-player. the default and the only default should be ANSI colors and supports themes via configuration; with templates/themes from the project repo.
Author
Owner

@euglevi commented on GitHub (Jan 16, 2023):

I think this feature is a must in terms of theming. I change my terminal theme quite often, it looks like a downsize having to change the spotify-player theme too.

<!-- gh-comment-id:1383946023 --> @euglevi commented on GitHub (Jan 16, 2023): I think this feature is a must in terms of theming. I change my terminal theme quite often, it looks like a downsize having to change the spotify-player theme too.
Author
Owner

@aome510 commented on GitHub (Jan 17, 2023):

This issue should be resolved by #107, which removed builtin themes and used a single theme based on terminal's ANSI colors.

The default theme change can be considered as a breaking change, so there should a while till this change is released with a new major version.

In the meantime, @wael444, @euglevi, can you guys test the latest build of the master branch to see if it works as expected?
Note that it may require to update the theme's configurations, so please refer to themes documentation for references. Feel free to reopen this issue if encounter any related issues.

<!-- gh-comment-id:1385801268 --> @aome510 commented on GitHub (Jan 17, 2023): This issue should be resolved by #107, which removed builtin themes and used a single theme based on terminal's ANSI colors. The default theme change can be considered as a breaking change, so there should a while till this change is released with a new major version. In the meantime, @wael444, @euglevi, can you guys test the latest build of the `master` branch to see if it works as expected? **Note that** it may require to update the theme's configurations, so please refer to [themes documentation](https://github.com/aome510/spotify-player/blob/master/doc/config.md#themes) for references. Feel free to reopen this issue if encounter any related issues.
Author
Owner

@sewnie commented on GitHub (Jan 17, 2023):

Yes. though the color of the green accent is a little too light, should be the default green color 2 instead of 10

<!-- gh-comment-id:1385825303 --> @sewnie commented on GitHub (Jan 17, 2023): Yes. though the color of the green accent is a little too light, should be the default green color `2` instead of `10`
Author
Owner

@aome510 commented on GitHub (Jan 17, 2023):

Yes. though the color of the green accent is a little too light, should be the default green color 2 instead of 10

Which component are you referring? I think it depends on the terminal's theme. The theme looks fine for me:

Screen Shot 2023-01-17 at 2 01 15 PM

If things don't work, you can always create a new theme based on the "default" theme and update the corresponding component styles.

<!-- gh-comment-id:1385910873 --> @aome510 commented on GitHub (Jan 17, 2023): > Yes. though the color of the green accent is a little too light, should be the default green color `2` instead of `10` Which component are you referring? I think it depends on the terminal's theme. The theme looks fine for me: <img width="1436" alt="Screen Shot 2023-01-17 at 2 01 15 PM" src="https://user-images.githubusercontent.com/40011582/212988040-97276dc1-be07-4a23-a0a0-1ad5eb68784f.png"> If things don't work, you can always create a new theme based on the "default" theme and update the corresponding component styles.
Author
Owner

@sewnie commented on GitHub (Jan 17, 2023):

image

<!-- gh-comment-id:1385918637 --> @sewnie commented on GitHub (Jan 17, 2023): ![image](https://user-images.githubusercontent.com/47404953/212989495-79730647-2e13-4d7f-9c90-bb166827353e.png)
Author
Owner

@euglevi commented on GitHub (Jan 17, 2023):

It seems to me it works well. Thank you! I have tried with a few themes. I will try more in the next days, but I have no reason to think I will experience any issues.

<!-- gh-comment-id:1386073278 --> @euglevi commented on GitHub (Jan 17, 2023): It seems to me it works well. Thank you! I have tried with a few themes. I will try more in the next days, but I have no reason to think I will experience any issues.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-player#34
No description provided.