WINDOW Mnemonic - Create a Window (Terminal Device)

 

BBj-Specific Information

For this topic's original documentation, see the WINDOW Mnemonic - Create a Window (Terminal Device).

Using a Number in place of the Title Parameter

If the fifth parameter (titlestr) is numeric, the window will be created without a title or a border, but the 'WINDOW' mnemonic will continue to process any embedded mnemonics that follow after.

print 'window'(10,5,45,20,0,'red')

The above statement creates a new window with red as the foreground color. The window will have no border or title. In this case, the parameter 0 is used in place of the title string. The value of the parameter has no effect or meaning; it is simply a placeholder to allow embedded mnemonics to be processed.

Contents of New Character Windows

In BBj, new character windows created with the 'WINDOW' mnemonic do not automatically inherit the contents of windows directly beneath them. Each new character window in BBj is empty, and the BBx technique of embedding a 'CS' mnemonic inside the 'WINDOW' mnemonic to clear the window is therefore unnecessary. This obsolete technique, while still valid syntax, will cause additional processing and slightly impair performance.

The new 'CAPTURE ' mnemonic can be used in concert with the 'WINDOW' mnemonic to produce a character window containing the same information displayed by windows beneath it. The following statement will create a new window (without a title or border) that will inherit the contents of any windows below it.

print 'window'(5,5,50,30,0,'capture')

For more information, see CAPTURE Mnemonic - Capture Underlying Text (Terminal Device).

Creating a Maximized Window

The string "MAX" can be used in place of the col, row, cols, rows parameters to create a new character window that is the full size of the SysConsole/SysWindow frame or the terminal emulator frame if running TermConsole inside a terminal emulator.

print 'window'("max","test",'blue')

The above statement creates a new character window with its upper left corner in column 0 and row 0. It will have as many columns and rows as the current size of the SysConsole/SysWindow or TermConsole. The window has the title "test" and will be drawn with a border and blue as the foreground color.

print 'window'("max",0,'capture')

The above statement makes use of all three new 'WINDOW' mnemonic features to create a new window that fills the entire SysConsole/SysWindow or TermConsole frame, has no title or border, and inherits everything from all other character windows below it.

Note that the "max" option of the 'WINDOW' mnemonic does not cause the SysConsole or SysWindow or terminal emulator window to be maximized to fill the entire screen display (use the MAXIMIZE mnemonic for the SysConsole/SysWindow). It creates a character window which matches the current size, whatever that size may be.

See Also

Mnemonics - Alphabetical Listing

Mnemonics - Group Listing