Skip to content

Refactored arc.py file#4757

Open
GoThrones wants to merge 3 commits into
ManimCommunity:mainfrom
GoThrones:arc
Open

Refactored arc.py file#4757
GoThrones wants to merge 3 commits into
ManimCommunity:mainfrom
GoThrones:arc

Conversation

@GoThrones
Copy link
Copy Markdown
Contributor

@GoThrones GoThrones commented Jun 1, 2026

Overview: What does this pull request change?

All the changes in this PR are backwards compatible.

This PR has made following changes in arc.py file:

(1) Made 'tip_shape' and explicit parameter in CurvedArrow class.

(2) Made parameter named 'center' an explicit parameter for Circle class.

(3) Included deprecation warning for the parameters: 'dim_to_match' and 'stretch' in 'surround' method of Circle class as those parameters are not used at all.

(4) Made parameter named 'point' explicit in init of AnnotationDot class and in LabeledDot class.

(5) Wrote docstring for AnnotationDot class.

(6) 'center' an explicit parameter in Ellipse class, considering that Ellipse in ManimCE is just a circle which has been squashed and elongated in different directions.

(7) Made parameter named 'arc_center' explicit in init of AnnularSector class.

(8) made 'arc_center', 'start_angle' and 'angle' explicit parameter in init of Sector class.

(9) Wrote explanatory comment for why the points our outer_arc has been reversed, and why init_points has been written, in AnnularSector class.

(10) made 'center' an explicit parameter in Annulus class.

(11) wrote explanatory comment for why the points our 'inner_circle' has been reversed in Annulus class.

(12) Renamed 'tip_shap_start to' 'tip_shape_at_start' and 'tip_shape_end' to 'tip_shape_at_end' in init of CurvedDoubleArrow.

(13) Also, modified one test files.

(14) Few minor modifications here and there.

Motivation and Explanation: Why and how do your changes improve the library?

Explicit parameters make it easier for users to understand which arguments can be provided, without going through the source code of manimce.

Reviewer Checklist

  • The PR title is descriptive enough for the changelog, and the PR is labeled correctly
  • If applicable: newly added non-private functions and classes have a docstring including a short summary and a PARAMETERS section
  • If applicable: newly added functions and classes are tested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant