Using the code snippet manager

VSScript offers simple code snippet manager window, which gives you a quick access to various useful Lua code fragments, which can be inserted into your code by a double click.

To open available snippet list, use the Snippets... option from VSScript menu, or click button on the script editor toolbar. The following dialog will appear:

You can choose the snippet category among those listed in the left-side window. Then, double click on chosen snippet in the right-side window. The snippet will be inserted into the editor at cursor position.

Adding your own snippets

Current version allows only predefined snippets, however you can still change or extend these snippets by editing the files directly. The files are located in Snippets subdirectory of VSScript installation directory. Each file has .vssnippet extension and describes one snippet category. The name of the file is equal to that category name.

The format is very simple. The name of the snippet is enclosed in @ ... @ block and everything after the second @ until the begginning of next snippet (another @) is considered as a code to be pasted in.

Table of Contents

Copyright (C) 2012-2015 Soft-Erg. All rights reserved.