Skip to content

Scaling a coordinate system adds a stroke width to text labels #4648

@uwezi

Description

@uwezi

Description of bug / unexpected behavior

Text objects in Manim do not have a visible stroke and consist only of filled polygon shapes as glyphs. When scaling text objects this behavior is kept consistently, but when scaling a compound object like a NumberPlane() the text labels suddenly end up with a non-zero stroke width.

Expected behavior

Objects with a zero stroke width should keep this width when scaling.

How to reproduce the issue

Code for reproducing the problem
class nplScaling(MovingCameraScene):
    def construct(self):
        npl = NumberPlane().add_coordinates()
        self.add(npl)
        self.play(npl.animate.scale(0.01,scale_stroke=True,about_point=ORIGIN))
        self.play(
            self.camera.frame.animate.scale(0.01)
        )
        self.wait()
        self.play(npl.animate.set_stroke(color=RED))
        self.wait()

Additional media files

Images/GIFs Image

Additional comments

The behavior is consistent between my Windows 10 system and Manimator on Discord.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions