Conversation
|
I love this PR and hope to merge it; I'd like to test it out some. |
|
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? |
|
Sorry, it's been a while. I plan to continue this. Currently working on coloring the remaining art with durdraw. |
43b2d75 to
cdc5f70
Compare
|
I've added all the remaining colored art for the plants. There's also a debug mode that allows cycling through art in botany for debugging purposes (set "self.debug_art = True" in menu_screen.py). I'll try to attach a demo video of the art in dark mode and light mode. I did notice that plants have a "color" descriptor (in plant.py), and the color might not match that of the art displayed. Is that going to be a problem? I think it would also be nice for people to be able to toggle this on and off (not sure where the setting would be saved though). Currently, the program just uses curses.has_colors(). |
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 some escape codes for setting foreground color are supported. Unsupported escape codes reset colors to normal. Add ANSI-colored ASCII art for all plants to "art" directory. Most of the art was colored using durdraw. Add art/test.ansi for debugging purposes. Also add a debugging mode for previewing art that can be enabled by setting the "debug_art" flag to True in menu_screen.py. It adds a "DEBUG" menu option that cycles through all art files.
|
Added demo videos of debug mode to the top comment, with all the colored art. |
Not sure what to do about this, thinking maybe I could have some designated color just be replaced by whatever color is in the color descriptor. e.g. green. Or the "color" could just sort of be a non-literal descriptor, and we could just ignore this. Or we could have a map for each plant where it shows where the color should be overridden by this color descriptor. What do people think?
I guess this could be saved in the plant.json? And there could be an extra preferences menu, where this could be toggled. I don't want to make botany more complicated than it has to be though; a big part of its charm is its simplicity. Does anyone have suggestions? |
A good start for allowing the user to control color output would be to respect |
|
Thanks Noelle, I'll get to it soon!
…On Thu, Jan 1, 2026 at 03:00 Noelle Leigh ***@***.***> wrote:
*noelleleigh* left a comment (jifunks/botany#44)
<#44 (comment)>
I think it would also be nice for people to be able to toggle this on and
off (not sure where the setting would be saved though). Currently, the
program just uses curses.has_colors().
I guess this could be saved in the plant.json? And there could be an extra
preferences menu, where this could be toggled. I don't want to make botany
more complicated than it has to be though; a big part of its charm is its
simplicity.
A good start for allowing the user to control color output would be to
respect NO_COLOR <https://no-color.org/> and FORCE_COLOR
<https://force-color.org/> as described in the Python documentation
<https://docs.python.org/3/using/cmdline.html#controlling-color>.
—
Reply to this email directly, view it on GitHub
<#44 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AD6ELKAAWYE55RTOSBDRFS34ET46PAVCNFSM6AAAAACMCHI4RCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTOMBTGU2DGNZZGU>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
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 some escape codes for setting foreground color are supported.
Unsupported escape codes reset colors to normal.
Add ANSI-colored ASCII art for all plants to "art" directory.
Most of the art was colored using durdraw.
Add art/test.ansi for debugging purposes.
Also add a debugging mode for previewing art that can be enabled by
setting the "debug_art" flag to True in menu_screen.py. It adds a
"DEBUG" menu option that cycles through all art files.
(edited with updated commit message above)
Screenshots:
Demo videos of debug mode:
light.mp4
dark.mp4