Category : Miscellaneous Language Source Code
Archive   : ADA-LRM3.ZIP
Filename : LR9VT.SRC

 
Output of file : LR9VT.SRC contained in archive : ADA-LRM3.ZIP

-- Package specification SMG is a "data-only" code interface of the
-- SMG$ routines from VMS V4.7 VAX Ada V1.4
--
-- Initial received and tested on 6/10/88
-- Originally written by Bryan Jervey, Norfolk State University
-- ReDTEA Project (United State Army)
--------------------------------------------------------------------------
--
-- Revisions history and notes:
--
-- 8/28/88
-- 1) Minor Corrections.
-- 2) Corrections in data types, parameter modes.
-- 3) Added all parameter objects to routines missing in previous
-- version.
-- 4) Included separate routines (except for functions CURSOR_COLUMN
-- and CURSOR_ROW) to include STATUS : out COND_VALUE as first
-- parameter.
-- 5) Deleted the following routines in conformance with VMS V5.0
-- changes: ALLOW_ESCAPE, PUT_WITH_SCROLL,
-- PUT_VIRTUAL_DISPLAY_ENCODED. (Have not added new SMG routines
-- unique to VMS V5.0);
-- 6) Since Ada does not support default values for parameter
-- items with mode "out", created additional routines with
-- named extensions " _1 " that mirror the standard routines
-- but without optional "out" mode parameter objects.
--
--------------------------------------------------------------------------
-- For specific explaination of parameter objects in the following
-- routines type
-- $ HELP RTL SMG$ SMG$routine_name
--
-------------------------------------------------------------------------

with STARLET;
with SYSTEM;
with CONDITION_HANDLING;

package SMG is

subtype ADDRESS is SYSTEM.ADDRESS;
subtype AST_PROCEDURE is SYSTEM.AST_HANDLER;
subtype BOOLEAN is STANDARD.BOOLEAN;
subtype BYTE_SIGNED is STANDARD.SHORT_SHORT_INTEGER;
subtype BYTE_UNSIGNED is SYSTEM.UNSIGNED_BYTE;
subtype CHAR_STRING is STRING;
subtype CONTEXT_TYPE is STARLET.CONTEXT_TYPE;
subtype COND_VALUE is CONDITION_HANDLING.COND_VALUE_TYPE;
subtype LONGWORD_SIGNED is INTEGER;
subtype LONGWORD_UNSIGNED is SYSTEM.UNSIGNED_LONGWORD;
subtype MASK_LONGWORD is SYSTEM.UNSIGNED_LONGWORD;
subtype NULL_ARG is SYSTEM.UNSIGNED_LONGWORD;
subtype USER_ARG is STARLET.USER_ARG_TYPE;
subtype VECTOR_BYTE_UNSIGNED is SYSTEM.UNSIGNED_BYTE;
subtype WORD_SIGNED is SHORT_INTEGER;
subtype WORD_UNSIGNED is SYSTEM.UNSIGNED_WORD;

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- adds a keypad key definition to a table of key definitions.
--

procedure ADD_KEY_DEF --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ATTRIBUTES : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER;
EQUIV_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
STATE_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

procedure ADD_KEY_DEF --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ATTRIBUTES : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER;
EQUIV_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
STATE_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

pragma INTERFACE(RTL, ADD_KEY_DEF);

pragma IMPORT_PROCEDURE(ADD_KEY_DEF, "SMG$ADD_KEY_DEF", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING, MASK_LONGWORD, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(ADD_KEY_DEF, "SMG$ADD_KEY_DEF", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, MASK_LONGWORD, CHAR_STRING,
CHAR_STRING));


--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- saves, or batches, all output to a virtual display until a matching
-- call to END_DISPLAY_UPDATE is encountered.
--

procedure BEGIN_DISPLAY_UPDATE --
(DISPLAY_ID : in LONGWORD_UNSIGNED);

procedure BEGIN_DISPLAY_UPDATE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, BEGIN_DISPLAY_UPDATE);

pragma IMPORT_PROCEDURE(BEGIN_DISPLAY_UPDATE, "SMG$BEGIN_DISPLAY_UPDATE", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(BEGIN_DISPLAY_UPDATE, "SMG$BEGIN_DISPLAY_UPDATE", (
COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- saves, or batches, all output to a pasteboard until a matching call
-- to END_PASTEBOARD_DATE is encountered.
--

procedure BEGIN_PASTEBOARD_UPDATE --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure BEGIN_PASTEBOARD_UPDATE --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, BEGIN_PASTEBOARD_UPDATE);

pragma IMPORT_PROCEDURE(BEGIN_PASTEBOARD_UPDATE, "SMG$BEGIN_PASTEBOARD_UPDATE"
, (LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(BEGIN_PASTEBOARD_UPDATE, "SMG$BEGIN_PASTEBOARD_UPDATE"
, (COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- immediately cancels any read-in-progress that was issued by
-- READ_COMPOSED_LINE, READ_KEYSTROKE, READ_STRING or READ_VERIFY
--

procedure CANCEL_INPUT --
(KEYBOARD_ID : in LONGWORD_UNSIGNED);

procedure CANCEL_INPUT --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, CANCEL_INPUT);

pragma IMPORT_PROCEDURE(CANCEL_INPUT, "SMG$CANCEL_INPUT", (LONGWORD_UNSIGNED))
;

pragma IMPORT_PROCEDURE(CANCEL_INPUT, "SMG$CANCEL_INPUT", (COND_VALUE,
LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
---------------------------------------------------------------------------
-- changes the width, height and background color associated with a
-- pasteboard.
--

procedure CHANGE_PBD_CHARACTERISTICS --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
DESIRED_WIDTH : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RESULTING_WIDTH : out LONGWORD_SIGNED;
DESIRED_HEIGHT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RESULTING_HEIGHT : out LONGWORD_SIGNED;
DESIRED_BACKGROUND_COLOR : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER;
RESULTING_BACKGROUND_COLOR : out LONGWORD_UNSIGNED);

procedure CHANGE_PBD_CHARACTERISTICS --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
DESIRED_WIDTH : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RESULTING_WIDTH : out LONGWORD_SIGNED;
DESIRED_HEIGHT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RESULTING_HEIGHT : out LONGWORD_SIGNED;
DESIRED_BACKGROUND_COLOR : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER;
RESULTING_BACKGROUND_COLOR : out LONGWORD_UNSIGNED);

procedure CHANGE_PBD_CHARACTERISTICS_1 --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
DESIRED_WIDTH : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DESIRED_HEIGHT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DESIRED_BACKGROUND_COLOR : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER);

procedure CHANGE_PBD_CHARACTERISTICS_1 --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
DESIRED_WIDTH : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DESIRED_HEIGHT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DESIRED_BACKGROUND_COLOR : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, CHANGE_PBD_CHARACTERISTICS);

pragma INTERFACE(RTL, CHANGE_PBD_CHARACTERISTICS_1);

pragma IMPORT_PROCEDURE(CHANGE_PBD_CHARACTERISTICS,
"SMG$CHANGE_PBD_CHARACTERISTICS", (LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CHANGE_PBD_CHARACTERISTICS,
"SMG$CHANGE_PBD_CHARACTERISTICS", (COND_VALUE, LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CHANGE_PBD_CHARACTERISTICS_1,
"SMG$CHANGE_PBD_CHARACTERISTICS", (LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CHANGE_PBD_CHARACTERISTICS_1,
"SMG$CHANGE_PBD_CHARACTERISTICS", (COND_VALUE, LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- changes the video attributes for all or part of a virtual display.
--

procedure CHANGE_RENDITION --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
START_ROW, START_COL, ROWS, COLUMNS : in LONGWORD_SIGNED;
RENDITION_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure CHANGE_RENDITION --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
START_ROW, START_COL, ROWS, COLUMNS : in LONGWORD_SIGNED;
RENDITION_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

pragma INTERFACE(RTL, CHANGE_RENDITION);

pragma IMPORT_PROCEDURE(CHANGE_RENDITION, "SMG$CHANGE_RENDITION", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(CHANGE_RENDITION, "SMG$CHANGE_RENDITION", (COND_VALUE
, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- lets you change the dimensions, border, and video attributes of a
-- virtual display.
--

procedure CHANGE_VIRTUAL_DISPLAY --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
ROWS, COLUMNS : in LONGWORD_SIGNED;
DISPLAY_ATTRIBUTES, VIDEO_ATTRIBUTES : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure CHANGE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
ROWS, COLUMNS : in LONGWORD_SIGNED;
DISPLAY_ATTRIBUTES, VIDEO_ATTRIBUTES : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, CHANGE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(CHANGE_VIRTUAL_DISPLAY, "SMG$CHANGE_VIRTUAL_DISPLAY",
(LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, MASK_LONGWORD,
MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CHANGE_VIRTUAL_DISPLAY, "SMG$CHANGE_VIRTUAL_DISPLAY",
(COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- checks to see whether a virtual display is covered by another
-- virtual display.
--

procedure CHECK_FOR_OCCLUSION --
(DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
OCCLUSION_STATE : out LONGWORD_SIGNED);

procedure CHECK_FOR_OCCLUSION --
(STATUS : out COND_VALUE;
DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
OCCLUSION_STATE : out LONGWORD_SIGNED);

pragma INTERFACE(RTL, CHECK_FOR_OCCLUSION);

pragma IMPORT_PROCEDURE(CHECK_FOR_OCCLUSION, "SMG$CHECK_FOR_OCCLUSION", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(CHECK_FOR_OCCLUSION, "SMG$CHECK_FOR_OCCLUSION", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- controls buffering, minimal updating, whether the screen is cleared
-- when the pasteboard is deleted, and whether tab characters are
-- used for screen formatting.
--

procedure CONTROL_MODE --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
NEW_MODE : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'NULL_PARAMETER;
OLD_MODE : out LONGWORD_UNSIGNED);

procedure CONTROL_MODE --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
NEW_MODE : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'NULL_PARAMETER;
OLD_MODE : out LONGWORD_UNSIGNED);

procedure CONTROL_MODE_1 --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
NEW_MODE : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure CONTROL_MODE_1 --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
NEW_MODE : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'NULL_PARAMETER);


pragma INTERFACE(RTL, CONTROL_MODE);

pragma INTERFACE(RTL, CONTROL_MODE_1);

pragma IMPORT_PROCEDURE(CONTROL_MODE, "SMG$CONTROL_MODE", (LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CONTROL_MODE, "SMG$CONTROL_MODE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CONTROL_MODE_1, "SMG$CONTROL_MODE", (LONGWORD_UNSIGNED
, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CONTROL_MODE_1, "SMG$CONTROL_MODE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- creates a copy of an existing virtual display and assigns to it
-- a new virtual display number.
--

procedure COPY_VIRTUAL_DISPLAY --
(CURR_DISPLAY_ID : in LONGWORD_UNSIGNED;
NEW_DISPLAY_ID : out LONGWORD_UNSIGNED);

procedure COPY_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
CURR_DISPLAY_ID : in LONGWORD_UNSIGNED;
NEW_DISPLAY_ID : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, COPY_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(COPY_VIRTUAL_DISPLAY, "SMG$COPY_VIRTUAL_DISPLAY", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(COPY_VIRTUAL_DISPLAY, "SMG$COPY_VIRTUAL_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- creates a table for key definitions.
--

procedure CREATE_KEY_TABLE --
(NEW_KEY_TABLE_ID : out LONGWORD_UNSIGNED);

procedure CREATE_KEY_TABLE --
(STATUS : out COND_VALUE;
NEW_KEY_TABLE_ID : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, CREATE_KEY_TABLE);

pragma IMPORT_PROCEDURE(CREATE_KEY_TABLE, "SMG$CREATE_KEY_TABLE", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CREATE_KEY_TABLE, "SMG$CREATE_KEY_TABLE", (COND_VALUE
, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- creates a pasteboard and returns its assigned pasteboard-id.
--

procedure CREATE_PASTEBOARD --
(NEW_PASTEBOARD_ID : out LONGWORD_UNSIGNED;
OUTPUT_DEVICE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
PB_ROWS, PB_COLUMNS : out LONGWORD_SIGNED;
PRESERVE_SCREEN_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

procedure CREATE_PASTEBOARD --
(STATUS : out COND_VALUE;
NEW_PASTEBOARD_ID : out LONGWORD_UNSIGNED;
OUTPUT_DEVICE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
PB_ROWS, PB_COLUMNS : out LONGWORD_SIGNED;
PRESERVE_SCREEN_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

procedure CREATE_PASTEBOARD_1 --
(NEW_PASTEBOARD_ID : out LONGWORD_UNSIGNED;
OUTPUT_DEVICE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
PRESERVE_SCREEN_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

procedure CREATE_PASTEBOARD_1 --
(STATUS : out COND_VALUE;
NEW_PASTEBOARD_ID : out LONGWORD_UNSIGNED;
OUTPUT_DEVICE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
PRESERVE_SCREEN_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

pragma INTERFACE(RTL, CREATE_PASTEBOARD);

pragma INTERFACE(RTL, CREATE_PASTEBOARD_1);

pragma IMPORT_PROCEDURE(CREATE_PASTEBOARD, "SMG$CREATE_PASTEBOARD", (
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD));

pragma IMPORT_PROCEDURE(CREATE_PASTEBOARD, "SMG$CREATE_PASTEBOARD", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED
, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(CREATE_PASTEBOARD_1, "SMG$CREATE_PASTEBOARD", (
LONGWORD_UNSIGNED, CHAR_STRING, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(CREATE_PASTEBOARD_1, "SMG$CREATE_PASTEBOARD", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- creates a virtual display and returns its assigned display id.
--

procedure CREATE_VIRTUAL_DISPLAY --
(NUM_ROWS, NUM_COLUMNS : in LONGWORD_SIGNED;
NEW_DISPLAY_ID : out LONGWORD_UNSIGNED;
DISPLAY_ATTRIBUTES : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER;
VIDEO_ATTRIBUTES : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER);

procedure CREATE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
NUM_ROWS, NUM_COLUMNS : in LONGWORD_SIGNED;
NEW_DISPLAY_ID : out LONGWORD_UNSIGNED;
DISPLAY_ATTRIBUTES : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER;
VIDEO_ATTRIBUTES : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, CREATE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(CREATE_VIRTUAL_DISPLAY, "SMG$CREATE_VIRTUAL_DISPLAY",
(LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED,
MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(CREATE_VIRTUAL_DISPLAY, "SMG$CREATE_VIRTUAL_DISPLAY",
(COND_VALUE, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- creates a virtual keyboard and returns its assigned keyboard-id.
--

procedure CREATE_VIRTUAL_KEYBOARD --
(NEW_KEYBOARD_ID : out LONGWORD_UNSIGNED;
FILESPEC, DEFAULT_FILESPEC : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
RESULTANT_FILESPEC : out CHAR_STRING;
RECALL_SIZE : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER
);

procedure CREATE_VIRTUAL_KEYBOARD --
(STATUS : out COND_VALUE;
NEW_KEYBOARD_ID : out LONGWORD_UNSIGNED;
FILESPEC, DEFAULT_FILESPEC : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
RESULTANT_FILESPEC : out CHAR_STRING;
RECALL_SIZE : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER
);

procedure CREATE_VIRTUAL_KEYBOARD_1 --
(NEW_KEYBOARD_ID : out LONGWORD_UNSIGNED;
FILESPEC, DEFAULT_FILESPEC : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
RECALL_SIZE : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER
);

procedure CREATE_VIRTUAL_KEYBOARD_1 --
(STATUS : out COND_VALUE;
NEW_KEYBOARD_ID : out LONGWORD_UNSIGNED;
FILESPEC, DEFAULT_FILESPEC : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
RECALL_SIZE : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER
);

pragma INTERFACE(RTL, CREATE_VIRTUAL_KEYBOARD);

pragma INTERFACE(RTL, CREATE_VIRTUAL_KEYBOARD_1);

pragma IMPORT_PROCEDURE(CREATE_VIRTUAL_KEYBOARD, "SMG$CREATE_VIRTUAL_KEYBOARD"
, (LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, CHAR_STRING, BYTE_UNSIGNED))
;

pragma IMPORT_PROCEDURE(CREATE_VIRTUAL_KEYBOARD, "SMG$CREATE_VIRTUAL_KEYBOARD"
, (COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, CHAR_STRING,
BYTE_UNSIGNED));

pragma IMPORT_PROCEDURE(CREATE_VIRTUAL_KEYBOARD_1,
"SMG$CREATE_VIRTUAL_KEYBOARD", (LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING
, BYTE_UNSIGNED));

pragma IMPORT_PROCEDURE(CREATE_VIRTUAL_KEYBOARD_1,
"SMG$CREATE_VIRTUAL_KEYBOARD", (COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING,
CHAR_STRING, BYTE_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns the virtual cursor's current column position in a specified
-- virtual display.
--

function CURSOR_COLUMN --
(DISPLAY_ID : in LONGWORD_UNSIGNED) return LONGWORD_SIGNED;

pragma INTERFACE(RTL, CURSOR_COLUMN);

pragma IMPORT_FUNCTION(CURSOR_COLUMN, "SMG$CURSOR_COLUMN");

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns the virtual cursor's current row position in a specified
-- virtual display.
--

function CURSOR_ROW --
(DISPLAY_ID : in LONGWORD_UNSIGNED) return LONGWORD_SIGNED;

pragma INTERFACE(RTL, CURSOR_ROW);

pragma IMPORT_FUNCTION(CURSOR_ROW, "SMG$CURSOR_ROW");

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- perform the DEFINE/KEY command you provide.
--

procedure DEFINE_KEY --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
COMMAND_LINE : in CHAR_STRING);

procedure DEFINE_KEY --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
COMMAND_LINE : in CHAR_STRING);

pragma INTERFACE(RTL, DEFINE_KEY);

pragma IMPORT_PROCEDURE(DEFINE_KEY, "SMG$DEFINE_KEY", (LONGWORD_UNSIGNED,
CHAR_STRING));

pragma IMPORT_PROCEDURE(DEFINE_KEY, "SMG$DEFINE_KEY", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- terminates access to TERMTABLE.EXE and frees the associated virtual
-- address space.
--

procedure DEL_TERM_TABLE;

procedure DEL_TERM_TABLE --
(STATUS : out COND_VALUE);

pragma INTERFACE(RTL, DEL_TERM_TABLE);

pragma IMPORT_PROCEDURE(DEL_TERM_TABLE, "SMG$DEL_TERM_TABLE", (null));

pragma IMPORT_PROCEDURE(DEL_TERM_TABLE, "SMG$DEL_TERM_TABLE", (COND_VALUE));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- deletes characters in a virtual display.
--

procedure DELETE_CHARS --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
NUM_CHARS, ROWS, COLUMNS : in LONGWORD_SIGNED);

procedure DELETE_CHARS --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
NUM_CHARS, ROWS, COLUMNS : in LONGWORD_SIGNED);

pragma INTERFACE(RTL, DELETE_CHARS);

pragma IMPORT_PROCEDURE(DELETE_CHARS, "SMG$DELETE_CHARS", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(DELETE_CHARS, "SMG$DELETE_CHARS", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- deletes a key definition from a specified table of key definitions.
--

procedure DELETE_KEY_DEF --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

procedure DELETE_KEY_DEF --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

pragma INTERFACE(RTL, DELETE_KEY_DEF);

pragma IMPORT_PROCEDURE(DELETE_KEY_DEF, "SMG$DELETE_KEY_DEF", (
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(DELETE_KEY_DEF, "SMG$DELETE_KEY_DEF", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- deletes lines from a virtual display.
--

procedure DELETE_LINE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
START_LINE : in LONGWORD_SIGNED;
NUMBER_LINES : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

procedure DELETE_LINE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
START_LINE : in LONGWORD_SIGNED;
NUMBER_LINES : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, DELETE_LINE);

pragma IMPORT_PROCEDURE(DELETE_LINE, "SMG$DELETE_LINE", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(DELETE_LINE, "SMG$DELETE_LINE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- flushes all output to the display, terminates all use for the specified
-- pasteboard, and deallocates all resources associated with the
-- pasteboard.
--

procedure DELETE_PASTEBOARD --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CLEAR_SCREEN_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

procedure DELETE_PASTEBOARD --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CLEAR_SCREEN_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

pragma INTERFACE(RTL, DELETE_PASTEBOARD);

pragma IMPORT_PROCEDURE(DELETE_PASTEBOARD, "SMG$DELETE_PASTEBOARD", (
LONGWORD_UNSIGNED, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(DELETE_PASTEBOARD, "SMG$DELETE_PASTEBOARD", (
COND_VALUE, LONGWORD_UNSIGNED, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- deletes a virtual display and removes it from any pasteboard on which
-- it is pasted. It also deallocates any buffer space associated with
-- the virtual display.
--

procedure DELETE_VIRTUAL_DISPLAY --
(DISPLAY_ID : in LONGWORD_UNSIGNED);

procedure DELETE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, DELETE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(DELETE_VIRTUAL_DISPLAY, "SMG$DELETE_VIRTUAL_DISPLAY",
(LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(DELETE_VIRTUAL_DISPLAY, "SMG$DELETE_VIRTUAL_DISPLAY",
(COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- deletes a virtual keyboard. Any terminal attributes specified when
-- the keyboard was created are reset to their previous values and the
-- keypad mode (numeric or application) is reset to its original state.
-- In addition, the channel is deassigned and, if the virtual keyboard
-- was a file, the file is closed.
--

procedure DELETE_VIRTUAL_KEYBOARD --
(KEYBOARD_ID : in LONGWORD_UNSIGNED);

procedure DELETE_VIRTUAL_KEYBOARD --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, DELETE_VIRTUAL_KEYBOARD);

pragma IMPORT_PROCEDURE(DELETE_VIRTUAL_KEYBOARD, "SMG$DELETE_VIRTUAL_KEYBOARD"
, (LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(DELETE_VIRTUAL_KEYBOARD, "SMG$DELETE_VIRTUAL_KEYBOARD"
, (COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- disables trapping of broadcast messages for the specified terminal.
--

procedure DISABLE_BROADCAST_TRAPPING --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure DISABLE_BROADCAST_TRAPPING --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, DISABLE_BROADCAST_TRAPPING);

pragma IMPORT_PROCEDURE(DISABLE_BROADCAST_TRAPPING,
"SMG$DISABLE_BROADCAST_TRAPPING", (LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(DISABLE_BROADCAST_TRAPPING,
"SMG$DISABLE_BROADCAST_TRAPPING", (COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- disables the invocation of AST routines for unsolicited input.
--

procedure DISABLE_UNSOLICITED_INPUT --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure DISABLE_UNSOLICITED_INPUT --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, DISABLE_UNSOLICITED_INPUT);

pragma IMPORT_PROCEDURE(DISABLE_UNSOLICITED_INPUT,
"SMG$DISABLE_UNSOLICITED_INPUT", (LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(DISABLE_UNSOLICITED_INPUT,
"SMG$DISABLE_UNSOLICITED_INPUT", (COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- draws a horizontal or vertical line.
--

procedure DRAW_LINE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
START_ROW, START_COLUMN, END_ROW, END_COLUMN : in LONGWORD_SIGNED;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER);

procedure DRAW_LINE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
START_ROW, START_COLUMN, END_ROW, END_COLUMN : in LONGWORD_SIGNED;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER);

pragma INTERFACE(RTL, DRAW_LINE);

pragma IMPORT_PROCEDURE(DRAW_LINE, "SMG$DRAW_LINE", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(DRAW_LINE, "SMG$DRAW_LINE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- draws a rectangle in a virtual display, given the position of the
-- of the upper left-hand corner and the lower right-hand corner. The
-- characters used to draw the lines making up the rectangle depend on
-- the type of terminal. The virtual cursor position does not change.
--

procedure DRAW_RECTANGLE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TOP_LEFT_ROW, TOP_LEFT_COLUMN : in LONGWORD_SIGNED;
BOTTOM_RIGHT_ROW, BOTTOM_RIGHT_COLUMN : in LONGWORD_SIGNED;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure DRAW_RECTANGLE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TOP_LEFT_ROW, TOP_LEFT_COLUMN : in LONGWORD_SIGNED;
BOTTOM_RIGHT_ROW, BOTTOM_RIGHT_COLUMN : in LONGWORD_SIGNED;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

pragma INTERFACE(RTL, DRAW_RECTANGLE);

pragma IMPORT_PROCEDURE(DRAW_RECTANGLE, "SMG$DRAW_RECTANGLE", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(DRAW_RECTANGLE, "SMG$DRAW_RECTANGLE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- detects unsolicited input and calls an AST routine in response.
--

procedure ENABLE_UNSOLICITED_INPUT --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
AST_ROUTINE : in AST_PROCEDURE;
AST_ARGUMENT : in USER_ARG := USER_ARG'NULL_PARAMETER);

procedure ENABLE_UNSOLICITED_INPUT --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
AST_ROUTINE : in AST_PROCEDURE;
AST_ARGUMENT : in USER_ARG := USER_ARG'NULL_PARAMETER);

pragma INTERFACE(RTL, ENABLE_UNSOLICITED_INPUT);

pragma IMPORT_PROCEDURE(ENABLE_UNSOLICITED_INPUT,
"SMG$ENABLE_UNSOLICITED_INPUT", (LONGWORD_UNSIGNED, AST_PROCEDURE, USER_ARG)
);


pragma IMPORT_PROCEDURE(ENABLE_UNSOLICITED_INPUT,
"SMG$ENABLE_UNSOLICITED_INPUT", (COND_VALUE, LONGWORD_UNSIGNED,
AST_PROCEDURE, USER_ARG));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- ends update batching for a virtual display.
--

procedure END_DISPLAY_UPDATE --
(DISPLAY_ID : in LONGWORD_UNSIGNED);

procedure END_DISPLAY_UPDATE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, END_DISPLAY_UPDATE);

pragma IMPORT_PROCEDURE(END_DISPLAY_UPDATE, "SMG$END_DISPLAY_UPDATE", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(END_DISPLAY_UPDATE, "SMG$END_DISPLAY_UPDATE", (
COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- ends update batching for a pasteboard.
--

procedure END_PASTEBOARD_UPDATE --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure END_PASTEBOARD_UPDATE --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, END_PASTEBOARD_UPDATE);

pragma IMPORT_PROCEDURE(END_PASTEBOARD_UPDATE, "SMG$END_PASTEBOARD_UPDATE", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(END_PASTEBOARD_UPDATE, "SMG$END_PASTEBOARD_UPDATE", (
COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- erases characters in a virtual display by replacing them with blanks.
--

procedure ERASE_CHARS --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
NUMBER_OF_CHARS, ROW_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED);

procedure ERASE_CHARS --
(STATUS : out COND_VALUE;

DISPLAY_ID : in LONGWORD_UNSIGNED;
NUMBER_OF_CHARS, ROW_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED);

pragma INTERFACE(RTL, ERASE_CHARS);

pragma IMPORT_PROCEDURE(ERASE_CHARS, "SMG$ERASE_CHARS", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(ERASE_CHARS, "SMG$ERASE_CHARS", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- causes all or part of a virtual display to be erased by replacing
-- text characters with blanks. If omitted, the starting position
-- default to 1,1. The ending positions default to the last row or
-- column in the display. thus, to erase the entire virtual, you
-- need only pass the display-id. The cursor position is the first
-- free position after the erased portion. If the entire is erased,
-- the virtual cursor is left at position 1,1.
--

procedure ERASE_DISPLAY --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
START_ROW, START_COLUMN, END_ROW, END_COLUMN : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER);

procedure ERASE_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
START_ROW, START_COLUMN, END_ROW, END_COLUMN : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, ERASE_DISPLAY);

pragma IMPORT_PROCEDURE(ERASE_DISPLAY, "SMG$ERASE_DISPLAY", (LONGWORD_UNSIGNED
, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(ERASE_DISPLAY, "SMG$ERASE_DISPLAY", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- erases a line from the specified starting porition to the end of
-- the line. If you do not specify a starting position, SMG$ERASE_LINE
-- erases text form the current virtual cursor position to the end of
-- the line. The virtual cursor remains at the first blank position
-- after the erased text.
--

procedure ERASE_LINE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

procedure ERASE_LINE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, ERASE_LINE);

pragma IMPORT_PROCEDURE(ERASE_LINE, "SMG$ERASE_LINE", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(ERASE_LINE, "SMG$ERASE_LINE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- erases the specified pasteboard. The physical cursor is left at
-- position 1,1. If there are any virtual displays pasted to the
-- pasteboard, they will be redrawn the next time the Screen Management
-- Facility is used to output the pasteboard.
--

procedure ERASE_PASTEBOARD --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure ERASE_PASTEBOARD --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, ERASE_PASTEBOARD);

pragma IMPORT_PROCEDURE(ERASE_PASTEBOARD, "SMG$ERASE_PASTEBOARD", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(ERASE_PASTEBOARD, "SMG$ERASE_PASTEBOARD", (COND_VALUE
, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- determines which virtual display contains the physical cursor on
-- a specified pasteboard, and returns the virtual display's inden-
-- tifier. SMG$FIND_CURSOR_DISPLAY returns the display-id of the
-- most recently pasted virtual display which contains the physical
-- cursor. If no virtual display contains the physical cursor, this
-- routine returns a 0, which is an invalid display identifier.
--

procedure FIND_CURSOR_DISPLAY --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
RETURNED_DISPLAY_ID : out LONGWORD_UNSIGNED);

procedure FIND_CURSOR_DISPLAY --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
RETURNED_DISPLAY_ID : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, FIND_CURSOR_DISPLAY);

pragma IMPORT_PROCEDURE(FIND_CURSOR_DISPLAY, "SMG$FIND_CURSOR_DISPLAY", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(FIND_CURSOR_DISPLAY, "SMG$FIND_CURSOR_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- causes all buffered output to be sent to the terminal immediately.
-- The calling program would normally call this routine just before
-- performing some cpu-intensive calculations, or whenever the terminal
-- screen must be up-to-date.
--

procedure FLUSH_BUFFER --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure FLUSH_BUFFER --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, FLUSH_BUFFER);

pragma IMPORT_PROCEDURE(FLUSH_BUFFER, "SMG$FLUSH_BUFFER", (LONGWORD_UNSIGNED))
;

pragma IMPORT_PROCEDURE(FLUSH_BUFFER, "SMG$FLUSH_BUFFER", (COND_VALUE,
LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- determines whether a message has been broadcast to the pasteboard
-- and returns the message.
--

procedure GET_BROADCAST_MESSAGE --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
MESSAGE : out CHAR_STRING;
MESSAGE_LENGTH : out WORD_SIGNED);

procedure GET_BROADCAST_MESSAGE --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
MESSAGE : out CHAR_STRING;
MESSAGE_LENGTH : out WORD_SIGNED);

pragma INTERFACE(RTL, GET_BROADCAST_MESSAGE);

pragma IMPORT_PROCEDURE(GET_BROADCAST_MESSAGE, "SMG$GET_BROADCAST_MESSAGE", (
LONGWORD_UNSIGNED, CHAR_STRING, WORD_SIGNED));

pragma IMPORT_PROCEDURE(GET_BROADCAST_MESSAGE, "SMG$GET_BROADCAST_MESSAGE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, WORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns the character at the current physical cursor postion.
--

procedure GET_CHAR_AT_PHYSICAL_CURSOR --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CHARACTER : out BYTE_UNSIGNED);

procedure GET_CHAR_AT_PHYSICAL_CURSOR --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CHARACTER : out BYTE_UNSIGNED);

pragma INTERFACE(RTL, GET_CHAR_AT_PHYSICAL_CURSOR);

pragma IMPORT_PROCEDURE(GET_CHAR_AT_PHYSICAL_CURSOR,
"SMG$GET_CHAR_AT_PHYSICAL_CURSOR", (LONGWORD_UNSIGNED, BYTE_UNSIGNED));

pragma IMPORT_PROCEDURE(GET_CHAR_AT_PHYSICAL_CURSOR,
"SMG$GET_CHAR_AT_PHYSICAL_CURSOR", (COND_VALUE, LONGWORD_UNSIGNED,
BYTE_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns attributes associated with a virtual display.
--

procedure GET_DISPLAY_ATTR --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
HEIGHT, WIDTH : out LONGWORD_SIGNED;
DISPLAY_ATTRIBUTES, VIDEO_ATTRIBUTES : out LONGWORD_UNSIGNED;
CHAR_SET : in LONGWORD_UNSIGNED);

procedure GET_DISPLAY_ATTR --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
HEIGHT, WIDTH : out LONGWORD_SIGNED;
DISPLAY_ATTRIBUTES, VIDEO_ATTRIBUTES : out LONGWORD_UNSIGNED;
CHAR_SET : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, GET_DISPLAY_ATTR);

pragma IMPORT_PROCEDURE(GET_DISPLAY_ATTR, "SMG$GET_DISPLAY_ATTR", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(GET_DISPLAY_ATTR, "SMG$GET_DISPLAY_ATTR", (COND_VALUE
, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns the key definition for a specified key.
--

procedure GET_KEY_DEF --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ATTRIBUTES : out MASK_LONGWORD;
EQUIV_STRING : out CHAR_STRING;
STATE_STRING : out CHAR_STRING);

procedure GET_KEY_DEF --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ATTRIBUTES : out MASK_LONGWORD;
EQUIV_STRING : out CHAR_STRING;
STATE_STRING : out CHAR_STRING);

procedure GET_KEY_DEF --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

procedure GET_KEY_DEF --
(STATYS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
KEY_NAME : in CHAR_STRING;
IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

pragma INTERFACE(RTL, GET_KEY_DEF);

pragma IMPORT_PROCEDURE(GET_KEY_DEF, "SMG$GET_KEY_DEF", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING, MASK_LONGWORD, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(GET_KEY_DEF, "SMG$GET_KEY_DEF", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, MASK_LONGWORD, CHAR_STRING,
CHAR_STRING));

pragma IMPORT_PROCEDURE(GET_KEY_DEF, "SMG$GET_KEY_DEF", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(GET_KEY_DEF, "SMG$GET_KEY_DEF", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- gets information about a virtual keyboard and leaves it in a
-- user-supplied area: the keyboard information table(KIT).
--

procedure GET_KEYBOARD_ATTRIBUTES --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
P_KIT, P_KIT_SIZE : out LONGWORD_UNSIGNED);

procedure GET_KEYBOARD_ATTRIBUTES --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
P_KIT, P_KIT_SIZE : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, GET_KEYBOARD_ATTRIBUTES);

pragma IMPORT_PROCEDURE(GET_KEYBOARD_ATTRIBUTES, "SMG$GET_KEYBOARD_ATTRIBUTES"
, (LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(GET_KEYBOARD_ATTRIBUTES, "SMG$GET_KEYBOARD_ATTRIBUTES"
, (COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- accesses TERMTABLE.EXE and returns the numeric sequence that causes
-- a terminal to perform a specified operation.
--

procedure GET_NUMERIC_DATA --
(TERMTABLE_ADDRESS : in LONGWORD_UNSIGNED;
REQUEST_CODE : in LONGWORD_SIGNED;
BUFFER_ADDRESS : out LONGWORD_UNSIGNED);

procedure GET_NUMERIC_DATA --
(STATUS : out COND_VALUE;
TERMTABLE_ADDRESS : in LONGWORD_UNSIGNED;
REQUEST_CODE : in LONGWORD_SIGNED;
BUFFER_ADDRESS : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, GET_NUMERIC_DATA);

pragma IMPORT_PROCEDURE(GET_NUMERIC_DATA, "SMG$GET_NUMERIC_DATA", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(GET_NUMERIC_DATA, "SMG$GET_NUMERIC_DATA", (COND_VALUE
, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- provided that the specified virtual display is currently pasted,
-- the row and column of the pasting are returned.
--

procedure GET_PASTING_INFO --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTED_FLAG : out BOOLEAN;
PASTEBOARD_ROW, PASTEBOARD_COL : out LONGWORD_SIGNED);

procedure GET_PASTING_INFO --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTED_FLAG : out BOOLEAN;
PASTEBOARD_ROW, PASTEBOARD_COL : out LONGWORD_SIGNED);

procedure GET_PASTING_INFO_1 --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTED_FLAG : out BOOLEAN);

procedure GET_PASTING_INFO_1 --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTED_FLAG : out BOOLEAN);

pragma INTERFACE(RTL, GET_PASTING_INFO);

pragma INTERFACE(RTL, GET_PASTING_INFO_1);

pragma IMPORT_PROCEDURE(GET_PASTING_INFO, "SMG$GET_PASTING_INFO", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, BOOLEAN, LONGWORD_SIGNED,
LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(GET_PASTING_INFO, "SMG$GET_PASTING_INFO", (COND_VALUE
, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, BOOLEAN, LONGWORD_SIGNED,
LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(GET_PASTING_INFO_1, "SMG$GET_PASTING_INFO", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, BOOLEAN));

pragma IMPORT_PROCEDURE(GET_PASTING_INFO_1, "SMG$GET_PASTING_INFO", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, BOOLEAN));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- gets pasteboard attributes and stores them in the pasteboard
-- information table.
--

procedure GET_PASTEBOARD_ATTRIBUTES --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PB_INFO_TABLE : out VECTOR_BYTE_UNSIGNED;
PB_INFO_TABLE_SIZE : out LONGWORD_UNSIGNED);

procedure GET_PASTEBOARD_ATTRIBUTES --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PB_INFO_TABLE : out VECTOR_BYTE_UNSIGNED;
PB_INFO_TABLE_SIZE : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, GET_PASTEBOARD_ATTRIBUTES);

pragma IMPORT_PROCEDURE(GET_PASTEBOARD_ATTRIBUTES,
"SMG$GET_PASTEBOARD_ATTRIBUTES", (LONGWORD_UNSIGNED, VECTOR_BYTE_UNSIGNED,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(GET_PASTEBOARD_ATTRIBUTES,
"SMG$GET_PASTEBOARD_ATTRIBUTES", (COND_VALUE, LONGWORD_UNSIGNED,
VECTOR_BYTE_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- accesses TERMTABLE.EXE and returns the character sequence that
-- causes a terminal to perform a specified operation.
--

procedure GET_TERM_DATA --
(TERMTABLE_ADDRESS, REQUEST_CODE : in LONGWORD_SIGNED;
MAX_BUFFER_LENGTH : in LONGWORD_SIGNED;
RETURN_LENGTH : out LONGWORD_SIGNED;
BUFFER_ADDRESS : out LONGWORD_UNSIGNED;
INPUT_ARGUEMENT_VECTOR : in ADDRESS := ADDRESS'NULL_PARAMETER);

procedure GET_TERM_DATA --
(STATUS : out COND_VALUE;
TERMTABLE_ADDRESS, REQUEST_CODE : in LONGWORD_SIGNED;
MAX_BUFFER_LENGTH : in LONGWORD_SIGNED;
RETURN_LENGTH : out LONGWORD_SIGNED;
BUFFER_ADDRESS : out LONGWORD_UNSIGNED;
INPUT_ARGUEMENT_VECTOR : in ADDRESS := ADDRESS'NULL_PARAMETER);

pragma INTERFACE(RTL, GET_TERM_DATA);

pragma IMPORT_PROCEDURE(GET_TERM_DATA, "SMG$GET_TERM_DATA", (LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED,
ADDRESS));

pragma IMPORT_PROCEDURE(GET_TERM_DATA, "SMG$GET_TERM_DATA", (COND_VALUE,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_UNSIGNED, ADDRESS));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- moves the virtual cursor to the specified corner of a virtual display.
--

procedure HOME_CURSOR --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
POSITION : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure HOME_CURSOR --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
POSITION : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, HOME_CURSOR);

pragma IMPORT_PROCEDURE(HOME_CURSOR, "SMG$HOME_CURSOR", (LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(HOME_CURSOR, "SMG$HOME_CURSOR", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- initializes the TERMTABLE database for the terminal named, so that
-- subsequent calls to SMT$GET_TERM_DATA cna extract information and
-- command strings for that terminal.
--

procedure INIT_TERM_TABLE --
(TERMINAL_NAME : in CHAR_STRING;
TERM_ENTRY_ADDRESS : out LONGWORD_UNSIGNED);

procedure INIT_TERM_TABLE --
(STATUS : out COND_VALUE;
TERMINAL_NAME : in CHAR_STRING;
TERM_ENTRY_ADDRESS : out LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, INIT_TERM_TABLE);

pragma IMPORT_PROCEDURE(INIT_TERM_TABLE, "SMG$INIT_TERM_TABLE", (CHAR_STRING,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(INIT_TERM_TABLE, "SMG$INIT_TERM_TABLE", (COND_VALUE,
CHAR_STRING, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- initializes the TERMTABLE database for the terminal names, so that
-- subsequent calls to SMG$GET_TERM_DATA can extract information and
-- command strings for that terminal.
--

procedure INIT_TERM_TABLE_BY_TYPE --
(TERMINAL_TYPE : in BYTE_SIGNED;
TERM_ENTRY_ADDRESS : out LONGWORD_UNSIGNED;
TERMINAL_NAME : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER
-- VMS usage "device_name"; SMG_C_ASCII default and only possible value
);

procedure INIT_TERM_TABLE_BY_TYPE --
(STATUS : out COND_VALUE;
TERMINAL_TYPE : in BYTE_SIGNED;
TERM_ENTRY_ADDRESS : out LONGWORD_UNSIGNED;
TERMINAL_NAME : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER
-- VMS usage "device_name"; SMG_C_ASCII default and only possible value
);

pragma INTERFACE(RTL, INIT_TERM_TABLE_BY_TYPE);

pragma IMPORT_PROCEDURE(INIT_TERM_TABLE_BY_TYPE, "SMG$INIT_TERM_TABLE_BY_TYPE"
, (BYTE_SIGNED, LONGWORD_UNSIGNED, CHAR_STRING));

pragma IMPORT_PROCEDURE(INIT_TERM_TABLE_BY_TYPE, "SMG$INIT_TERM_TABLE_BY_TYPE"
, (COND_VALUE, BYTE_SIGNED, LONGWORD_UNSIGNED, CHAR_STRING));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- inserts the specified character string at the row and column positions
-- specified. Characters to the right of the insertion are shifted to
-- the right. Note that any characters which do not fie on the current
-- line are discarded. The virtual cursor remains at the character
-- position following the last character inserted.
--

procedure INSERT_CHARS --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
STRING : in CHAR_STRING;
ROW, COLUMN : in LONGWORD_SIGNED;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure INSERT_CHARS --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
STRING : in CHAR_STRING;
ROW, COLUMN : in LONGWORD_SIGNED;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, INSERT_CHARS);

pragma IMPORT_PROCEDURE(INSERT_CHARS, "SMG$INSERT_CHARS", (LONGWORD_UNSIGNED,
CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD
, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(INSERT_CHARS, "SMG$INSERT_CHARS", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- inserts a line into a virtual display and scrolls the display.
--

procedure INSERT_LINE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
LINE_NUMBER : in LONGWORD_SIGNED;
STRING : in CHAR_STRING;
DIRECTION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure INSERT_LINE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
LINE_NUMBER : in LONGWORD_SIGNED;
STRING : in CHAR_STRING;
DIRECTION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, INSERT_LINE);

pragma IMPORT_PROCEDURE(INSERT_LINE, "SMG$INSERT_LINE", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, CHAR_STRING, LONGWORD_UNSIGNED, MASK_LONGWORD,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(INSERT_LINE, "SMG$INSERT_LINE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, CHAR_STRING, LONGWORD_UNSIGNED,
MASK_LONGWORD, MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- marks a display as invalid and causes the entire display to be
-- redrawn.
--

procedure INVALIDATE_DISPLAY --
(DISPLAY_ID : in LONGWORD_UNSIGNED);

procedure INVALIDATE_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, INVALIDATE_DISPLAY);

pragma IMPORT_PROCEDURE(INVALIDATE_DISPLAY, "SMG$INVALIDATE_DISPLAY", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(INVALIDATE_DISPLAY, "SMG$INVALIDATE_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- supplies a label virtual for a virtual display's border.
--

procedure LABEL_BORDER --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
LABEL_TEXT : in CHAR_STRING;
POSITION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
UNITS : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure LABEL_BORDER --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
LABEL_TEXT : in CHAR_STRING;
POSITION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
UNITS : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, LABEL_BORDER);

pragma IMPORT_PROCEDURE(LABEL_BORDER, "SMG$LABEL_BORDER", (LONGWORD_UNSIGNED,
CHAR_STRING, LONGWORD_UNSIGNED, LONGWORD_SIGNED, MASK_LONGWORD,
MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(LABEL_BORDER, "SMG$LABEL_BORDER", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_UNSIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns the definition(equivalence string) associated with a
-- specified key in a specified key in a speciried key table.
--

procedure LIST_KEY_DEFS --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
CONTEXT : in CONTEXT_TYPE;
KEY_NAME, IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ATTRIBUTES : out LONGWORD_UNSIGNED;
EQUIV_STRING, STATE_STRING : out CHAR_STRING);

procedure LIST_KEY_DEFS --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
CONTEXT : in CONTEXT_TYPE;
KEY_NAME, IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ATTRIBUTES : out LONGWORD_UNSIGNED;
EQUIV_STRING, STATE_STRING : out CHAR_STRING);

procedure LIST_KEY_DEFS_1 --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
CONTEXT : in CONTEXT_TYPE;
KEY_NAME, IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

procedure LIST_KEY_DEFS_1 --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
CONTEXT : in CONTEXT_TYPE;
KEY_NAME, IF_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

pragma INTERFACE(RTL, LIST_KEY_DEFS);

pragma INTERFACE(RTL, LIST_KEY_DEFS_1);

pragma IMPORT_PROCEDURE(LIST_KEY_DEFS, "SMG$LIST_KEY_DEFS", (LONGWORD_UNSIGNED
, CONTEXT_TYPE, CHAR_STRING, CHAR_STRING, LONGWORD_UNSIGNED, CHAR_STRING,
CHAR_STRING));

pragma IMPORT_PROCEDURE(LIST_KEY_DEFS, "SMG$LIST_KEY_DEFS", (COND_VALUE,
LONGWORD_UNSIGNED, CONTEXT_TYPE, CHAR_STRING, CHAR_STRING, LONGWORD_UNSIGNED
, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(LIST_KEY_DEFS_1, "SMG$LIST_KEY_DEFS", (
LONGWORD_UNSIGNED, CONTEXT_TYPE, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(LIST_KEY_DEFS_1, "SMG$LIST_KEY_DEFS", (COND_VALUE,
LONGWORD_UNSIGNED, CONTEXT_TYPE, CHAR_STRING, CHAR_STRING));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- loads a file of key definitions(DEFINE/KEY commands) into a
-- specified key table.
--

procedure LOAD_KEY_DEFS --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
FILESPEC : in CHAR_STRING;
DEFAULT_FILESPEC : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
LOGNAM_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

procedure LOAD_KEY_DEFS --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
FILESPEC : in CHAR_STRING;
DEFAULT_FILESPEC : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
LOGNAM_FLAG : in MASK_LONGWORD := MASK_LONGWORD'NULL_PARAMETER);

pragma INTERFACE(RTL, LOAD_KEY_DEFS);

pragma IMPORT_PROCEDURE(LOAD_KEY_DEFS, "SMG$LOAD_KEY_DEFS", (LONGWORD_UNSIGNED
, CHAR_STRING, CHAR_STRING, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(LOAD_KEY_DEFS, "SMG$LOAD_KEY_DEFS", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- relocates a virtual display on a pasteboard and preserves the
-- pasting order.
--

procedure MOVE_VIRTUAL_DISPLAY --
(DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ROW, PASTEBOARD_COLUMN : in LONGWORD_SIGNED;
TOP_DISPLAY_ID : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED
'NULL_PARAMETER);

procedure MOVE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ROW, PASTEBOARD_COLUMN : in LONGWORD_SIGNED;
TOP_DISPLAY_ID : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED
'NULL_PARAMETER);

pragma INTERFACE(RTL, MOVE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(MOVE_VIRTUAL_DISPLAY, "SMG$MOVE_VIRTUAL_DISPLAY", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(MOVE_VIRTUAL_DISPLAY, "SMG$MOVE_VIRTUAL_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- places a display on a pasteboard and makes the display visible.
-- If, however, the optional argument top-display-id is specified,
-- SMG$PASTE_VIRTUAL_DISPLAY pastes the virtual display being pasted
-- under the virtual display specified by top-display-id. In this
-- case, the virtual display specified by top-display-id must already
-- be pasted.
--

procedure PASTE_VIRTUAL_DISPLAY --
(DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ROW, PASTEBOARD_COLUMN : in LONGWORD_SIGNED;
TOP_DISPLAY_ID : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED
'NULL_PARAMETER);

procedure PASTE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PASTEBOARD_ROW, PASTEBOARD_COLUMN : in LONGWORD_SIGNED;
TOP_DISPLAY_ID : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED
'NULL_PARAMETER);

pragma INTERFACE(RTL, PASTE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(PASTE_VIRTUAL_DISPLAY, "SMG$PASTE_VIRTUAL_DISPLAY", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(PASTE_VIRTUAL_DISPLAY, "SMG$PASTE_VIRTUAL_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- deletes a specified virtual display and all displays that were
-- pasted on the specified pasteboard after the specified virtual
-- display.
--

procedure POP_VIRTUAL_DISPLAY --
(DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure POP_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, POP_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(POP_VIRTUAL_DISPLAY, "SMG$POP_VIRTUAL_DISPLAY", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(POP_VIRTUAL_DISPLAY, "SMG$POP_VIRTUAL_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- overwrites characters in a virtual display with the text you
-- specify.
--

procedure PUT_CHARS --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
ERASE_FLAG, RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure PUT_CHARS --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
ERASE_FLAG, RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, PUT_CHARS);

pragma IMPORT_PROCEDURE(PUT_CHARS, "SMG$PUT_CHARS", (LONGWORD_UNSIGNED,
CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD
, MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(PUT_CHARS, "SMG$PUT_CHARS", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- write double-height, double-width characters to a virtual display.
--

procedure PUT_CHARS_HIGHWIDE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure PUT_CHARS_HIGHWIDE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, PUT_CHARS_HIGHWIDE);

pragma IMPORT_PROCEDURE(PUT_CHARS_HIGHWIDE, "SMG$PUT_CHARS_HIGHWIDE", (
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(PUT_CHARS_HIGHWIDE, "SMG$PUT_CHARS_HIGHWIDE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED
, MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- writes double-width characters to a virtual display.
--

procedure PUT_CHARS_WIDE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure PUT_CHARS_WIDE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_NUMBER, COLUMN_NUMBER : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, PUT_CHARS_WIDE);

pragma IMPORT_PROCEDURE(PUT_CHARS_WIDE, "SMG$PUT_CHARS_WIDE", (
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(PUT_CHARS_WIDE, "SMG$PUT_CHARS_WIDE", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- writes a line of text to a virtual display.
--

procedure PUT_LINE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_ADVANCE : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET, DIRECTION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure PUT_LINE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_ADVANCE : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET, DIRECTION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, PUT_LINE);

pragma IMPORT_PROCEDURE(PUT_LINE, "SMG$PUT_LINE", (LONGWORD_UNSIGNED,
CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD, MASK_LONGWORD,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(PUT_LINE, "SMG$PUT_LINE", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- writes lines with double high and double wide characters.
--

procedure PUT_LINE_HIGHWIDE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_ADV : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
CHAR_SET : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER);

procedure PUT_LINE_HIGHWIDE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_ADV : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
CHAR_SET : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, PUT_LINE_HIGHWIDE);

pragma IMPORT_PROCEDURE(PUT_LINE_HIGHWIDE, "SMG$PUT_LINE_HIGHWIDE", (
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, LONGWORD_UNSIGNED,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(PUT_LINE_HIGHWIDE, "SMG$PUT_LINE_HIGHWIDE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- writes a line of double-width text to a virtual display.
--

procedure PUT_LINE_WIDE --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_ADVANCE : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

procedure PUT_LINE_WIDE --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
TEXT : in CHAR_STRING;
LINE_ADVANCE : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT, WRAP_FLAG : in MASK_LONGWORD :=
MASK_LONGWORD'NULL_PARAMETER;
CHAR_SET : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, PUT_LINE_WIDE);

pragma IMPORT_PROCEDURE(PUT_LINE_WIDE, "SMG$PUT_LINE_WIDE", (LONGWORD_UNSIGNED
, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD, MASK_LONGWORD
, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(PUT_LINE_WIDE, "SMG$PUT_LINE_WIDE", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD,
MASK_LONGWORD, MASK_LONGWORD, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- routine accesses the contents of a pasteboard. The caller specifies
-- an action routine that will be called once for each line in the
-- pasteboard. The action routine will be passed a descriptor for
-- for that line followed by a user-specified argument.
--

procedure PUT_PASTEBOARD --
(PASTEBOARD_ID, P_RTN : in LONGWORD_UNSIGNED;
P_PRM : in USER_ARG;
P_FF_FLAG : in MASK_LONGWORD);

procedure PUT_PASTEBOARD --
(STATUS : out COND_VALUE;
PASTEBOARD_ID, P_RTN : in LONGWORD_UNSIGNED;
P_PRM : in USER_ARG;
P_FF_FLAG : in MASK_LONGWORD);

pragma INTERFACE(RTL, PUT_PASTEBOARD);

pragma IMPORT_PROCEDURE(PUT_PASTEBOARD, "SMG$PUT_PASTEBOARD", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, USER_ARG, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(PUT_PASTEBOARD, "SMG$PUT_PASTEBOARD", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, USER_ARG, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- reads a line of input composed of normal keystrokes and
-- equivalence strings.
--

procedure READ_COMPOSED_LINE --
(KEYBOARD_ID, KEY_TABLE_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RECEIVED_STRING_LENGTH : out WORD_UNSIGNED;
DISPLAY_ID, FUNCTION_KEYS_FLAG : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TERMINATOR_CODE : out WORD_UNSIGNED);

procedure READ_COMPOSED_LINE --
(STATUS : out COND_VALUE;
KEYBOARD_ID, KEY_TABLE_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RECEIVED_STRING_LENGTH : out WORD_UNSIGNED;
DISPLAY_ID, FUNCTION_KEYS_FLAG : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TERMINATOR_CODE : out WORD_UNSIGNED);

procedure READ_COMPOSED_LINE_1 --
(KEYBOARD_ID, KEY_TABLE_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
DISPLAY_ID, FUNCTION_KEYS_FLAG : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_COMPOSED_LINE_1 --
(STATUS : out COND_VALUE;
KEYBOARD_ID, KEY_TABLE_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
DISPLAY_ID, FUNCTION_KEYS_FLAG : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

pragma INTERFACE(RTL, READ_COMPOSED_LINE);

pragma INTERFACE(RTL, READ_COMPOSED_LINE_1);

pragma IMPORT_PROCEDURE(READ_COMPOSED_LINE, "SMG$READ_COMPOSED_LINE", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING,
WORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING,
LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD, WORD_UNSIGNED));

pragma IMPORT_PROCEDURE(READ_COMPOSED_LINE, "SMG$READ_COMPOSED_LINE", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING,
WORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING,
LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD, WORD_UNSIGNED));

pragma IMPORT_PROCEDURE(READ_COMPOSED_LINE_1, "SMG$READ_COMPOSED_LINE", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_COMPOSED_LINE_1, "SMG$READ_COMPOSED_LINE", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- reads a line of text from a virtual display.
--

procedure READ_FROM_DISPLAY --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
RETURNED_STRING : out CHAR_STRING;
TERMINATOR_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ROW : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

procedure READ_FROM_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
RETURNED_STRING : out CHAR_STRING;
TERMINATOR_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
ROW : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, READ_FROM_DISPLAY);

pragma IMPORT_PROCEDURE(READ_FROM_DISPLAY, "SMG$READ_FROM_DISPLAY", (
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(READ_FROM_DISPLAY, "SMG$READ_FROM_DISPLAY", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- reads a keystroke and returns that keystroke's terminator code.
--

procedure READ_KEYSTROKE --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
TERMINATOR_CODE : out WORD_UNSIGNED;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_KEYSTROKE --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
TERMINATOR_CODE : out WORD_UNSIGNED;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

pragma INTERFACE(RTL, READ_KEYSTROKE);

pragma IMPORT_PROCEDURE(READ_KEYSTROKE, "SMG$READ_KEYSTROKE", (
LONGWORD_UNSIGNED, WORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
LONGWORD_UNSIGNED, MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_KEYSTROKE, "SMG$READ_KEYSTROKE", (COND_VALUE,
LONGWORD_UNSIGNED, WORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
LONGWORD_UNSIGNED, MASK_LONGWORD, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- reads a string form a virtual keyboard.
--

procedure READ_STRING --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MAX_LENGTH : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RECEIVED_STRING_LENGTH, TERMINATOR_CODE : out WORD_UNSIGNED;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_STRING --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MAX_LENGTH : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RECEIVED_STRING_LENGTH, TERMINATOR_CODE : out WORD_UNSIGNED;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_STRING_1 --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MAX_LENGTH : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_STRING_1 --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
RECEIVED_TEXT : out CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MAX_LENGTH : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
INI_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

pragma INTERFACE(RTL, READ_STRING);

pragma INTERFACE(RTL, READ_STRING_1);

pragma IMPORT_PROCEDURE(READ_STRING, "SMG$READ_STRING", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD, LONGWORD_SIGNED,
CHAR_STRING, WORD_UNSIGNED, WORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING,
MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_STRING, "SMG$READ_STRING", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD
, LONGWORD_SIGNED, CHAR_STRING, WORD_UNSIGNED, WORD_UNSIGNED,
LONGWORD_UNSIGNED, CHAR_STRING, MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_STRING_1, "SMG$READ_STRING", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD, LONGWORD_SIGNED,
CHAR_STRING, LONGWORD_UNSIGNED, CHAR_STRING, MASK_LONGWORD, MASK_LONGWORD))
;

pragma IMPORT_PROCEDURE(READ_STRING_1, "SMG$READ_STRING", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD
, LONGWORD_SIGNED, CHAR_STRING, LONGWORD_UNSIGNED, CHAR_STRING,
MASK_LONGWORD, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- reads a sequence of characters and verifies the sequence.
--

procedure READ_VERIFY --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_STRING, IN_STRING : out CHAR_STRING;
PIC_STRING, FILL_CHAR, CLEAR_CHAR : in CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
INI_OFFSET : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_CODE : out WORD_UNSIGNED;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
ALT_ECHO_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
ALT_DISPLAY_ID : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_VERIFY --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_STRING, IN_STRING : out CHAR_STRING;
PIC_STRING, FILL_CHAR, CLEAR_CHAR : in CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
INI_OFFSET : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_CODE : out WORD_UNSIGNED;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
ALT_ECHO_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
ALT_DISPLAY_ID : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_VERIFY_1 --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_STRING, IN_STRING : out CHAR_STRING;
PIC_STRING, FILL_CHAR, CLEAR_CHAR : in CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
INI_OFFSET : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
ALT_ECHO_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
ALT_DISPLAY_ID : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

procedure READ_VERIFY_1 --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_STRING, IN_STRING : out CHAR_STRING;
PIC_STRING, FILL_CHAR, CLEAR_CHAR : in CHAR_STRING;
PROMPT_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
MODIFIERS : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER;
TIMEOUT : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
TERMINATOR_SET : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
INI_OFFSET : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
DISPLAY_ID : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
ALT_ECHO_STRING : in CHAR_STRING := CHAR_STRING'
NULL_PARAMETER;
ALT_DISPLAY_ID : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER;
RENDITION_SET, RENDITION_COMPLEMENT : in MASK_LONGWORD := MASK_LONGWORD'
NULL_PARAMETER);

pragma INTERFACE(RTL, READ_VERIFY);

pragma INTERFACE(RTL, READ_VERIFY_1);

pragma IMPORT_PROCEDURE(READ_VERIFY, "SMG$READ_VERIFY", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING
, MASK_LONGWORD, LONGWORD_SIGNED, CHAR_STRING, LONGWORD_SIGNED,
WORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_VERIFY, "SMG$READ_VERIFY", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING,
CHAR_STRING, CHAR_STRING, MASK_LONGWORD, LONGWORD_SIGNED, CHAR_STRING,
LONGWORD_SIGNED, WORD_UNSIGNED, LONGWORD_UNSIGNED, CHAR_STRING,
LONGWORD_SIGNED, MASK_LONGWORD, MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_VERIFY_1, "SMG$READ_VERIFY", (LONGWORD_UNSIGNED,
CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING
, MASK_LONGWORD, LONGWORD_SIGNED, CHAR_STRING, LONGWORD_SIGNED,
LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED, MASK_LONGWORD,
MASK_LONGWORD));

pragma IMPORT_PROCEDURE(READ_VERIFY_1, "SMG$READ_VERIFY", (COND_VALUE,
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, CHAR_STRING, CHAR_STRING,
CHAR_STRING, CHAR_STRING, MASK_LONGWORD, LONGWORD_SIGNED, CHAR_STRING,
LONGWORD_SIGNED, LONGWORD_UNSIGNED, CHAR_STRING, LONGWORD_SIGNED,
MASK_LONGWORD, MASK_LONGWORD));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- repaints a series of lines on the current screen.
--

procedure REPAINT_LINE --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
ROW_START : in LONGWORD_SIGNED;
NUM_OF_LINES : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

procedure REPAINT_LINE --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
ROW_START : in LONGWORD_SIGNED;
NUM_OF_LINES : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, REPAINT_LINE);

pragma IMPORT_PROCEDURE(REPAINT_LINE, "SMG$REPAINT_LINE", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(REPAINT_LINE, "SMG$REPAINT_LINE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- repaints the current screen after nonSMG I/O has occurred.
--

procedure REPAINT_SCREEN --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure REPAINT_SCREEN --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, REPAINT_SCREEN);

pragma IMPORT_PROCEDURE(REPAINT_SCREEN, "SMG$REPAINT_SCREEN", (
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(REPAINT_SCREEN, "SMG$REPAINT_SCREEN", (COND_VALUE,
LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- moves a virtual display to a new position on the pasteboard.
-- The pasting order is not preserved.
--

procedure REPASTE_VIRTUAL_DISPLAY --
(DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PB_ROW, PB_COLUMN : in LONGWORD_SIGNED;
TOP_DISPLAY_ID : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER);

procedure REPASTE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED;
PB_ROW, PB_COLUMN : in LONGWORD_SIGNED;
TOP_DISPLAY_ID : in LONGWORD_UNSIGNED := LONGWORD_UNSIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, REPASTE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(REPASTE_VIRTUAL_DISPLAY, "SMG$REPASTE_VIRTUAL_DISPLAY"
, (LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(REPASTE_VIRTUAL_DISPLAY, "SMG$REPASTE_VIRTUAL_DISPLAY"
, (COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED));

-------------------------------------------------------------------------
-- replaces the specified lines in the recall buffer with the
-- specified string.
--

procedure REPLACE_INPUT_LINE --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_LINE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
NUM_OF_LINES : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER);

procedure REPLACE_INPUT_LINE --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_LINE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
NUM_OF_LINES : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, REPLACE_INPUT_LINE);

pragma IMPORT_PROCEDURE(REPLACE_INPUT_LINE, "SMG$REPLACE_INPUT_LINE", (
LONGWORD_UNSIGNED, CHAR_STRING, BYTE_UNSIGNED));

pragma IMPORT_PROCEDURE(REPLACE_INPUT_LINE, "SMG$REPLACE_INPUT_LINE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, BYTE_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- rewrites the screen image as it was at the time the
-- SMG$SAVE_PHYSICAL_SCREEN routine was called.
--

procedure RESTORE_PHYSICAL_SCREEN --
(PASTEBOARD_ID, SAVED_DISPLAY_ID : in LONGWORD_UNSIGNED);

procedure RESTORE_PHYSICAL_SCREEN --
(STATUS : out COND_VALUE;
PASTEBOARD_ID, SAVED_DISPLAY_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, RESTORE_PHYSICAL_SCREEN);

pragma IMPORT_PROCEDURE(RESTORE_PHYSICAL_SCREEN, "SMG$RESTORE_PHYSICAL_SCREEN"
, (LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(RESTORE_PHYSICAL_SCREEN, "SMG$RESTORE_PHYSICAL_SCREEN"
, (COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns the current virtual cusor position in a specified
-- virtual in a specified virtual display.
--

procedure RETURN_CURSOR_POS --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
ROW_NUMBER, COLUMN_NUMBER : out LONGWORD_SIGNED);

procedure RETURN_CURSOR_POS --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
ROW_NUMBER, COLUMN_NUMBER : out LONGWORD_SIGNED);

pragma INTERFACE(RTL, RETURN_CURSOR_POS);

pragma IMPORT_PROCEDURE(RETURN_CURSOR_POS, "SMG$RETURN_CURSOR_POS", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(RETURN_CURSOR_POS, "SMG$RETURN_CURSOR_POS", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- returns to the caller the requested line from the recall buffer.
-- This line is retrieved either by matching it with a specified
-- string or by specifying the appropriate line number.
--

procedure RETURN_INPUT_LINE --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_LINE : out CHAR_STRING;
MATCH_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
LINE_NUM : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER;
OUT_LENGTH : out WORD_UNSIGNED);

procedure RETURN_INPUT_LINE --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_LINE : out CHAR_STRING;
MATCH_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
LINE_NUM : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER;
OUT_LENGTH : out WORD_UNSIGNED);

procedure RETURN_INPUT_LINE_1 --
(KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_LINE : out CHAR_STRING;
MATCH_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
LINE_NUM : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER);

procedure RETURN_INPUT_LINE_1 --
(STATUS : out COND_VALUE;
KEYBOARD_ID : in LONGWORD_UNSIGNED;
OUT_LINE : out CHAR_STRING;
MATCH_STRING : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
LINE_NUM : in BYTE_UNSIGNED := BYTE_UNSIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, RETURN_INPUT_LINE);

pragma INTERFACE(RTL, RETURN_INPUT_LINE_1);

pragma IMPORT_PROCEDURE(RETURN_INPUT_LINE, "SMG$RETURN_INPUT_LINE", (
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, BYTE_UNSIGNED, WORD_UNSIGNED))
;

pragma IMPORT_PROCEDURE(RETURN_INPUT_LINE, "SMG$RETURN_INPUT_LINE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, BYTE_UNSIGNED,
WORD_UNSIGNED));

pragma IMPORT_PROCEDURE(RETURN_INPUT_LINE_1, "SMG$RETURN_INPUT_LINE", (
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, BYTE_UNSIGNED));

pragma IMPORT_PROCEDURE(RETURN_INPUT_LINE_1, "SMG$RETURN_INPUT_LINE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING, BYTE_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- sound the terminal bell or buzzer.
--

procedure RING_BELL --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
NUMBER_OF_TIMES : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

procedure RING_BELL --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
NUMBER_OF_TIMES : in LONGWORD_SIGNED := LONGWORD_SIGNED'NULL_PARAMETER);

pragma INTERFACE(RTL, RING_BELL);

pragma IMPORT_PROCEDURE(RING_BELL, "SMG$RING_BELL", (LONGWORD_UNSIGNED,
LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(RING_BELL, "SMG$RING_BELL", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- saves the contents of the screen so that a later call to
-- SMG$RESTORE_PHYSICAL_SCREEN can restore it.
--

procedure SAVE_PHYSICAL_SCREEN --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
SAVED_DISPLAY_ID : out LONGWORD_UNSIGNED;
DESIRED_ROW_START, DESIRED_ROW_END : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

procedure SAVE_PHYSICAL_SCREEN --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
SAVED_DISPLAY_ID : out LONGWORD_UNSIGNED;
DESIRED_ROW_START, DESIRED_ROW_END : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, SAVE_PHYSICAL_SCREEN);

pragma IMPORT_PROCEDURE(SAVE_PHYSICAL_SCREEN, "SMG$SAVE_PHYSICAL_SCREEN", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(SAVE_PHYSICAL_SCREEN, "SMG$SAVE_PHYSICAL_SCREEN", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- scrolls a rectangular region of a virtual display.
--

procedure SCROLL_DISPLAY_AREA --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
STARTING_ROW, STARTING_COLUMN, HEIGHT, WIDTH : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
DIRECTION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
COUNT : out LONGWORD_SIGNED);

procedure SCROLL_DISPLAY_AREA --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
STARTING_ROW, STARTING_COLUMN, HEIGHT, WIDTH : in LONGWORD_SIGNED :=
LONGWORD_SIGNED'NULL_PARAMETER;
DIRECTION : in LONGWORD_UNSIGNED :=
LONGWORD_UNSIGNED'NULL_PARAMETER;
COUNT : out LONGWORD_SIGNED);

pragma INTERFACE(RTL, SCROLL_DISPLAY_AREA);

pragma IMPORT_PROCEDURE(SCROLL_DISPLAY_AREA, "SMG$SCROLL_DISPLAY_AREA", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(SCROLL_DISPLAY_AREA, "SMG$SCROLL_DISPLAY_AREA", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED, LONGWORD_UNSIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- enables the trapping of broadcast messages.
--

procedure SET_BROADCAST_TRAPPING --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
AST_ROUTINE : in AST_PROCEDURE := AST_PROCEDURE'NULL_PARAMETER;
AST_ARGUMENT : in USER_ARG := USER_ARG'NULL_PARAMETER);

procedure SET_BROADCAST_TRAPPING --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
AST_ROUTINE : in AST_PROCEDURE := AST_PROCEDURE'NULL_PARAMETER;
AST_ARGUMENT : in USER_ARG := USER_ARG'NULL_PARAMETER);

pragma INTERFACE(RTL, SET_BROADCAST_TRAPPING);

pragma IMPORT_PROCEDURE(SET_BROADCAST_TRAPPING, "SMG$SET_BROADCAST_TRAPPING",
(LONGWORD_UNSIGNED, AST_PROCEDURE, USER_ARG));

pragma IMPORT_PROCEDURE(SET_BROADCAST_TRAPPING, "SMG$SET_BROADCAST_TRAPPING",
(COND_VALUE, LONGWORD_UNSIGNED, AST_PROCEDURE, USER_ARG));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- moves the virtual cursor to the specified position in a virtual
-- dispaly.
--

procedure SET_CURSOR_ABS --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
ROW, COLUMN : in LONGWORD_SIGNED );

procedure SET_CURSOR_ABS --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
ROW, COLUMN : in LONGWORD_SIGNED );

pragma INTERFACE(RTL, SET_CURSOR_ABS);

pragma IMPORT_PROCEDURE(SET_CURSOR_ABS, "SMG$SET_CURSOR_ABS", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(SET_CURSOR_ABS, "SMG$SET_CURSOR_ABS", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- turns the physical cursor on or off.
--

procedure SET_CURSOR_MODE --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CURSOR_MODE : in BOOLEAN);

procedure SET_CURSOR_MODE --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CURSOR_MODE : in BOOLEAN);

pragma INTERFACE(RTL, SET_CURSOR_MODE);

pragma IMPORT_PROCEDURE(SET_CURSOR_MODE, "SMG$SET_CURSOR_MODE", (
LONGWORD_UNSIGNED, BOOLEAN));

pragma IMPORT_PROCEDURE(SET_CURSOR_MODE, "SMG$SET_CURSOR_MODE", (COND_VALUE,
LONGWORD_UNSIGNED, BOOLEAN));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- moves the virtual cursor the specified number of rows and
-- columns from the current virtual cursor position in a virtual
-- display.
--

procedure SET_CURSOR_REL --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
DELTA_ROW, DELTA_COLUMN : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

procedure SET_CURSOR_REL --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
DELTA_ROW, DELTA_COLUMN : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, SET_CURSOR_REL);

pragma IMPORT_PROCEDURE(SET_CURSOR_REL, "SMG$SET_CURSOR_REL", (
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(SET_CURSOR_REL, "SMG$SET_CURSOR_REL", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- sets and/or returns the current default state for a key table.
--

procedure SET_DEFAULT_STATE --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
NEW_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
OLD_STATE : out CHAR_STRING);

procedure SET_DEFAULT_STATE --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
NEW_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER;
OLD_STATE : out CHAR_STRING);

procedure SET_DEFAULT_STATE_1 --
(KEY_TABLE_ID : in LONGWORD_UNSIGNED;
NEW_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

procedure SET_DEFAULT_STATE_1 --
(STATUS : out COND_VALUE;
KEY_TABLE_ID : in LONGWORD_UNSIGNED;
NEW_STATE : in CHAR_STRING := CHAR_STRING'NULL_PARAMETER);

pragma INTERFACE(RTL, SET_DEFAULT_STATE);

pragma INTERFACE(RTL, SET_DEFAULT_STATE_1);

pragma IMPORT_PROCEDURE(SET_DEFAULT_STATE, "SMG$SET_DEFAULT_STATE", (
LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(SET_DEFAULT_STATE, "SMG$SET_DEFAULT_STATE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING, CHAR_STRING));

pragma IMPORT_PROCEDURE(SET_DEFAULT_STATE_1, "SMG$SET_DEFAULT_STATE", (
LONGWORD_UNSIGNED, CHAR_STRING));

pragma IMPORT_PROCEDURE(SET_DEFAULT_STATE_1, "SMG$SET_DEFAULT_STATE", (
COND_VALUE, LONGWORD_UNSIGNED, CHAR_STRING));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- creates a scrolling region in a virtual display.
--

procedure SET_DISPLAY_SCROLL_REGION --
(DISPLAY_ID : in LONGWORD_UNSIGNED;
STARTING_LINE, ENDING_LINE : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

procedure SET_DISPLAY_SCROLL_REGION --
(STATUS : out COND_VALUE;
DISPLAY_ID : in LONGWORD_UNSIGNED;
STARTING_LINE, ENDING_LINE : in LONGWORD_SIGNED := LONGWORD_SIGNED'
NULL_PARAMETER);

pragma INTERFACE(RTL, SET_DISPLAY_SCROLL_REGION);

pragma IMPORT_PROCEDURE(SET_DISPLAY_SCROLL_REGION,
"SMG$SET_DISPLAY_SCROLL_REGION", (LONGWORD_UNSIGNED, LONGWORD_SIGNED,
LONGWORD_SIGNED));

pragma IMPORT_PROCEDURE(SET_DISPLAY_SCROLL_REGION,
"SMG$SET_DISPLAY_SCROLL_REGION", (COND_VALUE, LONGWORD_UNSIGNED,
LONGWORD_SIGNED, LONGWORD_SIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- sets the terminal's numeric keypad to either nuneric or
-- applications mode.
--

procedure SET_KEYPAD_MODE --
(KEYBOARD_ID, NEW_MODE : in LONGWORD_UNSIGNED);

procedure SET_KEYPAD_MODE --
(STATUS : out COND_VALUE;
KEYBOARD_ID, NEW_MODE : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, SET_KEYPAD_MODE);

pragma IMPORT_PROCEDURE(SET_KEYPAD_MODE, "SMG$SET_KEYPAD_MODE", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(SET_KEYPAD_MODE, "SMG$SET_KEYPAD_MODE", (COND_VALUE,
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- either enables or disables the trapping of out-of-band
-- characters.
--

procedure SET_OUT_OF_BAND_ASTS --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CONTROL_CHAR_MASK : in MASK_LONGWORD;
AST_ROUTINE : in AST_PROCEDURE;
AST_ARGUMENT : in USER_ARG := USER_ARG'NULL_PARAMETER);

procedure SET_OUT_OF_BAND_ASTS --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
CONTROL_CHAR_MASK : in MASK_LONGWORD;
AST_ROUTINE : in AST_PROCEDURE;
AST_ARGUMENT : in USER_ARG := USER_ARG'NULL_PARAMETER);

pragma INTERFACE(RTL, SET_OUT_OF_BAND_ASTS);

pragma IMPORT_PROCEDURE(SET_OUT_OF_BAND_ASTS, "SMG$SET_OUT_OF_BAND_ASTS", (
LONGWORD_UNSIGNED, MASK_LONGWORD, AST_PROCEDURE, USER_ARG));

pragma IMPORT_PROCEDURE(SET_OUT_OF_BAND_ASTS, "SMG$SET_OUT_OF_BAND_ASTS", (
COND_VALUE, LONGWORD_UNSIGNED, MASK_LONGWORD, AST_PROCEDURE, USER_ARG));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- moves the physical cursor to the specified position on the
-- physical screen.
--

procedure SET_PHYSICAL_CURSOR --
(PASTEBOARD_ID, PB_ROW, PB_COLUMN : in LONGWORD_UNSIGNED);

procedure SET_PHYSICAL_CURSOR --
(STATUS : out COND_VALUE;
PASTEBOARD_ID, PB_ROW, PB_COLUMN : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, SET_PHYSICAL_CURSOR);

pragma IMPORT_PROCEDURE(SET_PHYSICAL_CURSOR, "SMG$SET_PHYSICAL_CURSOR", (
LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(SET_PHYSICAL_CURSOR, "SMG$SET_PHYSICAL_CURSOR", (
COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- writes the current pasteboard buffer to the file or hardcopy
-- terminal specified by pasteboard-id.
--

procedure SNAPSHOT --
(PASTEBOARD_ID : in LONGWORD_UNSIGNED;
FF_FLAG : in BOOLEAN);

procedure SNAPSHOT --
(STATUS : out COND_VALUE;
PASTEBOARD_ID : in LONGWORD_UNSIGNED;
FF_FLAG : in BOOLEAN);

pragma INTERFACE(RTL, SNAPSHOT);

pragma IMPORT_PROCEDURE(SNAPSHOT, "SMG$SNAPSHOT", (LONGWORD_UNSIGNED, BOOLEAN)
);

pragma IMPORT_PROCEDURE(SNAPSHOT, "SMG$SNAPSHOT", (COND_VALUE,
LONGWORD_UNSIGNED, BOOLEAN));

--------------------------------------------------------------------------
--------------------------------------------------------------------------
-- removes a virtual display from a pasteboard.
--

procedure UNPASTE_VIRTUAL_DISPLAY --
(DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED);

procedure UNPASTE_VIRTUAL_DISPLAY --
(STATUS : out COND_VALUE;
DISPLAY_ID, PASTEBOARD_ID : in LONGWORD_UNSIGNED);

pragma INTERFACE(RTL, UNPASTE_VIRTUAL_DISPLAY);

pragma IMPORT_PROCEDURE(UNPASTE_VIRTUAL_DISPLAY, "SMG$UNPASTE_VIRTUAL_DISPLAY"
, (LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

pragma IMPORT_PROCEDURE(UNPASTE_VIRTUAL_DISPLAY, "SMG$UNPASTE_VIRTUAL_DISPLAY"
, (COND_VALUE, LONGWORD_UNSIGNED, LONGWORD_UNSIGNED));

end SMG;


  3 Responses to “Category : Miscellaneous Language Source Code
Archive   : ADA-LRM3.ZIP
Filename : LR9VT.SRC

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/