Defining Windows


This section provides the mandatory and optional for the following window resources:

  • Windows and Dialogs

  • Event Masks

The Resource Properties Index identifies and describes the optional properties for windows and dialogs.

Windows and Dialogs

Windows, also known as Forms or Top Level Windows, are the base GUI elements in which most other elements must reside. Windows usually have a title bar, and close, minimize, and maximize buttons on the title bar. Windows can contain child windows, controls, and menus, but nothing can contain a Window. A window can also serve as a dialog box.

The following lists the mandatory properties for windows and dialogs:

window resource-id"title"x, y, width, height

The following describes the window and dialog properties:

Property

Definition

Window

Identifies the resource as a window.

resource-id

Unique resource ID number that identifies the window in the resource file. It must be an integer between 1 and 32767.

"title"

Title of the window, contained in quotation marks.

x

Horizontal position of the upper-left corner of the window in current units.

y

Vertical position of the upper-left corner of the window in current units.

width

Width of the window in current units.

height

Height of the window in current units.

Current Units Settings

Setting the current units determines the unit type for a window and its contained controls and elements. This is set at the window level only.

Unit Type

Current Unit Setting

Pixels

currentunits 0

Characters

currentunits 1

Semicharacters

currentunits 2

Dialog Box Settings

Setting the following properties defines a window as a dialog box:

Alwaysontop,Dialogbehavior,Dialogborder,Gravity,Keyboardnavigation,Not Maximizable, and Not Sizable.

Event Masks

Event masks filter the events reported by the current window.

Event

Activation

Push Button

Check/Uncheck

Control Focus Gained/Lost

Edit Control Modify

Keypress

List Item Click

Menu Selection

Mouse Button Down

Mouse Button Up

Mouse Double-Click

Mouse Move

Notify

Right Mouse Button Down

Scrollbar Move

System Color Change

Tool Button Push

Window Close Box

Window Focus Gained/Lost

Window Resize