Using the JADE Skin Loader

The schema load operation replaces existing skin entities of the same name.

If you want to load skins into an environment only for the initial load or when there have been many changes made to a skin, use the JADE Skin Loader. (The Jade Skin Maintenance dialog enables you to load skins individually. For details, see "Defining and Maintaining JADE Skins at Run Time", in Chapter 2 of the JADE Runtime Application Guide.)

The Application class skinLoad method displays the common Browse for Folder dialog, which prompts you to specify the root directory in which the skin images are located.

The name of the root directory is used as the application name for the skin. Although you can load a partial set of skins, you must load the complete set of skins for a specific control, menu item, or form because any existing skins with the same name are deleted prior to loading in the new skins.

The skins are not loaded unless the skins directory has the specified structure. For details, see "Directory Structure Example for the Button Control" or "Directory Structure Example for the Combo Box Control", in the following subsections.

For details about creating an empty skin directory structure into which you can load your skin image files of a specified name in a selected root directory, see the Application class skinMakeDirectory method.

At the end of the load process, a validation phase logs details about the load. The file name is the skin name with a .log file suffix (for example, DemoSkin.log), and it is located in the root directory in which the skin images are located (for example, the DemoSkin directory). You should review this file, because it lists skins that have not been loaded into the system.

The skinLoad method loads images only. You must change other settings by using the Jade Skin Maintenance dialog after the load is complete.

The code shown in the following fragment invokes the skinLoad method from a Workspace.

app.skinLoad;

The following image shows the Jade Skin Maintenance dialog after the loading the Windows Broadbean skin.

The FormAdminMdi class zSetupSkinSelectMenu and mnuSkin_click methods in the ErewhonInvestmentsViewSchema schema, included in the erewhon subdirectory of the examples directory on the JADE release medium, provide an example of adding a skin for selection by users in runtime applications.