[Local Variables]
Name=PrefsTree
Title=Advanced Preferences
Caption=1st level node
Help=Online;%Root%Help\PrefsTree.html
[Navigation Controls]
onEnter=
onNext=
Help=
[Image 4200]
Type=Image
Name=prefstree.bmp
Value=
Start_x=0
Start_y=0
Width=425
Height=56
[Widget 4201]
Type=GlobalText
Name=Text4201
Value=Browse this tree to find other preferences that you want to customize. Double-click to edit.
Start_x=0
Start_y=32
Width=400
Height=30
[Widget 4202]
Type=PrefsTree
Name=AdvancedPrefs
Attrib=MetaPrefs.xml
Value=
Start_x=0
Start_y=45
Width=405
Height=181
Above is the section which defines the PrefsTree widget. The Name is important if you want to hook up the control to some buttons, as in our example. The Attrib
specifies the name of the prefs XML file. This file belongs in the root
with the .exe files. Once edited, a copy of the file gets saved in the working
config directory. This is where install builder picks up its values. The
Value is not used. |
[Widget 4203]
Type=Button
Name=Button4203
Value=Open
Start_x=0
Start_y=232
Width=40
Height=14
onCommand=OpenPrefTreeItem(AdvancedPrefs)
Above is the section defining the "Open" button. When pressed, it calls OpenPrefTreeItem()
for the PrefsTree widget named in the parameter. If a pref is selected,
a dialog is open which allows the user to edit that text. If a group is selected,
then that group is expanded or collapsed, depending on its current state.
You can also use the right-button menu to open a pref for editing. |
[Widget 4204]
Type=Button
Name=Button4204
Value=Find Pref
Start_x=50
Start_y=232
Width=40
Height=14
onCommand=FindPrefTreeItem(AdvancedPrefs)
Above is the section defining the "Find Pref" button. When pressed, it calls FindPrefTreeItem() for the PrefsTree widget named in the parameter. This function opens a find
dialog which is used to find any text associated with a pref. It searches
the pref name, its description, and its files for the text. You can also
use the right-button menu to open the find dialog. |
[Widget 4205]
Type=Button
Name=Button4205
Value=Find Next
Start_x=100
Start_y=232
Width=40
Height=14
onCommand=FindNextPrefTreeItem(AdvancedPrefs)
Above is the section to define the "Find Next" button. When pressed, if calls FindNextPefTreeItem()
for the PrefsTree widget named in the parameter. This function selects the
next pref which matches the last text search. It opens a find dialog if "Find Pref" was never used. |
[Widget 4206]
Type=Button
Name=Button4206
Value=Add Pref
Start_x=150
Start_y=232
Width=40
Height=14
onCommand=AddPrefTreeItem(AdvancedPrefs)
Above is the section to define the "Add Pref" button. It calls AddPrefTreeItem() for the PrefsTree widget named in the parameter. This function opens the add dialog which prompts the user for the name and description of the new pref. It then open the edit dialog which allows the user to set the value of the new pref. |