How to make Angular dimension by Python Rhino

Hi all

I wanna make an Angular dimension on Rhino by Python can anyone help.

import Rhino
import scriptcontext as sc

plane = Rhino.Geometry.Plane.WorldXY
center = Rhino.Geometry.Point3d(0.0,0.0,0.0)
radius = 5.0
angle = Rhino.RhinoMath.ToRadians(45)
offset = 12.0
arc = Rhino.Geometry.Arc(plane, center, radius, angle)
ang_dim = Rhino.Geometry.AngularDimension(arc, offset)

sc.doc.Objects.AddAngularDimension(ang_dim)
sc.doc.Views.Redraw()
2 Likes

Hi Gijs,

Is there a script that can dimension an angle as a cut angle. For example -90 degrees from the angle shown using the usual angle dim tool in drafting.

Cheers,
Alan

Hi @Alan_Goulbourne,

Can you post a file and/or image of what you’re looking for?

Thanks,

– Dale

Hi Dale,
Thanks for the quick response here is a screenshot to explain, I know it’s easy to do the math etc, but some fabricators like the cut angle shown so currently you have to draw a perpendicular line to get the cut angle and I just wondered if there was a way that a script could be written to offer a cut angle option to be displayed in the same way.
Thanks you.

Cheers,
Alan