0
votes

If create a Dot and add (as a submobject) a label (Text mobject) above the dot and then call the get_center function, the center of the dot is moved because the function uses the submobjects to calculate the center of the mobject.

>>> v = Dot()
>>> v.get_center()
array([0. 0. 0.])
>>> v.add(Text('a').move_to(UP))
>>> v.get_center()
array([0. , 0.58890625, 0. ])

How can I get the center of the dot ignoring the submobjects?