Overview
Command Text is a function that lets you describe Turbo Guide Line operations in a text file and execute them automatically. Commands are executed in order from the beginning of the file and perform the same processing as normal user operations.
File Format
| Item | Description |
|---|---|
| Character encoding | UTF-8 (with or without BOM) |
| Line ending | CR+LF / LF / CR |
| Command | One command per line |
| Maximum lines | 2000 |
| Maximum line length | 1024 |
Execution Order
Commands are executed in the order in which they are written.
CLEAR
VLINE=100,100,RED,3,SOLID
HLINE=100,200,BLUE,3,SOLID
If the same command is written multiple times, every occurrence is executed.
Comments
Lines beginning with # are treated as comments and
are not executed.
# Comment
VLINE=100,100,RED,3,SOLID
Blank lines are also ignored.
Command List
| Command | Parameters | Description |
|---|---|---|
| CLEAR | - | Clear all guide lines |
| MAIN_POSIZE | Left, Top, Width, Height | Change the main window position and size |
| TRANSPARENT | Opacity | Set transparency |
| EXTENDED | YES / NO | Switch Extended mode |
| VLINE | X, Y, Color, Width, Style | Draw a vertical line |
| HLINE | X, Y, Color, Width, Style | Draw a horizontal line |
| ANGLE | X, Y, Angle, Color, Width, Style | Draw an angled line |
| RECT | X1, Y1, X2, Y2, Color, Width, Style, Equal | Draw a rectangle |
| CIRCLE | X1, Y1, X2, Y2, Color, Width, Style, Equal | Draw a circle |
| P2P | X1, Y1, X2, Y2, Color, Width, Style, Mode | Draw a line between two points |
| CROSS | X, Y, Color, Width, Style | Draw a crosshair |
| CENTER_CROSS | Color, Width, Style | Draw a center crosshair |
| EDGE | Color, Width, Style | Draw border lines |
| MARGIN | Margin, Color, Width, Style | Draw margin lines |
| MESH | Gap, Color, Width, Style | Draw a mesh |
| AUTOFIT_SET | Title, TglLeft, TglTop, TglWidth, TglHeight, TargetLeft, TargetTop, TargetWidth, TargetHeight, Cycle, Detect | Auto Fit settings |
| AUTOFIT | YES / NO | Enable or disable Auto Fit |
| AUTOFIT_EXEC | - | Execute immediately using the current Auto Fit settings |
| FIT_SET | No, Title, Menu, Left, Top, Width, Height | Change Fit settings |
| FIT_EXEC | No | Execute the specified Fit |
| BACKGROUND | FileName, ImageMode | Background image |
Parameters
The following table describes the main parameters used by each command.
| Parameter | Value | Description |
|---|---|---|
| X, Y | Integer | Drawing start position or center position (client coordinates) |
| X1, Y1 | Integer | Start coordinates or top-left coordinates |
| X2, Y2 | Integer | End coordinates or bottom-right coordinates |
| Left, Top | Integer | Top-left position of the window |
| Width, Height | Integer | Window width and height |
| TglLeft, TglTop | Integer | Top-left position of Turbo Guide Line for Auto Fit |
| TglWidth, TglHeight | Integer | Width and height of Turbo Guide Line for Auto Fit |
| TargetLeft, TargetTop | Integer | Top-left position of the Auto Fit target window |
| TargetWidth, TargetHeight | Integer | Width and height of the Auto Fit target window |
| Color | Color name | Line color |
| Width | 1,2,3,4,5,8,10,20 | Line width |
| Style | SOLID,DASH,DOT | Line style |
| Angle | -89.99 to -0.01 / 0.01 to 89.99 | Angle (degrees) |
| Gap | Integer 1 or greater | Mesh spacing |
| Margin | 1 to 99 | Margin (%) |
| Equal | YES/NO | Whether to make a square/perfect circle |
| Mode | FULL/SHORT | Drawing method for a line between two points |
| Opacity | 0 to 100 | Transparency (%) |
| Title | String | Target window title |
| Menu | String | Name displayed in the Fit menu |
| No | 1 to 9 | Fit number |
| Detect | YES/NO | Enable change detection for Auto Fit |
| Cycle | 0 to 999 | Auto Fit execution cycle (seconds) |
| FileName | String | Background image file name (full/relative path) |
| ImageMode | String | NORMAL/STRETCH/CENTER/ZOOM |
Color
Specify the line color.
BLACK
RED
GREEN
BLUE
WHITE
AQUA
HOTPINK
VIOLET
YELLOW
GRAY
Width
Specify the line width.
1
2
3
4
5
8
10
20
Style
Specify the line style.
SOLID
DASH
DOT
Setting Commands and Execution Commands
Commands that change settings and commands that execute processing are separate.
Auto Fit
AUTOFIT_SET=...
AUTOFIT=YES
AUTOFIT_EXEC
Fit
FIT_SET=...
FIT_EXEC=1
Setting commands update the Turbo Guide Line settings, while execution commands perform processing using the current settings.
Error Handling
Lines containing input errors are skipped and processing continues with the next command.
Examples:
- Undefined command
- Incorrect number of parameters
- Numeric conversion error
- Value out of range
- Invalid color, line width, or line style
File Errors
If the file itself has a problem, command execution is stopped.
Examples:
- File does not exist
- File is not UTF-8
- Maximum number of lines exceeded
- Maximum line length exceeded
Execution Errors
If an internal error occurs during execution, command execution is stopped for safety.
Syntax
Command with parameters:
COMMAND=Parameter1,Parameter2,...
Command without parameters:
CLEAR
AUTOFIT_EXEC