T-FLEX CAD lets a user add to the system his own commands, that start external applications and macros, open a document, a window with a folder or a library. Custom command added to the system can be added to the ribbon and various toolbars using the customization dialog.
The following command is used for adding a custom command to the system:
Icon |
Ribbon |
---|---|
Get Started > Options > Customize > User Commands... > User Commands... |
|
Keyboard |
Textual Menu |
- |
Customize > User Commands… |
After calling this command the User Commands dialog window will appear on the screen. In this window the following items are defined: the command's type (what sort of operations this command will do), command call parameters, command name, a line of a tooltip for a command and its icon for displaying in the textual menu or on the toolbars of the system.
To add the command, it is necessary to press the Add button.
Left section of the dialog contains the list of user-added commands. In order to select a command in the list click its row with .
Right section of the dialog contains following buttons:
•Add
Adds a new command to the list. Upon pressing this button a drop down list for choosing the type of the command being added will emerge:
oMacro – adding the command for calling a macro. When this item is selected, a window of an auxiliary dialog box for choosing a macro is opened. A macro can be selected from the list or assigned manually;
oExternal Application – adding the command for calling an external application (without exiting the T‑FLEX CAD). When this item is selected, a window of an auxiliary dialog box for selecting an external application and start-up parameters will emerge. An additional flag Wait for application completion prohibits continuation of work in the T-FLEX CAD before closing the window of external application;
oOpen Document – adding the command for opening the T-FLEX CAD document. When this item is selected, the standard file selection dialog box will appear;
oOpen Folder Window – adding the command for opening a certain folder with the T‑FLEX CAD documents. Upon choosing this item, the standard folder selection dialog box will be opened;
oOpen Library Window – adding the command for opening the T-FLEX CAD library. Upon choosing this option, the dialog box for assigning the library name will appear.
oInsert Fragment allows to add the Insert Fragment command. If you select this option, you can create a path to the fragment file, which will be inserted into the current document when you click on this button. The icon image for such a command can be taken from the fragment file itself.
oNew Document from Template - adding the command to create a document from the selected template. Upon choosing this item, the standard folder selection dialog box will be opened;
•Remove
Deletes the command selected in the list.
•Properties
For the command selected in the list, calls for the same dialog box as the one used upon addition of the given command. Thus, one can change parameters of the command (for example, indicate another file for opening or another macro).
•Export
Allows to export the list of the user's commands into an external file of the *.tfcmd format.
•Import
Allows to import the list of the user's commands from an external file of the *.tfcmd format.
•Run
Calls for the command selected at the moment in the list of the commands.
Upon defining user's commands one should keep in mind that the commands defined in the dialog box User Commands, by default, are not added to the textual menu or toolbars of the system. Access to these commands is possible only with the help of the button Run of the given dialog box. To simplify an access to the user's commands, it is possible to add them to the ribbon and various toolbars using the customization dialog.
The bottom section of the dialog contains following input boxes:
•Command Name
Name of the command selected in the list
•Prompt
Text of the tooltip, which appears upon moving the cursor over a button of the command selected in the list.
•Button Image
Icon of the command selected in the list. In this box you should specify a path either to an *.ico file, or to a T-FLEX CAD document. In the latter case the icon saved in the selected document will be used (if saved). Without T-FLEX DOCs integration the button located to the right of the box invokes the standard dialog for selecting a file stored on a disk. In the T-FLEX DOCs integration mode the button invokes the drop-down menu containing following commands:
Open
Invokes the standard dialog for selecting a file stored on a disk.
Open from T-FLEX DOCs
Invokes the dialog for selecting a file stored in T-FLEX DOCs.