SCTEXT
SCTEXT is one window for everything to do with labels and numbering: placing new labels, clicking existing texts or attributes and numbering them, or giving a whole selection a sequence in one go (for example CAB-001, CAB-002, …). You see the sequence live in the window and, for a selection, also as a preview in the drawing before anything is changed.
Starting
Type SCTEXT on the command line. If you preselect texts and/or blocks with attributes, the window opens straight in Number a selection mode.
How it works
- The SCAD Text — labels and numbering window opens. Under 1. What do you want to do? choose one of three tasks:
- Place new text: place new labels.
- Click existing: click individual texts or attributes.
- Number a selection: number a selection in one go.
- Under 2. Label sequence, set the sequence (see below). Under Preview you see the first values of the sequence.
- Fill in the rest of the window for the chosen task and click the button at the bottom: Place text, Start picking or Preview in drawing.
- Continue in the drawing.
ESCstops the current action in the drawing. The window itself also has a Cancel button.
Place new text
The label follows the cursor with a live preview. The command line shows Place <value> [Forward/Back/Freeze]:. Each click places a label with the next value of the sequence. Labels are placed as MText. At the end the command reports SCTEXT: placed N label(s).
Under 3. New text appearance you set the look:
| Field | What it does |
|---|---|
| Text style | Text style of the label. |
| Layer | Layer of the label. Only unlocked, visible layers are in the list. |
| Height | Text height (default 10). |
| Rotation (degrees in UCS) | Rotation in degrees, relative to the current UCS (default 0). |
| Alignment | Under More formatting: alignment of the label around the insertion point (nine positions, from Top left to Bottom right). |
| Background mask | Under More formatting: gives the label a background in the colour of the drawing background. |
| Mask border factor (1–5) | Under More formatting: the space around the text for the mask (default 1.15). |
Click existing
Click existing text (text, MText or a block attribute) in the order you want. The command line shows Apply <value>: select text or an attribute [Forward/Back/Freeze]:. Each click gives that object the next value. The full content of the text is replaced. At the end the command reports SCTEXT: updated N label(s).
Number a selection
- Click Select objects in drawing… and select texts and/or blocks with attributes (
Select text and/or attributed blocks:). The window shows how many texts and blocks are selected. - Under Text or attribute to number, choose what is numbered:
Text objects (N)orAttribute: <TAG> (N blocks). - Choose the order under Order (see below).
- Click Preview in drawing. The new labels appear in the drawing as a preview. The command line shows
Preview: N/N labels shown, N existing-label conflicts. [Apply/Reverse/Exclude/Settings] <Apply>:. - Press
Enter(or chooseApply) to apply the numbering. The command reportsSCTEXT: numbered N object(s), from <first> to <last>.
| Option in the preview | What it does |
|---|---|
Apply | Applies the numbering. |
Reverse | Reverses the order. |
Exclude | You pick an object (Select an object to exclude from numbering:); it drops out of the numbering and the rest is renumbered. |
Settings | Back to the window. |
A click in the drawing only refreshes the preview, also after zooming. ESC stops without changing anything. If some of the proposed labels already exist elsewhere in the drawing, a window asks whether to continue anyway (... proposed label(s) already exist outside this selection. Apply anyway?).
Options
Label sequence (simple)
| Field | What it does |
|---|---|
| Prefix | Text before the number. |
| Start | Start value, default 001. 001 gives leading zeros (001, 002, …), A gives letters (A, B, … Z, AA). Numbers with decimals work too. |
| Step | Step size, default 1. 0 repeats the same label, -1 counts down. |
| Suffix | Text after the number. |
| Continue from label… | You click an existing label (Pick the text or attribute to continue from:). Prefix, Start and Suffix are filled in with the next value, for example CAB-037 becomes CAB-038. If the label contains several numbers, fill in Prefix and Suffix first so it is clear which part counts up. |
| Find next unused | Finds the first value from Start that does not yet exist in the current space. |
Use a multipart label
A label made of four parts one after the other, where you make each part fixed or changing. Per part you set Start / literal text, End (optional), Step and Fixed. Fixed parts (Fixed on) contain literal text or a separator. The last changing part counts up first; at its end value it starts over and the part before it counts up by one. An empty End means the part keeps going without wrapping around.
Example for A-01 through A-12, then B-01:
| Start / literal text | End | Step | Fixed |
|---|---|---|---|
| A | 1 | off | |
| - | on | ||
| 01 | 12 | 1 | off |
| on |
Continue from label… and Find next unused cannot be used in multipart mode.
Targets and order (Number a selection only)
| Field | What it does |
|---|---|
| Include matching visible blocks in the active viewport | Attributes only: numbers all blocks of the same type that are visible in the current view, also ones you did not select. Selected blocks outside the view drop out. |
| Fill empty values only | Skips targets that already have a value. A block whose chosen attribute is filled in anywhere is skipped as a whole. |
| Order: By position | Sorts by position in the current UCS. Default is X first, then Y, then Z. Drag the grip above an axis left or right to change the order (or use the arrow keys with the grip focused). Per axis you choose the direction: Left to right / Right to left, Front to back / Back to front, Top to bottom / Bottom to top. |
| Order: Along a line or polyline | Sorts along a line or polyline. After Preview in drawing you pick the line (Select line or polyline to define the increment order:). Only objects crossed by that line are numbered. |
| Order: Along a line or polyline, reversed | The same, in the opposite direction. |