Ability to change text colour using config.text_color #2790
Replies: 4 comments
-
I see the need - it would be great to set the color of a type of Mobject exactly once in the code or stylesheet configuration. However, the dev team has decided that config is not the right place for background_color and we want to deprecate it soon. There isn't yet a solidified plan for a "stylesheet" type interface, though I agree I'd like one. Last time this came up on Discord, the two kinds of workarounds were subclassing Tex with different defaults or defining a partial function that modifies kwargs if a value is unset. If you want to take on a larger project, feel free to suggest some alternatives and start developing one of them. I'd be happy to have stylesheets in Manim. |
Beta Was this translation helpful? Give feedback.
-
One positive thing about setting so many attributes as keyword arguments is that you can easily make your own version of a mobject constructor with different defaults:
and then use myText instead of Text in you scene. |
Beta Was this translation helpful? Give feedback.
-
One possibly better solution might be to add a new config property manim/manim/mobject/mobject.py Line 67 in dbb6212 |
Beta Was this translation helpful? Give feedback.
-
I think I'm a fan of the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Description of proposed feature
To change the background colour,
config.background_color=COLOUR
can be used. Adding support to change the text colour would be convenient when changing the background colour, and the default white text doesn't show well.How can the new feature be used?
Maybe a command like
config.text_color=COLOUR
Additional comments
Beta Was this translation helpful? Give feedback.
All reactions