Certain behavior in the Script Editor makes editing or viewing files in any other editor extremely messy and confusing.
It comes down to indentation behavior.
Standard indentation styles are:
- indentation distance: 2 or 4 characters
- character: spaces or a single tab
- tab distance: 8 characters
GMAT's Script Editor is configured as follows:
- indentation distance: 3 characters
- GUI indentation character: spaces
- Editor indentation character: tab
- tab distance: 3 characters
This leads to the following situation:
- User saves script from GUI.
- Script is saved with 3-space indentation.
- User opens the script in the editor and adds a new line (say, in a For loop)
- New line automatically has a 1-tab indentation, with a tab distance that happens to be set at 3 characters
- User views the script in Notepad++, and now the indentation is messed up, because every editor has its own tab distance.
In GMAT script editor:
This may seem like a minor issue, but when sharing lengthy scripts among several people who use different editors, it becomes a readability issue.
- make GMAT editor indent consistently, either using spaces or tabs
- set tab distance at standard distance (4 or 8 char)
- set default indent at standard distance (2 or 4 char)