Stencils



Stencil sets define groups of stencil items.  A stencil item defines certain properties of a potential node. It is basically for creating new nodes with a given image and possibly tags and a label. It is restricted to reference and view nodes as these can have images.

NOTE: This facility is only for use with map views and will not work for list views.

Stencil set data is saved in the form of an xml file for each stencil set. Stencil sets are stored in the Compendium subfolder 'System\resources\Stencils' in further subfolders named after the stencil sets. Inside these stencil set folders will be the xml file holding the data and three further subfolders called 'nodeimages', 'paletteimages' and Templates, holding the relevant stencil set item images and template files (see below for further details). As all relevant data is contained in a stencil set folder, stencil sets can easily can be shared with other users if desired, by simply zipping up the relevant stencil set folder folder and sending it to them.

Stencil Management

You can create stencil sets and stencil items using the Stencil management dialog. This can be accessed from the Tools Menu or the Map Right-Click Menu. The initial Stencil management dialog will look something link figure 1 below:

Figure 1. The Stencils management dialog

To create a stencil set, press the 'Create New Stencil Set' button at the top of the Stencils management dialog. This will open the Stencil Set dialog, (which will initially be empty):

Figure 2. The Stencil Set dialog

You then need to enter a name for the new stencil set in the 'Full Name' field at the top of the dialog. When you later open stencil sets to use them they appear in a tabbed pane panel on the left side of the compendium application screen (see figure 6 below in the section called Using Stencils). Each stencil set opened will have a tabbed panel. The field 'Tab Name' allows you to enter an abbreviated name to appear as the tab panel label.

You can then start adding new stencil set items. To add a new stencil set item press the 'Add Item' button. This will open a 'Stencil Set Item' dialog similar to figure 3 below, (which will initially be blank):

Figure 3. A Stencil Set Item dialog

There are various properties you can set for a stencil set item:


Property

Purpose

Node Label

This allows you to enter a default label stub to appear when a node is created from this stencil set item. It is an optional field.

Icon Hint

This field allows you to enter text that will appear as the rollover hint for this stencil set item. NOTE: The Stencil icons in the Stencil Palette will be ordered by the icon hint text.

Node Type

This allows you to specify the type of node to create when creating a new node from this stencil set item. You choices are 'Reference', 'Map' and 'List', as only these three node types can have images.
Background This field will only be available when the node type chosen is 'Map'. It allows you to specify a map background image for the current stencil set item.
Template This field will only be available when the node type chosen is 'Map' or 'List'. It allows you to specify a Compendium xml template file which will be imported as the contents to the map / list node when it is created from this stencil item.

Shortcut: ALT +

This allows you to add a keyboard shortcut for creating a node from this stencil set item. You can currently have ten shortcuts per stencil set.

When you have more than one stencil set open and use a keyboard shortcut, it will take this to be the top-most open stencil set currently visible.

Node Image

This field holds a reference to the node icon image to add when a node is created from this stencil set item. 

If you select a node icon image which is larger than the scaled size of 96 x 96 pixels, you will be warned, but it will not stop you adding large images if you wish, they will simply be scaled. All image scaling slows down Compendium.

Note: when you save a stencil set, the image will be copied to the appropriate stencil directory subfolder for that set. In this way, stencil set directories can be passed around between users and will have all the relevant materials within.

Palette Image

This field holds a reference to the palette image, which is displayed in the Stencil Set tab panel palette (see figure 6 below for an example). If you do not select an image, the node image will be used.

Having this as a separate item allows you to set smaller image for the palette if you wish to keep the size of the palette to a minimum.

If you select a node icon image which is larger than the scaled size of 96 x 96 pixels, you will be warned, but it will not stop you adding large images if you wish, they will simply be scaled. All image scaling slows down Compendium.

Note: when you save a stencil set, the image will be copied to the appropriate stencil directory subfolder for that set. In this way, stencil set directories can be passed around between users and will have all the relevant materials within.

Tags

You can select none, one or more tags to be added to a node created from this stencil set item.

 

When you have completed all these fields, press 'Save' to save the new stencil set item and return to the Stencil Set dialog. You will see that the new Stencil Set item has appeared as in figure 4:

Figure 4. The Stencil Set dialog with new item added.


If you wish to edit any stencil set item select it and press the 'Edit' button, This will open a Stencil Set Item dialog with the existing details for you to edit, as in figure 3 above. If you wish to delete a stencil set item, simply select it from the list and press the 'Delete' button.

Once you have added all the items you desire press 'Save', button a new folder containing an xml file holding the stencil set data will be created, the Stencil Set dialog will close and the new stencil set will appear in the Stencils management dialog:

Figure 5. The Stencil management dialog with the new stencil set.

If you wish to edit any stencil set select it and press the 'Edit' button, This will open a Stencil Set dialog with the existing details for you to edit.

The 'Duplicate' button allows you to duplicate the selected stencil set, if you wish to create a second stencil set very similar to an existing one. You will be asked to give a name for the stencil set, and then the contents of the selected stencil set will be copied under the new name.

If you wish to delete a stencil set, simply select it from the list and press the 'Delete' button

NOTE: if Compendium cannot delete the associated folders and files due to the system not allowing it, you will need to manually delete the associated stencil set folder from the 'Stencils' directory in the Compendium home folder for the stencil set to be permanently deleted, otherwise it will reappear next time you open Compendium.

There is another button on this dialog called 'Duplicate'. This allows you to duplicate a stencil set, if you wish to create a second stencil set very similar to an existing one. You will be asked to give a name for the stencil set, and then the contents of the selected stencil set will be copied under the new name.

Using Stencils

To use a stencil set, go to the Tools Menu or the Map Right-Click Menu and select 'Open Stencil'. This option has a submenu listing all your current stencil sets. If you select one, you will see a tabbed panel appear on the left-hand side of the screen showing a palette of your chosen stencil set, (see figure 6 below)

Figure 6. An open stencil set.

You can open more than one stencil set at a time and you will get a stack of palette tabs build up, as in figure 7 below:

Figure 7. Several open stencil sets.

To create a new node with from a stencil item, just drag the stencil set item from its stencil palette and drop onto a map. A new node will be created with the properties defined by the stencil set item dragged. Figure 8 shows a new node created from a stencil set item:

Figure 8.  A new node created from dragging over a stencil set item.

If the stencil dragged was a map or list node type, and had an associated Compendium template file, this file should have been loaded as the contents of the new node.

You can edit a stencil set item directly by double-clicking on the item in the stencil set palette. This will open a Stencil Set Item dialog with the details of that item to edit. When you save the item you will see the dialog for the Stencil set appear and when you save that, the Stencil management dialog, as usual. It simply provides a shortcut to opening all the appropriate dialogs directly. Figure 9 below shows a stencil set item being edited directly from the stencil set panel:

Figure 9. Editing a stencil set item from the open stencil set palette.