Text Tool
Library: | Base |
Introduced: | 2.0 Beta 1 |
Behavior
The text tool allows you to create and edit labels associated with components. Which components support labels are indicated in the 'Text Tool Behavior' section of their documentation. As of the current release, the following components in the built-in libraries support labels.
Wiring Library |
Pin Probe Tunnel Clock |
Gates library | All components |
Library Memory | All components |
Inout/Output Library |
Button Dip Switch LED LED Bar RGB LED 7-Segments Display LED Matrix Port I/O |
Input/Output Extra Library |
Switch Slider PLA |
System On a Chip Library | Tous les composants |
For components that can take a label but have none assigned to it currently, you can click anywhere within the component to add a label. If there is already a label, you need to click within the label. If you click at a point where there is not currently a label to be edited, Logisim will initiate the addition of a new Label component.
In the current version of Logisim, text editing features are still fairly primitive. There is no way to insert a line break into a label. It is not possible to select a text region in a label, but you can do so in the attribute table in the Text or Label field.
Attributes
The tool's attributes are only valid for labels that are placed anywhere on the circuit. When it's a component label, the attributes defined by the component will prevail.
- Text
- The text appearing in the label. This value can be edited in the attribute table or, using the text tool, on the canvas.
- Font
- The font to use when drawing the label.
- Horizontal Alignment
- The horizontal positioning technique for the text relative to the label's official location (where the mouse was clicked in creating the label). "Left" means that the text should be drawn so that its left edge is at the location; "right" means that the text should be drawn so that its right edge is at the location; and "center" means that the text should be drawn so that its center (horizontally) is at the location.
- Vertical Alignment
-
The vertical positioning technique for the text relative to the label's official location (where the mouse was clicked in creating the label). "Base" means that the baseline should intersect the location; "Top" means that the text's top should intersect the location; "Bottom" means that the text's bottom should intersect the location; and "Center" means that the text should be centered (vertically) at the location.
The text's top and bottom is computed based on the font's standard ascent and descent values; thus, even if the actual text contains no tall letters (such as b) or descending letters (such as g), it is assumed to contain such letters for the purposes of vertical positioning.
Clicking on a component supporting the Text Tool will display that component's attributes.
Back to Library Reference