Comments (4)
alternatively you can just set the color for the object afterwards:
class bullets(Scene):
def construct(self):
t3 = BulletedList(
"Low Signal-to-Noise Ratio (SNR)",
"Low contrast",
"Low resolution",
color=BLUE,
fill_color=BLUE,
stroke_color=BLUE
).set_color(RED)
self.add(t3)
from manim.
The reason for this behavior is that Manim does not typeset the bulleted list as an itemize
in LaTeX, but rather makes individual rows out of the items and places separately generated dots in front of each line - where the dot itself is typeset without passing any **kwargs
on to the MathTex
object:
line_separated_items = [s + "\\\\" for s in items]
super().__init__(
*line_separated_items, tex_environment=tex_environment, **kwargs
)
for part in self:
dot = MathTex("\\cdot").scale(self.dot_scale_factor)
dot.next_to(part[0], LEFT, SMALL_BUFF)
part.add_to_back(dot)
self.arrange(DOWN, aligned_edge=LEFT, buff=self.buff)
from manim.
Gotcha, the workaround you suggested is so much cleaner, thank you!!
from manim.
For now I have worked around the issue as follows:
tex_template = TexTemplate()
tex_template.add_to_preamble(r"\usepackage{enumitem,xcolor}")
t3 = Tex(r"\begin{itemize}[label=\textcolor{black}{\textbullet}] \item Low Signal-to-Noise Ratio (SNR)"
r"\item Low contrast \item Low resolution"
r"\end{itemize}",
color=BLACK,
tex_template=tex_template)
from manim.
Related Issues (20)
- License situation of library should be mentioned on landing page of documentation
- Suffix of generated video file is incorrect when passing `--format`
- I can't render my animations
- DecimalNumber changes height unexpectedly
- ConvertToOpengl does not always work
- TracedPath stroke_opacity acting weird, with working version for comparison HOT 1
- 'RuntimeWarning: divide by zero encountered in scalar divide' causing Axes rendering failure for axis values 0 HOT 3
- How do I set the background color of code in Manim? HOT 1
- SurroundingRectangle supports *mobjects
- Improvement on the python-dev version
- Trying to make a vector field, I got a message telling me to make a bug report HOT 1
- Axes don't work correctly HOT 3
- Tex-Mobject width and font_size arguments affect eachother HOT 4
- Updaters not refreshing between animations HOT 1
- Axes and the unit_size HOT 3
- Uhhh... help? HOT 1
- Manim HOT 1
- Manim render command leads to "cannot import name 'DEFAULT_DASH_LENGTH' from 'manim.mobject.geometry'" error HOT 1
- Color palette format and builder
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from manim.