By linking Visual Studio Code (hereinafter referred to as VS CODE) and StateGo, you can make your work very easy.
Register VS CODE in StateGo
Click [Tool] -> [Source Editor Setting] on the menu bar to display the Source Editor Setting dialog.
As for the specification of Source Editor, easy input method is provided.
Using the Editor Candidate
First of all, please make sure that "Visual Studi Code" is displayed as an editor candidate.
If you have installed VS CODE by default, it should be displayed.
If you installed VS CODE in a place other than the default, please specify the full path of Code.exe in the environment variable VSCodeExe.
After specifying it, start StateGO, please confirm that it is displayed in the editor candidate.
The reflection of the environment variable may require the reboot of PC.
Please push the "Input" button with Visual Studio CODE displayed.
The command for calling is displayed in the command column.
Push the【SAVE & CLOSE】 button and it is completed.
Enter the command directly
You can type the command directly into the command input field.
You can use the following arguments
%1 - file name
%2 - line number
Use your history
The commands you have used in the past will be shown in the history.
Then you can enter them.
Registering StateGo in VS CODE
Use the Open in External Editor extension.
After installation with the extension, you can use the
- [File] > [User Settings] > [Settings] > Setup screen opens
- Enter "open in external editor" in Search Settings → Search results are displayed
- Alt-editor ... Select "Edit in settings.json" → settings.json will appear
- Add two lines as shown below.
If you have a different installation path for StateGo, change it to match.
How to use
The following things are possible by setting both StateGo and VS CODE for activation.
State Source View
You can check the source of the selected state with the VS CODE.
I want to see the program part of the selected state in my editor!
Any of the following methods
- From the state's context menu, select "To Source".
- Press the [Source] button on the utility panel (bottom left corner of the screen).
- With state selected, hold down the control key and press the J key.
The VS CODE opens and the cursor is displayed on the line of the selected state
Open StateGo corresponding to the source displaying VS CODE
If the file displayed in VS CODE is an output file of StateGo, you can call StatGo, the conversion source, from VS CODE and check it.
I'd like to see SteteGo in a file being displayed in VS CODE!
Press the E key while holding down the Alt and Shift keys.
StateGo starts and opens the StateGO file from which it was converted.
Using VS CODE in state item editing
StateGo enters a program directly into a state. In that case, you can input the program on VS CODE.
You can mark the corresponding part of the output file, and you can edit and reflect the space between the marks.
Therefore, you can use word completion function to input program easily.
I want to use VS CODE in state item editing.
Click on "External Editor" in the Edit Item dialog
VS CODE is launched and the edit part is displayed.
Edit and save.
Reflected in the Edit Item Dialog