Multiple font sizes in single text box

For denoting windows in Architectural Work many architects use a feet and inches finished size to denote the door so a 2668 is a 2’-6" (30") by 6’-8" (78"). On drawings this is typically noted with the feet component being larger than the inches so its a big 2 small 6 big 6 small 8. Is there a way (preferably an easy way) to do this in Rhino?

How is that done in Autocad or Revit? I can’t recall ever seeing that convention.

no idea… but I attached a screenshot of a plan i’m working with to show several examples (doors and windows) of what i’m talking about.

Feet an inches are the same size on your image, am I missing something?

If you look at any of the windows or doors you’ll see what is usually a 4 digit number - lets look at the front door just to focus on one. The front door is directly south of the stairway - you’ll see “3080 4-LITE TEMPERED” on 3 lines - the 3 is larger than the 0 and the 8 is larger than the 0 so this can be interpreted at a 3’-0" by 8’-0" doorway. All of the doors and windows have a similar nunuber 2080 for the front windows, 2680 for the coat closet, etc, etc.

Is there a particular workflow? Tagging a box of that size? or change an existing text? Block?

I’m not sure what you’re asking? As for the text, as far as I can tell you can only set the size of the font for the entire text area and can’t have different text attributes within a textbox… this has other ramifications like I wouldn’t be able to underline or italicize one word of the text within a text area… whatever text attributes I select apply to all of the text in a text block… seems like a problem to me for areas beyond my immediate need and i’m unfortunately guessing that the only option is to make a feature request but I’m hoping that its been something others have needed and there is some workaround.

This seems to be the case from what I can see.

You can set the font, bold, italic, and underline properties for individual letters and words within a text area:

I’ve achieved the different text sizes here by using different fonts - a possible work around for your original question.


Here’s a lighthearted solution.

Select text to create a group with the individual different size texts.

import rhinoscriptsyntax as rs
import Rhino as rh
import random

def split(word): 
    return [char for char in word]

selText = rs.GetObject("Select Text", 512)

textstr = rs.TextObjectText(selText)
textH = rs.TextObjectHeight(selText)
textPt = rs.TextObjectPoint(selText)

sizeList = [textH, textH*.66,textH, textH*.66]
charList = split(textstr)
ranname = random.randint(1,1000)
group = rs.AddGroup(ranname)

for inx,val in enumerate(charList):
    vMove = rh.Geometry.Vector3d((inx*.85),0,0)
    tAdd = rs.AddText(val, textPt + vMove ,sizeList[inx])
    groupadd = rs.AddObjectsToGroup(tAdd,group)


Hey Kevin, do you happen to remember the 2 fonts you used for the 2nd (4086) option? That would be a suitable workaround

this is great… I haven’t started messing with scripting within python so maybe this is a good opportunity to dive in. Thanks for the code.

The larger font is “Helvetica” and the smaller one is “ITF Devanagari”.

I was experimenting to see how difficult it would be to modify a font to a smaller size. I made these with “FreeSerif” and “FeeeSans” from “GNU FreeFonts” and copies I modified with the program “FontForge”.

The text in this image is all in one textbox.


1 Like

Nice tips