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

add color to botany #44

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

joyalicegu
Copy link

Add example ANSI-colored ASCII art to "art" directory

Add ansi_render() to menu_screen.py to render ANSI-colored ASCII art

Fall back on non-colored art if no colored art exists

Only single escape codes for setting foreground color are supported.
Escape sequences with multiple codes (e.g. "ESC[1;33m") are unsupported.
Unsupported escape codes reset colors to normal.

Screenshots:
screenshot-botany-dark
screenshot-botany-light
screenshot-botany-jackolantern
screenshot-botany-rip
screenshot-botany-seed
screenshot-botany-seedling

Add example ANSI-colored ASCII art to "art" directory

Add ansi_render() to menu_screen.py to render ANSI-colored ASCII art

Fall back on non-colored art if no colored art exists

Only single escape codes for setting foreground color are supported.
Escape sequences with multiple codes (e.g. "ESC[1;33m") are unsupported.
Unsupported escape codes reset colors to normal.
@vilmibm
Copy link
Collaborator

vilmibm commented Apr 4, 2024

I love this PR and hope to merge it; I'd like to test it out some.

@joyalicegu
Copy link
Author

This is really old, and I didn't finish coloring all of the existing ascii art. I will probably do some more work on it over the next couple of weeks (I should have an update to this PR ready by May).

I would like to test it more, too. I want to make sure it doesn't behave unexpectedly in different terminals / screen sizes / etc. Since this is just using the curses library, I don't expect anything weird to happen, but you never know. Maybe some other townies can try it out?

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

Successfully merging this pull request may close these issues.

2 participants