Generic Dialog Framework

The Generic Dialog Framework is an easy way to generate your own dialogs by adjusting a set of prefabricated panels.

Dialog Panels

There are 6 total dialog panels available, 3 of which are unique applications, whereas the remaining 3 are themselves preadjusted forms of one dialog panel. Each dialog panel is adjusted with a member function of the Dialog Framework class. Style sheets can be used for all dialog panels. A block of style sheet options geared specifically to the Generic Dialog Framework can be found in the stylesheet.css file.

All dialog panels adjust to the text entered in them. The panels will appear in the middle of the screen, with the rest of the screen overlaid by a transparent background.

To use the Dialog Framework class and the dialog panels, the library "DialogFramework.ctl" has to be added. Viz.:

#uses "classes/DialogFramework"

Simple dialog

The simple dialog is the most basic application of the dialog panels. It shows a text and can be changed with the function general().

gdf general pnl

Information dialog

The information dialog is a variation of the general dialog panel. Different default values are set, which add an icon to the header and change the background. The information dialog is adapted with the function information().

gdf information pnl

Warning dialog

The warning dialog is another variation of the general dialog panel. The default values are set to generate a warning with icon and attention-grabbing header, as well as specifying an "acknowledge" button. The warning() function is used to adjust this dialog.

gdf warning pnl

Question dialog

The question dialog is the last direct variation of the general dialog panel. This dialog adds a second button and different header style. It is edited with question().

gdf question pnl

MultiLanguage dialog

The multilanguage dialog loads an editor for langStrings with buttons to cancel, copy, delete or save. This dialog can be adapted with the multiLanguages() function.

gdf multiLanguages pnl

Input dialog

The input dialog adds a text field to edit the displayed value and buttons to cancel or save this change. This dialog is adjusted with the input() function.

gdf input pnl

Example

The detailed examples can be found with the "dialogFramework.pnl" which is located in the folderwincc_oa_path/Examples_3.21/panels/examples/dialogFramework.

Figure 1. dialogFramework - Panel
dialogFramework - Panel

This panel either shows each available dialog panel separately, or shows a short demonstration of all dialog panels. The stylesheet options specifically set for the dialog framework can be applied via the checkbox.

Figure 2. general dialog panel with the different stylesheet options
general dialog panel with the different stylesheet options