Formatting Text

Text in text objects can be formatted. This section covers changing the font, style, size, orientation, justification, and inter-line spacing. Positioning of individual characters (e.g., crenatura) is discussed in the following section. Specifying the fill (color, pattern, etc.) of text is covered in Capitolo 10, Attributes.

There are three methods to format text. The first is to use the items in the Strumento Testo-Controlli Strumento, the second is to use keyboard shortcuts, and the third is to use the Testo e Carattere dialog.

Formatting with the Tool Controls

The font family, font size, justification, font style, and text direction can be changed from the Strumento Testo-Controlli Strumento. If characters within a text object are selected, the changes apply only to those characters. Otherwise, the changes apply to all selected text objects (to select more than one text object, switch temporarily to the Strumento Selettore). Changes made when no text object is selected (or a new blank text object is created) change the default style. (Except flowed-text: Bug?)

Font Family:  The leftmost drop-down menu allows one to select the font family. When activated, the menu shows samples of the various fonts available to Inkscape. (The text used for the sample can be customized by editing your .preference.xml file.)

Font Size:  The adjacent drop-down menu sets the font size in pixels. To select a size that is not in the menu, simply type the number in. The mouse scroll wheel can also be used to select the size when the cursor is over the menu (doesn't always work: Bug).

Justification:  Text can be justified by clicking on the following icons:

  • Left justified.

  • Centered.

  • Right justified.

  • Left and right justified.

Left, center, and right justified text.
Left, center, right, and both left and right justified text.

Only flowed text can be both left and right justified at the same time.

Style:  Text can made Bold or Italicized (if the chosen font supports these options). These are the styles supported by the SVG standard.

Orientation:  The orientation of the text can be chosen by clicking on one of the following icons:

  • Horizontal.

  • Vertical.

Horizontal, vertical, and rotated text.
Horizontal (left), vertical (center), and rotated (right) text.

The vertical choice is mostly applicable to languages written from top to bottom and from right to left, such as Chinese, Japanese, or Korean. See the above figure to see the difference between vertical text and text rotated by 90 degrees. A block of text can only have one orientation.

Formatting with the Keyboard

Font style, interline spacing, and inter-character spacing for a line of text are changeable via the keyboard.

Text attributes: Applies to selected text.

  • Ctrl+B: Toggle Bold on/off. Text must be selected.

  • Ctrl+I: Toggle Italics on/off. Text must be selected.

Letter spacing: Commands apply to line with cursor or selection for regular text and applies to paragraph for flowed text. The adjustments are specified in Pixel schermo and thus depend on the zoom level.

  • Alt+>: Expand line or paragraph by one Pixel schermo.

  • Alt+<: Contract line or paragraph by one Pixel schermo.

  • Shift+Alt+>: Expand line or paragraph by ten Pixel schermo.

  • Shift+Alt+<: Contract line or paragraph by ten Pixel schermo.

Line spacing: Commands apply to entire text object. The adjustments are specified in Pixel schermo and thus depend on the zoom level.

  • Ctrl+Alt+>: Make text object one Pixel schermo taller.

  • Ctrl+Alt+<: Make text object one Pixel schermo shorter.

  • Shift+Ctrl+Alt+>: Make text object ten Pixel schermo taller.

  • Shift+Ctrl+Alt+<: Make text object ten Pixel schermo shorter.

Formatting with the Text and Font Dialog

Font family, style, and size; justification and line spacing can be changed via the Testo e Carattere dialog (Testo Testo e Carattere... (Shift+Ctrl+T)). Changing line spacing is only accessible from the dialog. The dialog is split into three parts, the first for selecting the Font Family, the second for selecting the Style and Size, and the third for selecting the Layout. A preview of the proposed changes is shown on the dialog. Changes are not made to the selected text until the Apply button is clicked. Changes apply to the whole text object unless a portion of the text is selected in which case only the selected text is affected. New text can be forced to use a specified format by setting the default with the Set as Default button.

Text and Font dialog.
Testo e Carattere dialog.

Font Family:  The names of all the Font Families installed on your computer should be shown. Click on the name to select a new Font Family.

Style and Font Size:  After a Font Family is selected, the Style box will show the available styles for that family. Not all families have all styles. Oblique is often used instead of Italics.[13]

The Font Size can be selected from the drop-down menu. Font size is measured in points. A font size that is not listed can be typed into the Entry box. If you choose a large font, the preview window may not be large enough to show the entire text. In this case, the preview window can be made larger by increasing the size of the dialog window.

Layout:  The alignment and orientation of text can be changed by clicking on the appropriate icon. See the previous section on using Controlli Strumento for more details on the use of the justification and orientation options.

Text can be:

  • Left justified.

  • Centered.

  • Right justified.

  • Left and right justified.

The orientation of the text can be:

  • Horizontal.

  • Vertical.

Line spacing (the distance between text Linee base) can be changed by the Line spacing entry box.

[13] An Oblique font is usually a regular font that has been skewed. A true Italic font has several characters (e.g., 'a' and 'a') that have different designs.