|
To change the default Layout, follow these steps once the template is loaded into the Layout draw area, as described in the topic Invoking Templates,
Select the panel for which you would like to set/change the layout.
Right-click on the panel. This brings up a popup menu
From the pop-up menu, select the menu item Layouts. This brings up a sub pop-up menu. listing all the possible layouts. Each "Layout" menu item has a "RadioButton" associated with it, with one selected at any point of time
Select the RadioButton corresponding to the Layout you would like to set on the panel.
Save the layout setting for the selected template, using the "File->Save" or "File->Save As" option
When you choose the Save or Save As option, the file name in which the stylesheet (corresponding to the applied layout) is prompted. Please note that the layout settings are saved as a stylesheet with ".tss" extension.
Specify the file name, wherein the current layout setting is saved, in the template as a stylesheet with the specified name.
The stylesheet is saved under <Web NMS Home>/stylesheets directory. Whenever you invoke the template via the Application Client, Applet Client or using OpenTemplate.bat/.sh file, this stylesheet is applied for the template.
Illustration
The following image shows the template "ATM_Virtual_Connection.xml" being displayed in the Layout draw area, with the default layout set to "GridBagLayout".
|
|
Note: When you need to add new components to the panel or rearrange the existing components in a form, while applying any of the layouts to the desired template,
|
Preview of the selected Layout
Select the template to preview.
Choose the Preview->Full Preview or Preview->Partial Preview menu option, from the main menu bar. For a detailed description of these menus with illustrations, please refer to the topic "Working with Menus and Toolbar options".
Select the panel to set the layout properties for the components inside the template.
Right-click on the panel. This brings up a pop-up menu.
Select the Layout Properties menu item. This invokes a dialog, which is based on the current Layout setting for the template.
Change the required properties and choose the Apply option, for each property being changed.
Finally, once you are done with all the property changes, choose the OK option.
Resizing is not allowed for all the layouts, i.e, only in some specific layouts, components are allowed to be resized. The following are the layouts in which the resizing is allowed :
Null Layout
Border Layout
Flow Layout
|
|
Warning:
<Stage label="First" > <Form id="1" > </Form> <Form id="2" > </Form> </Stage>
In the above case, components present in Form "1" and Form "2" can be merged. But same is not possible, if there are any tags between Form "1" and Form"2".
|
|