Grasshopper dimension move text grip?

How can I move a text grip in a Grasshopper linear or aligned dimension?

You’re way above my coding level so the only reason I’m chiming in is because I’ve just had to completely dissect dimension objects in order to create an ‘autoleader’ system - everything’s fresh in my head (sort of - struggled the entire way haha).

I work with geometry more than DocObjects and don’t usually touch the grips.

https://developer.rhino3d.com/api/rhinocommon/rhino.docobjects.rhinoobject/getgrips

You can get the grips (which you probably know way more about that I do) but telling which one’s which?

You could come up with some sort of scheme where you use TextPosition (on the geometry) to figure out where the closest grip to the center of the text actually is (DistanceTo). But at the same time disqualify the other points (could be done by using “Get3dPoints”, matching up the TextPosition and using the rest to tell which grip locations you want to ignore). That would probably work almost all the time.

You can move the text using just the TextPosition too obviously but I imagine there’s some reason you’re using the grips.

https://developer.rhino3d.com/api/rhinocommon/rhino.geometry.dimension/textposition#

Anything can be done with code. I was wondering why it cannot be done with native tools?

1 Like

Thank you for your report. I have logged this requirement in the feature list.

RH-91233 Grasshopper dimension move text grip

1 Like