Text Shape
Intro
Create and format text.
A Text Shape can also be created in the Viewport using the Text tool. With the Text tool selected, click and drag to draw a Text Box. If you Option/Alt + click on the Text tool or, with the Text tool selected, click once in the Viewport, the Text Shape will be created with Auto Width and Auto Height checked. This results in the text box fitting the text rather than the text fitting within the Text Box.
UI
- Shape
- Background
- Advanced
String - Enter text, numbers or symbols here.
- Add and connect a String Generator from a list. - Open a popover window to enable/disable the font's OpenType features. If the current string (or selection) does not contain a combination of glyphs that could be affected by a particular option, that option will be dimmed. OpenType can be applied to the entire string or via selections and combined with rich text features. Note that OpenType is not supported if the String attribute has an input connection. In this scenario, use an Apply OpenType Style Behaviour instead. - Clear any rich text or OpenType styling to return the text to its default. - Open a popover version of the Glyph Browser. Double click glyphs to add them to the String. Note that adding glyphs is not supported if the String attribute has an input connection. In this scenario, open the Glyph Browser and add glyphs to the input directly.Font - Select the Font and Weight.
If a Variable Font is selected, a small hamburger icon will appear to the right of the Font attribute. Click this icon to load a pop over window in order to access the font's axes. Drag the pop over window's header to detach it in order to make connections to the axes.
Typeface - Connect a Typeface. This is a way to connect different Text Shapes to the same typeface.
Font Size - Set the size of the font.
Shrink to Fit Text Box - When checked, the Font Size will be automatically reduced at the point the String overflows the Text Box. Note - this requires Auto to be unchecked on the Text Box Size Attribute.
Allow Word Breaks - When unchecked and with Shrink to Fit Text Box checked, words are prevented from wrapping over lines. This is useful for automated templates to prevent long words being split across lines where they would otherwise extend outside the text box. Instead, the text will be scaled appropriately.
Hyphenated words (e.g. Sub-Mesh) will be treated as separate words unless they contain a NON-BREAKING HYPHEN character (U+2011).
Avoid Orphans - When checked, ensure that wrapping text within a Text Box does not result in single words being 'orphaned' on the last line.
Alignment - Align text horizontally to the Left, Centre, Right or Justified. Justified text increases the spaces between words aligning the text to both the left and right margins except the last line of a paragraph which is aligned to the left.
Vertical Alignment - Align text vertically to the Top, Centre, Bottom or Baseline.
Character Spacing - Set the distance between characters.
Word Spacing - Set the distance between words.
Line Spacing - Set the distance between lines.
Paragraph Spacing - Set the distance between paragraphs. A paragraph is defined by a line break.
Text Box Size - Set the size of the area the text wraps within.
- Auto Width - When checked, the Text Box is sized to the width of the text.
- Auto Height - When checked, the Text Box is sized to the height of the text.
Force Monospacing - Click the checkbox to remove any kerning from non monospace fonts (useful when animating text strings but need to maintain each character's position). Use the Monospace Multiplier to increase or decrease the space between monospaced characters.
String Manipulators - Add a String Manipulator.
Style Behaviours - Add a Style Behaviour. Style Behaviours allow for the procedural manipulation of text strings. For an example, see the Apply Font Size Utility.
Material Behaviours - Add a Material Behaviour. Material Behaviours allow for the procedural manipulation of text strings. For an example, see the Apply Text Material Utility.
Formatting Inputs - Inject a String/Text into the Text Shape. This allows you to set up Text containing different styles, colours or sizes. Any connected Text or String can then be referenced by its index within curly brackets. For example, a Text Shape containing the Text string Cavalry {0}
will inject the text from another Text Shape connected to Formatting Inputs index 0.
Formatting Inputs
- Create a Text Shape (Text Shape 1).
- Using the
+
icon on the Formatting Inputs attribute row, add a second Text Shape (Text Shape 2). - Set the Font Weight for Text Shape 2 to Bold.
- On the Fill tab, set Text Shape 2's Color to blue.
- Change the Text input for Text Shape 2 to
rules
. - On Text Shape 1, insert a space character between
Cavalry
and{0}
Text Shape 1 now displays 'Cavalry rules' (with rules in blue).
Text Path - Connect a Shape to position the Text Shape along.
When Text is placed along a path its Alignment will be set based on the path's start/centre/end. Text will be positioned as follows depending on the Alignment:
- Left - its left edge (first character) is positioned at the path's first point.
- Centre - its centre is positioned half way along the path.
- Right - its right edge (last character) is positioned at the path's last point (for closed paths this will be the same as the first point).
Path Loop - When checked, the Text Shape will loop around the Path.
Path Travel - Move the Text Shape along the Path.
Path Push - Move the Text Shape along the Path's normals.
Use the Shape > Reverse Contour(s)
command or Reverse Path Behaviour to position Text on the other side of a Path.
Background Shape - Add a Custom Shape to be used as the background. Note - this is an output connection. To reconnect, connect the Text Shape's Background Shape attribute to the Custom Shape's Input Shape attribute.
Mode - Set the level for the Background Shape to be based on:
- Document - Create a Shape to encompass the entire String.
- Paragraph - Create a Shape for each paragraph found within the String. Note - a paragraph is defined by an empty line (e.g. two line returns).
- Line - Create a Shape for each line found within the String.
- Word - Create a Shape for each word found within the String.
- Character - Create a Shape for each character found within the String.
Specific Indices - Manually enter the indices to determine which paragraphs/lines/words/characters are selected. Enter comma separated values (e.g. 0, 4, 7
) or create ranges using colons (e.g. 1:4
) or a combination of both (e.g. 2, 3:5
). Entering the string first
or last
will procedurally select those indices. Negative values can also be used to select indices working backwards from the end of the string. e.g. -1
= last, -2
= penultimate, -3
= third to last, etc.
Padding - Increase/decrease the padding of the Custom Shape around the Text Shape.
Ascender Adjustment - Offset the vertical padding of the Custom Shape above the ascenders (e.g. t, d, l) within the font.
Descender Adjustment - Offset the vertical padding of the Custom Shape below the descenders (e.g. g, y, j) within the font.
Corner Radius Mode - Determine whether to set the corner radius globally on on a per corner basis:
- All - The Corner Radius setting will set all corner radii.
- Individual - Set each corner individually via Top and Bottom Radii.
Corner Radius - Set a radius for the rectangle’s corners.
Top Radii - Set a radius for the top corners [l, r].
Bottom Radii - Set a radius for the bottom corners [l, r].
Chamfer - Chamfer the corners of the rectangle.
Font Scale - Output the scale factor applied to the Text when Shrink to Fit Text Box is checked.
Automatic Naming - When checked, a Text Shape's 'nice name' is inherited from its String unless it has been manually set by renaming it in the Scene Window.
See Sub-Mesh for animating Text by character/word/line.
When using a combination of features with Text they will affect the output in the follow order:
- Text input (includes String Generators and String Manipulators)
- Style Behaviours (Apply Character Spacing, Apply Font Size, Apply Typeface)
- Standard Materials (Fill, Stroke)
- Material Behaviours (Apply Text Material)
- Formatted Inputs
By default, a Text Shape's 'nice name' is inherited from its String unless it has been manually set by renaming it in the Scene Window. This can be disabled by unchecking Automatic Naming in the Advanced tab.