I’d like to leave a small gap between the bottom of a text object and the geometry below it, as shown in the image. I want that gap to scale with the text when I change Model space scale.
Model space scale changes the text height and other annotation settings, but the insertion point stays at the bottom of the text. Moving the text away from the geometry creates a fixed gap that doesn’t scale.
Is there a way to define a margin or offset between the text and its insertion point that scales with the annotation?
There isn’t a setting for an offset between a text object and its insertion point. Text gap in the annotation style applies to dimensions and leaders, not to plain text.
Thanks, Dale. Could this be logged as a feature request?
I’d like a configurable gap between a text object’s insertion point and its bottom edge, scaled with Model space scale. Ideally, the gap could also be expressed as a proportion of text height, so it stays visually consistent when text height changes.
With the gap set to zero by default, existing text would behave exactly as it does today. This would add a useful feature without changing current behavior.
My current workaround is to add a second line containing a space and set line spacing to 0.25. It produces the spacing I need, but requires extra text content just to control placement and causes formatting problems when exported to DXF or opened in other CAD applications.
If this is something that could be a block with an attribute, you could whip up some sort of python script for it. It would run just like a command. I guess it could be done with just ordinary text as well.
I’ve dealt with similar things in AutoCAD - I just grab the annotation scale (or rather, 1 divided by the “cannoscalevalue” variable). In Rhino’s case it would have to be tied to your current annotation style’s scale (which I don’t anticipate being a problem).
My texts are all created by a plugin I created, and they are in the right place with the right gap. But if the user later changes the scale, the texts resize, but the gap doesn’t.
Would using a block scale the gap together with the font size?
One file has thousands of texts like this. Is it ok to create thousands of unique blocks?
That’s kind of a good thing because it means you’re familiar with programming.
It is actually possible to add meta-data to your text while you use your plugin to create the text. The meta data could be handled many different ways.
I’d have to see what you’re actually doing… but… it absolutely could.
Literally thousands? The block definition itself shouldn’t take up a lot of memory, but maybe a McNeel employee might chime in on that. It would be a simple block with attribute user text. The bigger issue would likely be how much of a pain it is to deal with the text inside a block… I’ve dealt with and solved similar things in AutoCAD but I’m not quite sure of your workflow so I don’t want to put too much momentum into this recommendation. I’ve made similar things work for me but likely in different situations.
Note that below is based on someone who’s done some scripting in Rhino but I’ve been doing AutoLISP (for AutoCAD) like mad for the last few months (and little to nothing in Rhino):
Based on your pictures, What I would do is make a script that gets the text’s scale (or text height), gets it’s insertion point and attachment point (not sure what these are called in Rhino), uses a “curve closest point” function (I’ve used this before but don’t know the exact name), and through that you could get a reliable way of nudging the text just the right amount off of the line.
One I’m not too sure about are: Would this be a global function or only affect selected objects? I mean are there multiple scales in one model?
You mean I would need a script to create the text and one to scale it?
That’s what I’m doing now, but my intention was to avoid the script in the scaling phase. Managing the scale from the script is possible, but there are too many parameters in play, so I just recreate the text instead of scaling it and repositioning it.
Many texts in a drawing are likely to be near a geometry. Dimension texts are always near a geometry.
Rhino does manage scalable gap for dimension texts, not for text texts. I think it would make sense to close that gap (sorry) and make text texts behave like dimension texts.