mirror of
https://github.com/3b1b/manim.git
synced 2025-09-19 04:41:56 +00:00
Add default border width to StringMobject
This commit is contained in:
parent
17cd597904
commit
246a010799
1 changed files with 5 additions and 6 deletions
|
@ -47,6 +47,7 @@ class StringMobject(SVGMobject, ABC):
|
||||||
self,
|
self,
|
||||||
string: str,
|
string: str,
|
||||||
fill_color: ManimColor = WHITE,
|
fill_color: ManimColor = WHITE,
|
||||||
|
fill_border_width: float = 0.5,
|
||||||
stroke_color: ManimColor = WHITE,
|
stroke_color: ManimColor = WHITE,
|
||||||
stroke_width: float = 0,
|
stroke_width: float = 0,
|
||||||
base_color: ManimColor = WHITE,
|
base_color: ManimColor = WHITE,
|
||||||
|
@ -65,12 +66,10 @@ class StringMobject(SVGMobject, ABC):
|
||||||
self.use_labelled_svg = use_labelled_svg
|
self.use_labelled_svg = use_labelled_svg
|
||||||
|
|
||||||
self.parse()
|
self.parse()
|
||||||
super().__init__(
|
super().__init__(**kwargs)
|
||||||
stroke_color=stroke_color,
|
self.set_stroke(stroke_color, stroke_width)
|
||||||
fill_color=fill_color,
|
self.set_fill(fill_color, border_width=fill_border_width)
|
||||||
stroke_width=stroke_width,
|
self.note_changed_stroke()
|
||||||
**kwargs
|
|
||||||
)
|
|
||||||
self.labels = [submob.label for submob in self.submobjects]
|
self.labels = [submob.label for submob in self.submobjects]
|
||||||
|
|
||||||
def get_file_path(self, is_labelled: bool = False) -> str:
|
def get_file_path(self, is_labelled: bool = False) -> str:
|
||||||
|
|
Loading…
Add table
Reference in a new issue