Futurebasic/Language/Reference/window statement

< Futurebasic < Language < Reference

WINDOW

Syntax

WINDOW [#]idExpr[,[title$][,[rect][,[type][,class]]]]

Description

Use this statement to do any of the following:

The parameters should be specified as follows. They are interpreted slightly differently depending on whether you are creating a new window or altering an existing one.

To Create a New Screen Window

Note: If you specify the window's (positive) ID number when you alter a window's characteristics, the window also becomes the current active window (unless its _keepInBack attribute is set). If you specify the negative of the window's ID number, the window becomes invisible.

Side Effects of Activating the Window

The WINDOW statement always makes the window active, unless you specify a negative idExpr, or you specified the _keepInBack attribute when you created the window. When you activate a window using the WINDOW statement, the following things also happen:

Side Effects of Making a Window Visible

If idExpr is the (positive) ID of a window that currently exists but is invisible, the WINDOW statement makes the window visible, and also generates a DIALOG event of type _wndRefresh. A _wndRefresh event is also generated when you create a new window visibly. (Note: There are also other kinds of actions which generate _wndRefresh events; see the DIALOG function for more information.)

Side Effects of Making a Window Invisible

If idExpr is negative, the window becomes invisible, and it becomes the current output window. If the window was previously active, it becomes inactive; if your program has other visible windows, one of them becomes the active window.

More about the type Parameter

The typeparameter is a positive or negative integer. The absolute value of type
determines the general appearance of the window and determines some special attributes
of it. The sign of type determines whether the window will be modal or non-modal. If
type is negative, the window will be modal, which means the user won't be able to
switch to a different window until the modal window is closed; if the user clicks in an
inactive window while a modal window is active, a beep is generated, but a _wndClick
event is notgenerated. typecan be expressed as follows:

[-](windowVariant [+attribute [+attribute ...]])

windowVariant can be any of the following:

<image was here

_doc (1)

Document window with room for scrollbars.

<image was here

Framed dialog window.

<image was here

_dialogPlain (3)


_dialogShadow (4)


_docNoGrow (5)


_dialogMovable (6)


_docZoom (9)

Plain dialog window.

Shadowed dialog window.


Document window with no grow box.


Movable dialog window.


Document window with zoom box and room for scrollbars.

<image was here

_docRound (17)

Rounded-corner window. Add 1 through 7 to this variant to increase the roundness of the corners.

<image was here

_WDEFbaseID (129)

Palette window with close box. You can add the constant _WDEFhasZoom (8) to this variant to give the window a zoom
<image was here _WDEFbaseID + _WDEFsideDrag (131) Sideways palette. You can add the constant _WDEFhasZoom (8) to this variant to give the window a zoom box.
176 through 191 These values are mapped to Appearance Manager window types 1984 through 1999.
192 through 255 These values are mapped to Appearance Manager window types 1024 through 1087.

The attribute can be any of the following (you can specify as many of these as apply): <image was here>

See Also

code> MINWINDOW; MAXWINDOW; SETZOOM; GET WINDOW; WINDOW CLOSE; WINDOW OUTPUT; WINDOW function; DIALOG function; code> AUTOCLIP;

This article is issued from Wikibooks. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.