## ATTRIBUTES

Many MNEMONICS causes the setting of attributes and modes that affect subsequent I/O to the PC3 driver. These attributes and modes fall into 3 catagories:
Global - affects all channels and all windows.
Channel - affects the current channel. OPEN(1)FID(0) would give you another set of these attributes for channel 1.
Window - affects the current Window only. Note that when a window is created the value of the current windows attributes are use to initialize the new window.

### Global MNEMONIC's

'MODE'
'SP'
'CP'
'WT'
'MWT'
'KL','KU'
The Bell Mode in the 'RB'
Also the Screen Edit settings

### Channel MNEMONIC's

'BE','EE'
'BG','EG'
'BI','EI'
'BO','EO'
'UC','LC'

### Window MNEMONIC's

'BB' or 'FS', 'EB' or 'FT'
'BR', 'ER'
'BU' or 'US', 'EU' or 'UT'
'GS','GE'
'SB','SF'
'PS','PE'
'ATTR'
'RGB'
'RGBX'
'BLACK'
'BLUE'
'GREEN'
'CYAN'
'RED'
'MAGENTA'
'YELLOW'
'WHITE'
'BACKGR'
'DEFAULT'

## @(col) - Position Cursor
@(col,row)

The single @ position use a space character to move the to right and a non-destructuve backspace to move left. If the cursor is being move off the SCREEN it appears on the right or bottom of the SCREEN.
NOTE:
All positioning is relative to the SCROLL area.

## ATTR - Set Atributes

Allows setting the Forgound,Reverse Video,Underline,Blink and Graphic Attributes.
PRINT 'ATTR'(X$) - where the HTA(X$(1,1)) is:
$01$ - Forground
$02$ - Reverse Video
$04$ - Underline
$08$ - Blink
$20$ - Graphic

## 'BACKGR' Background Color

The Next Color attribute will apply to the Background.

## 'BB' and 'EB' - Begin/End Blink
'FS' and 'FT' - Flash Start/Flash Terminate

The PC3 driver does not support a Blink. However you can assign a color (on a per window basis) vai:
PRINT 'BB'(R,G,B) - WHERE R,G,B represent 0->255 for the color intensity of Red,Green,Blue.

## 'BC' - Back Cursor

Non-Destuctive Move Left of the Cursor.

## 'BE' and 'EE' - Begin/End Echo

Sets/Resets the echo attribute. If the echo attribute is reset characters input from the keyboard are not echoed.

## 'BG' and 'EG' - Begin/End Error 29

Once the 'EG' is output no ERROR 29's will be generated for invalid MNEMONICS. The 'BG' restores the generation of ERROR 29's

## 'BI' and 'EI' - Begin/End Input Transparency

Once the 'BI' is output character codes are not anded against $7F$.

## 'BLACK' - Black

Next Character is printed in black.

## 'BLUE' - Blue

Next Character is printed in blue.

## 'BO' and 'EO' - Begin/End Output Transparency

Once a 'BO' has been output no MNEMONICS are detected except the 'EO' MNEMONIC.

## 'BOX' - Draw a Box

PRINT 'BOX'(col,row,cols,rows{,titlestr{,attribstr}}) - will draw a box at Column col and Row row of size cols*rows. If the title string is specified it will appear on the top line of the box. If the attribute string (MNEMONIC) is present it will be applied before printing the box.
EXAMPLE:
PRINT 'BOX'(10,5,40,10,"HELLO",'RED')

## 'BR' and 'ER' - Begin/End Reverse Video

Once a 'BR' cahracters are displayed in reverse mode.

## 'BS' - Back Space

Destuctive Move Left of the Cursor.

## 'BU' and 'EU' - Begin/End Character Underline
'US' and 'UT' - Underline Start/Terminate

Instead of underline you can assign a color (on a per window basis) vai:
PRINT 'BU'(R,G,B) - WHERE R,G,B represent 0->255 for the color intensity of Red,Green,Blue.

## 'CE' - Clear End of Screen

Clears all characters from the cursor to the end of the scroll area.

## 'CF' - Clear Foreground

Clears all foreground characters.

## 'CH' - Cursor Home

Moves the cursor to position 0,0 of the Scroll Area.

## 'CI' - Clear Input

Empties the input buffer (type ahead).

## 'CL' - Clear Line

Clears all characters from the cursor to the end of the line.

## 'CON' - Connection Change

PRINT 'CON'(c,d$), - changes connection to connection # c and places d$ in the input buffer.
PRINT 'CON', - is equivalent to PRINT 'CON'(-1,""),
The 'CON' mnemonic changes which connection has control of the Screen(PC3 Driver). The windows PC is always connections # -1 and other connection #'s come from the connections # of a successful CONNECT command.

### Normal CONNECT - CON usages

BASIC CONNECTION
In its simplest usage CONNECT - CON uses SM32.EXE under windows is used like a terminal emulator. In this case the windows startup program would contain:
1000 CONNECT 0,2,C$,D$; REM MAKE CONNECTION
1010 PRINT (0,ERR=.+1)'CON'(0,""),REM CONNECT SCREEN TO LINUX SERVER
1020 BYE
In this simple sceenario windows sm32 connects to linux, gives its screen to linux sm32 and then windows sm32 exits (bye) when linux sm32 ends.
HANDLING Remote Procedure Calls
Once linux sm32 is running and has control of the Screen it can execute a call under windows sm32 on the the PC using the RCALL command. The linux box must set the Remote Procedure Call Mode to 1 via the RPM function. This is a co-operative interface and the program running under windows does an LCALL in response to the RCALL. The Sequence is as follows:
windows sm32
1000 CONNECT 0,2,C$,D$;
1010 PRINT 'CON'(0,""),
the 'CON' will pend windows sm32 until it regains the Screen
linux sm32
2000 a=RPM(0,ind=1); rem make sure rpc mode enable
2010 RCALL "MYWINPROG",W$,"HELLO"
the rcall commands packages up the program name and variables into a single variable and the DOES equaivalent of:
print 'con'(-1,tmp$), this pends linux sm32 in the middle of the RCALL
windows sm32
1030 print 'EE','BI',
1040 READRECORD(0,siz=-50000,tim=0)A$
1050 if A$(1,1)<>"R" escape; REM this is not an RCALL ???
1060 LCALL A$
REM the LCALL knows how to unpackage the RCALL string and do a CALL
1070 PRINT 'CON'(0,A$),
this pends windows sm32
linux sm32
the pended RCALL command continues with the equivalent of:
readrecord(0,siz=-50000,tim=0)tmp$
the RCALL command retrieves any VALUE/RESULT variables from tmp$ (W$ above). The linux program continues its execution.

### Custom CONNECT - CON usages

The programmer is free to define some kind of custom communication. Consider the following:
windows sm32
1000 CONNECT 0,2,"box1.mydom.com:5001",D$; REM connection to box1
1000 CONNECT 1,2,"box2.mydom.com:5001",D$; REM connection to box2
1010 PRINT 'CON'(0,""),; REM let box1 have control
linux sm32 on box1
2000 PRINT 'CON'(1,""),; REM let box2 have control
linux sm32 on box2
3000 PRINT 'CON'(0,"0HELLO box1"),; REM SEND MESSAGE TO box1
linux sm32 on box1
2010 PRINT 'EE','BI',
2020 READRECORD(0,SIZ=-50000,TIM=0)A$
2030 IF A$(1,1) <> "0" ESCAPE; REM ALL MY MESSAGES START WITH 0
2040 A$=A$(2)
2050 IF A$<>"HELLO box1" ESCAPE; REM EXPECTING HELLO FROM box2
2060 PRINT 'CON'(0,"1HELLO box2"),; REM SEND MESSAGE TO box2
linux sm32 on box2
3010 PRINT 'EE','BI',
3020 READRECORD(0,SIZ=-50000,TIM=0)A$
3030 IF A$(1,1) <> "1" ESCAPE; REM ALL MY MESSAGES START WITH 1
3040 A$=A$(2)
3050 IF A$<>"HELLO box2" ESCAPE; REM EXPECTING HELLO FROM box1
NOTE:
It is recommended that custom interfaces avoid 'R' as the 1st character of their 'CON' strings so that the RCALL can be implimented as part of the custom interface. Also in a setup like the Custom above where you have 3 computers you can use the 'SRPC' mnemonic set which computer receives control when an RCALL is executed. The 'SRPC' mnemonic can also be used to swap the master/slave relation on Normal connection. That is linux sm32 sets it self up as an RPC server does a 'SRPC'(0) to make it the receiver of RCALLS and does a PRINT 'CON'(-1,"") to return control to windows sm32. Now RCALL's executed under windows will run under linux.

## 'CP' - Compressed Print

Switches to the font specified by CP on the Fonts property page.
NOTE:
Same as 'MODE'("CP")

## 'CR' - Carriage Return

Move cursor to position 0 on the current line.

## 'CS' - Clear Scroll Area

Clears all characters from scroll area.

## 'CU' - Clear Unprotected

Clears all foreground charaacters from the cursor to the end of the window. Equivalent to: PRINT 'PS','CE','PE',

## 'CURSOR' - Cursor Mode

'CURSOR'("ON") - causes cursor to be displayed.
'CURSOR'("OFF") - causes the cursor to be hidden.
'CURSOR'("INS") - causes the cursor to be a blinking block.
'CURSOR'("REP") - causes the cursor to be a blinking underline.

## 'CYAN' - Cyan

Next Character is printed in Cyan.

## 'DC' - Delete Character

Deletes the character at the cursor, shifting all the characters to the right of the cursor one position left and inserting a space in the last character in the row.

## 'DEFAULT' Set Default

This makes the current Attributes and colors the default
PRINT 'BACKGR','RED','WHITE','DEFAULT','CS', - set the scroll area to white on red.

## 'DN' - Down Cursor

Moves the cursor down one line.

## 'DROP' - Drop Window

'DROP'(x) - drops the window # x from the list of active windows
'DROP'("ACCOUNTING") - drops the window named ACCOUNTING from the active window list. The window must have been created with a name see 'WINDOW'
If the current window is being dropped it is the same as a 'POP'

## 'EL' and 'FL' - Edit/Function Key Load

The 'EL' anf 'FL' are follow by a command string. The 1st byte of the string is the command and following bytes if any are paramters.So they are always used as follows:
PRINT 'FL',C$ where C$ is the command string.
The functions keys and edit keys are defined on the KEYS property page and are number 0->x.
C$(1,1)="0" - reset key to its default C$(2,1)=CHR(x) where x is the key #
C$(1,1)="1" - reset all keys to their default
C$(1,1)="2" - load key C$(2,1)=CHR(x) where x is the key #, C$(3,1)=chr(len(T$) C$=C$(1,3)+T$ where T$ is the text to load.
C$(1,1)="3" - load multiple C$(2,1)=CHR(k) where k is number of keys to load, C$(3) is a repeat of CHR(x) where x is key number + CHR(LEN(t$)) + t$ where t$ is the text for key x.
C$(1,1)="4" - returns key string C$(2,1)=char(x) where x is key number the input buffer receives the 1 byte text len followed by the text
C$(1,1)="5" - returns all key text. The input buffer receives 1 byte ASC of which is the number of keys, for each key 1 byte ASC of which is the key #, 1 byte ASC of which is len of text followed by the text
C$(1,1)="6" - returns the label of a specified key C$(1,2)=CHR(x) where x is key #. The input buffer receive the same as 4
C$(1,1)="7" - returns all labels. The input buffer receive the same as 5
C$(1,1)="8" - return the text as if the user had pressed the specified key. C$(2,1)=chr(x) wher x is the key number
C$(1,1)="9" - returns the contained text C$(2,1)=chr(len(t$)) C$=C$(1,2)+t$. t$ is place in the input buffer as if it had been typed in.

## 'ES' - Print Escape Character

Sends $1B$ to screen ??.

## 'GOTO' - Change Window

PRINT 'GOTO'(x) - makes window # x the current window.
PRINT 'GOTO'("MYWIN") - makes the window named MYWIN the current window.

## 'GREEN' - Green

Next Character is printed in Green.

## 'GS' and 'GE' - Graphics Start/End

Once a 'GS' has been send to PC3 the characters 0,1,2,3,4,5,6,7,8,9,: are replaced by line drawing characters. Where:
0 - is a Horizontal line
1 - is a Vertical line
2 - is a upper left corner
3 - is a upper right corner
4 - is a lower left corner
5 - is a lower right corner
6 - is a connect to right
7 - is a connect to left
8 - is a connect to top
9 - is a connect to bottom
: - is a center connect

## 'GWIN' - Graphics Window Control

`PRINT 'GWIN'("CASCADE")`
The main window will cascade its 2 child windows.
`PRINT 'GWIN'("MAXIMIZE")`
The main window will maximize its currently active child window.
`PRINT 'GWIN'("WEB")`
The main window will make its Web View child the currently active window.
`PRINT 'GWIN'("CONSOLE")`
The main window will make its Console View child the currently active window.
`PRINT 'GWIN'("STATUSON")` The main window display the status line see 'STATUS'
`PRINT 'GWIN'("STATUSOFF")` The main window will hide the status line.
`READ 'EE','GWIN'("WINDOW"),W$,'BE'
Returns a comma delimitted string of the form:
"view,win_x,win_y,win_width,win_height,wa_x,wa_y,wa_width,wa_height"
where:
view="CONSOLE" - console view is current view and is maximized
view="console" - console view is current view but is not maximized
view="WEB" - web view is current view and is maximized
view="web" - web view is current view but is not maximized
win_x,win_y=Main Windows current upper left position in pixels
win_width=Main Windows width in pixels
win_height=Main Windows height in pixels
wa_x,wa_y=Screens Work Area upper left position in pixels
wa_width=Screens Work Area width
wa_height=Screens Work Area height
The work area is the portion of the screen not obscured by the system taskbar or by application desktop toolbars.`

## 'IC' - Insert Character

Inserts a space at the cursor position pushing all characters to the right. The last character in the line is lost.

## 'LAUNCH' - Launch a Windows Program

PRINT 'LAUNCH'("notepad.exe","C:\",0,0) will launch notepad.exe.
The 1st string is the executable program.
The 2nd string is the start dir for the program.
The 3rd parameter is the Priority (1=high,0=normal,-1=low).
The 4th parameter is window size(1=maximize, 0=default , -1 - minimize).

## 'KL' and 'KU' - Lock/Unlock Keyboard

If the keyboard is locked and a READ command is executed an error 65 is generated and the keyboard is unlocked.

## 'LC' and 'UC' - Lower/Upper Case

Once a 'UC' is received all KEYBOARD input is translated to upper case. Once a 'LC' is receive both upper and lower case characters are accepted from the keyboard.

## 'LD' - Line Delete

Deletes the line under the cursor scrolling all lower line up and inserting a blank line at the bottom of the scroll area.

## 'LF' - Line Feed

Move the cursor down 1 line and positions it in column 0.

## 'LI' - Line Insert

Insert a blank line under the cursor scrolling all lower line down. The line at the bottom of the scroll area is lost.

## 'MAGENTA' - Magenta

Next Character is printed in Magenta.

## 'MENU' - Make Menus

The 'MENU' mnemonic gives the basic programmer the ability to maintain named menu's
The 1st parameter to 'MENU' is the command. All commands have at least 2 more parameters.
The 2nd parameter is the the view name either "WEB" or "CONSOLE". Indicating which view owns the menu you are accessing.
The 3rd parameter is the menu name - only the 1st 8 characters are used. The menu name "" always exit and is the empty menu that SM32 begins with.
If required the 4th parameter is the position string to specify the position of the item or sub menu.
If required the 5th parameter is sub menu/item information:
for a sub menu "menu,menu name" eg. "menu,&File" for a menu item "item,ID#,item name" eg. "item,34000,E&xit"
For items a 6th and 7th parameter can be specified:
6th is the message that appears in the status line if the mouse is over this item - this is "" if not specified
7th is an interger flag bit 1 = checked bit 2 = disabled:

        0=enabled
        1=checked and enabled
        2=disabled
        3=checked and disabled  ???

"CREATE"
`PRINT 'MENU'("CREATE","CONSOLE","MYMENU")`
Deletes "MYMENU" if it exists then Creates an empty menu named "MYMENU".
"DELETE"
`PRINT 'MENU'("DELETE","CONSOLE","MYMENU")`
Delete the menu "MYMENU" - all its sub menus and items. If the position field is specified, only that Item or SubMenu is deleted.
"SHOW"
`PRINT 'MENU'("SHOW","CONSOLE","MYMENU")`
Makes "MYMENU" the currently displayed menu in the CONSOLE view
"APPEND"
`PRINT 'MENU'("APPEND","CONSOLE","MYMENU","","menu,&File")`
Adds a submenu named File to MYMENU
`PRINT 'MENU'("APPEND","CONSOLE","MYMENU","0","item,34000,E&xit","Exit this Program")`
appends an item to the 1st sub menu
`PRINT 'MENU'("APPEND","CONSOLE","MYMENU","0","separator")`
appends a separator line.
"INSERT"
`PRINT 'MENU'("INSERT","CONSOLE","MYMENU","0,0","item,34001,&Open","Open a File")`
inserts an item before the 1st item in the first sub menu
`PRINT 'MENU'("INSERT","CONSOLE","MYMENU","1,3,4","item,8002,&Save")`
inserts an item before the 5th item in the sub menu that is the 4th element(it must be a sub menu) of the 2nd sub menu in MYMENU
"MODIFY"
`PRINT 'MENU'("MODIFY","CONSOLE","MYMEU","0,1","item,34000,E&xit","Exit This Program",2)`
changes the Exit item to disable and grayed condition
"SETFLAG"
`PRINT 'MENU'("SETFLAG","CONSOLE","MYMENU","","34000","New Status Message",1)`
changes the Message displayed in the status line and checks the menu item that has an id of 34000 SETFLAG is similar to MODIFY but it changes the 6th and 7th parameters based on id number not posiotion, the position string is ignored. If 6th parameter(the status line message) is "" it is not changed

## 'MESSAGEBOX' - Message Box

PRINT 'MESSAGEBOX'(T$,M$,O$), - Display a Windows Message Box and wait for user input.
T$ is the message box title.
M$ is the message box message
O$ is a 3 byte option string
The Message Box mnemonic pushes a single digit (0->6) followed by CR into the input buffer to indicate the name of the button used to terminate the Message Box.
O$(1,1)="0" - The message box contains three push buttons: Abort, Retry, and Ignore.
O$(1,1)="1" - The message box contains one push button: OK. This is the default if O$=""
O$(1,1)="2" - The message box contains two push buttons: OK and Cancel.
O$(1,1)="3" - The message box contains two push buttons: Retry and Cancel.
O$(1,1)="4" - The message box contains two push buttons: Yes and No.
O$(1,1)="5" - The message box contains three push buttons: Yes, No, and Cancel.
O$(2,1)=" " or LEN(O$) < 2 - No icon symbol appears in box.
O$(2,1)="0" - An exclamation-point icon appears in the message box.
O$(2,1)="1" - An icon consisting of a lowercase letter i in a circle appears in the message box.
O$(2,1)="2" - A question-mark icon appears in the message box.
O$(2,1)="3" - A stop-sign icon appears in the message box.
O$(3,1)=" " or LEN(O$) < 3 - The first button is the default button.
O$(3,1)="0" - The first button is the default button.
O$(3,1)="1" - The second button is the default button.
O$(3,1)="2" - The third button is the default button.
Return Values are: "0" - Abort button was selected.
"1" - Cancel button was selected.
"2" - Ignore button was selected.
"3" - No button was selected.
"4" - OK button was selected.
"5" - Retry button was selected.
"6" - Yes button was selected.
EXAMPLE:
1000 READ 'EE','MESSAGEBOX'("This is the Title","Yes or No Make up your mind?","420"),a$,'be', 1010 if a$="6" THEN PRINT "Yes" ELSE PRINT "no"

## 'MODE' - Change Font

PRINT 'MODE'(N$) - change to font N$. N$ must be defined on property page Fonts.

## 'MOVE' - Move Window

PRINT 'MOVE'(col,row) - the current window will be moved to col,row relative to 0,0 of the Screen.

## 'MOVEWINDOW' - Move Main Window

`PRINT 'MOVEWINDOW'(X,Y,W,H)`
will move the MainWindow to position(pixels) X,Y with a width of W and a height of H
.

## 'MWT' - Windows Title

PRINT 'MWT'(T$) - Sets the Main Windows Window Title to T$
If you want a single title (without the - [something]) you can:
PRINT 'MWT'(T$),'WT'("")

## 'PS' and 'PE' - Protect Start/End

Once a 'PS' is sent some of the clearing function like 'CL' and 'CE' act more like 'CF' in that they only clear the foreground characters.

## 'PLAYSOUND'(pathname) - Play Sound

Uses the Windows API function PlaySound to play the wave file specified by pathname.

    EXAMPLE:
    100 PRINT 'PLAYSOUND'("C:\WAVEFILES\GOODMORNING.WAV"),

NOTES:
No SETDISK directories or PREFIXES are NOT searched. The sound file must be in the current directory of SM32.EXE or be a pathname.

## 'POP' - Pop Window

PRINT 'POP', - destroys the current window and returns to the previous window.

## 'PRM' - Load Prompt

'PRM'(P$) Loads screenedit prompt string. This is an alternative to using PRM=.

    100 READ (0,PRM="YES")A$
    100 READ (0)'PRM'("YES"),A$

are functionally equivalent statements.

## 'PUSH' - Push Window

PRINT 'PUSH', - creates a new window identical to the current window and then make it the current window.

## 'RB' - Ring Bell
'RB'(bell mode)

If the bell mode is specified it sets the mode of subsequent 'RB''s that do not have the bell mode specified. The bell mode is a value from 0->6 which generate the following sounds:

    bell mode   sound from                         windows api call
       0        PC speaker                         Beep(100,100)
       1        Sound Card(SystemDefault)          MessageBeep(MB_OK)
       2        Sound Card(SystemAsterisk)         MessageBeep(MB_ICONASTERISK)
       3        Sound Card(SystemExclamation)      MessageBeep(MB_ICONEXCLAMATION)
       4        Sound Card(SystemHand)             MessageBeep(MB_ICONHAND)
       5        Sound Card(SystemQuestion)         MessageBeep(MB_ICONQUESTION)
       6        either                             MessageBeep(-1);
    EXAMPLE:
    100 PRINT 'RB'(1),; REM SET RB TO SystemDefault sound
    110 PRINT 'RB',; REM PLAY SystemDefault sound

NOTES:
The System sounds can be changed in the control panel. Also SEE 'PLAYSOUND'

## 'RC' - Read Cursor

Places the cursor position in the input buffer in the form of:
CHR(32+LINE)+CHR(32+COL)+$0D$
EXAMPLE:
100 READ 'EE','RC',A$,'BE',
110 PRINT "The cursor was at Line:",asc(a$(1,1))-32," and Column:",asc(a$(2,1))-32
Note:
The position is Screen relative NOT scroll area relative.

## 'RED' - Red

Next Character is printed in Red.

## 'RGB' - Set Color

PRINT 'RGB'(R,G,B) - set the color based on the intensity of the red,blue and green. Each of R,G and B are in the range from 0->3 allowing 64 different colors.
PRINT 'RGB'(C$) - in this form C$(1,2) is a 16 bit number with each 2 bit field (0->3) being the color as the follow masks display:
$0003$ - foreground blue
$000C$ - forground green
$0030$ - forground red
$0300$ - background blue
$0C00$ - background green
$3000$ - background red

## 'RGBX' - Set Color

PRINT 'RGBX'(R,G,B) - set the color based on the intensity of the red,blue and green. Each of R,G and B are in the range from 0->255.
print 'RGB'(1,2,3) is equiavlent to
print 'RGBX'(85,170,255)
Note: The FIN function and the read screen mnemonics only return 2 bits for each color that is : int(color/85) for an RGBX color.

## 'RL' - Read Line

Read the screen data from the start of the current line to the end of the current line. A CR is added to the screen data.

## 'RM' - Reset Mode

Resets all modes to their default

## 'RP' - Read Page

Read the screen data from the the current cursor position to the end of the scroll area. A CR is added to the screen data.

## 'RS' - ReDraw Screen

If the screen has been modified outside the PC3 driver this will restore it.

## 'RT' - Move Cursor Right

Non-destructive move right..

## 'SB' and 'SF' - Set Low/High Intensity

PRINT 'SB'(x) - where x > 0 and x < 100 sets the percentage of intensity that background is compared to foreground. The default is 75.
PRINT 'SB'(r,g,b) where r,g,b 0->255 for each or the RGB colors. This version set the color to be used for displaying characters that are in background. Note 'SB'(x) and 'SB'(r,g,b) do not set background mode.
PRINT 'SB' - sets background mode. All subsequent characters will be displayed in lower intensity (or the color selected by 'SB'(r,g,b).
PRINT 'SF' - sets foreground mode. All subsequent characters will be displayed in high intensity also called foreground.
Background characters are protected by the 'PS' and 'CF' from being cleared.

## 'SCROLL' - Set Scroll Area

PRINT 'SCROLL'(col,row,cols,rows) - defines a scroll area within a window.
PRINT 'SCROLL'("ON") - enables scrolling
PRINT 'SCROLL'("OFF") - disables scrolling
PRINT 'SCROLL'("RESET") - set the scroll area to the size of the window. If there was a title box around the previous scroll area it will now be contained in the new max size scroll area.

## 'SP' - Standard Print

Switches to the font specified by SP on the Fonts property page.
NOTE:
Same as 'MODE'("SP")

## 'SRPC' - Set RPC Connections #

PRINT 'SRPC'(x), - subsequent RCALL's will be made to connection # x. Connections # -1 is the windows PC.

## 'STATUS' - Load status line

`PRINT 'STATUS'(A$)`

## 'SW' - Show Window

PRINT 'SW'(X$) Where X$=
"HIDE" to hide the window
"SHOW" to display the hidden window
"RESTORE" to restore the minimized window
"MINIMIZE" to minimize a window
"MAXIMIZE" to maximize a window

    EXAMPLE:
    10 BEGIN
    20 STRING "TESTFILE.TXT",-1
    30 OPEN (1)"TESTFILE.TXT"
    40 FOR I=1 TO 50
    50 WRITE(1)"DATA "+STR(I)+$0D$
    60 NEXT I
    65 CLOSE(1)
    70 PRINT 'LAUNCH'("NOTEPAD.EXE TESTFILE.TXT",DIR(-1),0,0)
    75 REM TCB(8) WILL CONTAIN PROCESS ID
    80 PRINT 'SW'("MINIMIZE"),REM MINIMIZE WHILE NOTEPAD IS RUNNING
    85 REM WHILE EXIT CODE FOR NOTEDPAD IS STILL_ACTIVE (259)
    90 WHILE 259=GEC(TCB(8))
    100 PRINT "WAITING FOR NOTEPAD TO END"
    110 WAIT 1
    120 WEND
    130 PRINT 'CS','SW'("RESTORE")

NOTE:
If you PRINT 'SW'("HIDE") while in console mode you will have to use the task manager to terminate SM32.

## 'SWAP' - Swap Windows

Swaps to the previous window.

## 'SYSMENU' - Add Launch Program to Sysmenu

PRINT 'SYSMENU'("NotePad","notepad.exe","C:\",0,0) will add an entry under Propeties in the System Menu called Notepad.
The 1st string is the name that appears in the System Menu.
The 2nd string is the executable program.
The 3rd string is the start dir for the program.
The 4th parameter is the Priority (1=high,0=normal,-1=low).
The 5th parameter is window size(1=maximize, 0=default , -1 - minimize).
If you had the Manual tree for the manual you are now reading in C:\Manual then a more usefull example would be:
PRINT 'SYSMENU'("Manual","C:\Program Files\Internet Explorer\IExplore.exe C:\Manual\sm32.html","",0,0)
Then you could bring up this manual from the System Menu of your sm32 screen.
NOTE:
There is no way to remove an entry. It is expected that in your startup program you might add a couple of entries of programs you want easy access to.

## 'TR' - Terminal Read

Places all the characters in the scroll area into the input buffer and adds a CR.

## 'UP' - Cursor UP

Move the cursor to the line above. If on line 0 move to the last line of the Scroll area.

## 'VT' - Vertical Tab

Move the cursor to the line above. If on line 0 move to the last line of the Scroll area.

## 'WHITE' - White

Next Character is printed in White.

## 'WINDOW' - Create a New Window

PRINT 'WINDOW'(col,row,cols,rows{,titlestr{,attribstr{,namestr}}}) - will create a new window at Column col and Row row of size cols*rows. If the title string is specified and is <> "" a BOX (see 'BOX') will be drawn at Column col and Row row of size cols*rows and the title will appear on the top line of the box. If the attribute string (MNEMONIC) is present and <> "" it will be applied before printing the box. If the namestr is present the NAME (see 'GOTO' and 'DROP') will be associated with the window. A scroll area (see 'SCROLL') will be established either inside the Box if there was a title or the entire window.
EXAMPLE:
PRINT 'WINDOW'(10,5,40,10,"HELLO",'RED',"HELLOWINDOW")
The 'WINDOW' mnemonic can also be used to get a list of active windows.
EXAMPLE:
10 PRINT 'EE','CI',WINDOW'("LIST"),
20 READRECORD(0,SIZ=1)A$;REM GET # OF WINDOWS
30 READRECORD(0,SIZ=ASC(A$))L$
40 PRINT 'BE'
ASC of each character in L$ will be the window number of an active window. The order is from the current window down to window 0. The same order windows would appear if you kept 'POP'ing the current window down to window 0.

## 'WRAP' - Enable/Disable Line Wrapping

PRINT 'WRAP'("ON") - characters will wrap from the end of 1 line to the next
PRINT 'WRAP'("OFF") - characters printed past the end of the line will be lost.

## 'WT' - Windows Title

PRINT 'WT'(T$) - Sets the Windows Window Title to T$

## 'YELLOW' - Yellow

Next Character is printed in Yellow.