[OpenVMS documentation]
[Site home] [Send comments] [Help with this site] [How to order documentation] [OpenVMS site] [Compaq site]
Updated: 11 December 1998

OpenVMS RTL Screen Management (SMG$) Manual


Previous Contents Index

The display-id argument must be specified when you use the rendition-set argument.

rendition-complement


OpenVMS usage: mask_longword
type: longword (unsigned)
access: read only
mechanism: by reference

Attribute complement specifier. The optional rendition-complement argument is the address of a longword bit mask in which each attribute set causes the corresponding attribute to be complemented in the display. All attributes that can be specified with the rendition-set argument can be complemented with the rendition-complement argument. The display-id argument must be specified when you use the rendition-complement argument.

The optional arguments rendition-set and rendition-complement let the user control the attributes of the virtual display. The rendition-set argument sets certain virtual display attributes, while rendition-complement complements these attributes. If the same bit is specified in both the rendition-set and rendition-complement parameters, rendition-set is evaluated first, followed by rendition-complement. By using these two parameters together, the user can control each virtual display attribute in a single procedure call. On a single-attribute basis, the user can cause the following transformations:
Set Complement Action
0 0 Attribute set to default
1 0 Attribute on
0 1 Attribute set to complement of default setting
1 1 Attribute off

character-set


OpenVMS usage: longword_unsigned
type: longword (unsigned)
access: read only
mechanism: by reference

Specifies the default character set for all text in this virtual display. The character-set argument is the address of an unsigned longword that contains the character set code. Valid values are SMG$C_ASCII (the default) and SMG$C_SPEC_GRAPHICS.

Description

SMG$PUT_CHARS writes text to the specified virtual display, possibly overwriting any existing text. Use SMG$INSERT_CHARS to write new text while preserving existing text.

By default, SMG$PUT_CHARS modifies only those character positions where new text is written. However, you can erase the line before the new text is written by specifying SMG$M_ERASE_LINE for the flags argument, or you can erase the remainder of the line after the text is written by specifying SMG$M_ERASE_TO_EOL for the flags argument. The cursor remains at the character position immediately following the last text written. Note that this routine writes to a single line; excess characters at the end of the line are discarded. However, if the display has the SMG$M_TRUNC_ICON attribute, SMG$PUT_CHARS outputs the truncation icon when the line overflows the display.


Condition Values Returned

SS$_NORMAL Normal successful completion.
SMG$_INVCOL Invalid column.
SMG$_INVDIS_ID Invalid display-id.
SMG$_INVROW Invalid row.
SMG$_WILUSERMS Pasteboard is not a video terminal.
SMG$_WRONUMARG Wrong number of arguments.
LIB$_INVSTRDES Invalid string descriptor.

Example


    
C+ 
C This Fortran example program demonstrates the use of 
C SMG$PUT_CHARS. 
C- 
 
        INTEGER SMG$CREATE_VIRTUAL_DISPLAY, SMG$CREATE_PASTEBOARD 
        INTEGER SMG$PASTE_VIRTUAL_DISPLAY,  SMG$PUT_CHARS 
        INTEGER DISPLAY1, PASTE1, ROWS, COLUMNS, BORDER, STATUS 
C+ 
C Create the virtual display. To give it a border, set BORDER = 1. 
C No border would be BORDER = 0. 
C- 
        ROWS = 7 
        COLUMNS = 50 
        BORDER = 1 
 
        STATUS = SMG$CREATE_VIRTUAL_DISPLAY 
     1        (ROWS, COLUMNS, DISPLAY1, BORDER) 
        IF (.NOT. STATUS) CALL LIB$SIGNAL(%VAL(STATUS)) 
 
C+ 
C Create the pasteboard. 
C- 
 
        STATUS = SMG$CREATE_PASTEBOARD (PASTE1) 
        IF (.NOT. STATUS) CALL LIB$SIGNAL(%VAL(STATUS)) 
 
C+ 
C Put data in the virtual display. 
C- 
 
        STATUS = SMG$PUT_CHARS ( DISPLAY1, 
     1        ' This virtual display has 7 rows and 50 columns.', 2, 1 ) 
        IF (.NOT. STATUS) CALL LIB$SIGNAL(%VAL(STATUS)) 
 
        STATUS = SMG$PUT_CHARS ( DISPLAY1, 
     1        ' This is a bordered virtual display.', 4, 1 ) 
        IF (.NOT. STATUS) CALL LIB$SIGNAL(%VAL(STATUS)) 
 
        STATUS = SMG$PUT_CHARS ( DISPLAY1, 
     1        ' SMG$PUT_CHARS puts data in this virtual display.', 6, 1 ) 
        IF (.NOT. STATUS) CALL LIB$SIGNAL(%VAL(STATUS)) 
 
 
C+ 
C Paste the virtual display. 
C- 
 
        STATUS = SMG$PASTE_VIRTUAL_DISPLAY ( DISPLAY1, PASTE1, 4, 15 ) 
        IF (.NOT. STATUS) CALL LIB$SIGNAL(%VAL(STATUS)) 
 
        END 
 
      

The output generated by this Fortran program is shown in Figure SMG-33.

Figure SMG-33 Output of Fortran Program Calling SMG$PUT_CHARS



SMG$PUT_CHARS_HIGHWIDE

The Write Double-Height Double-Width Characters routine writes double-height, double-width (highwide) characters to a virtual display.

Format

SMG$PUT_CHARS_HIGHWIDE display-id ,text [,start-row] [,start-column] [,rendition-set] [,rendition-complement] [,character-set]


RETURNS


OpenVMS usage: cond_value
type: longword (unsigned)
access: write only
mechanism: by value


Arguments

display-id


OpenVMS usage: identifier
type: longword (unsigned)
access: read only
mechanism: by reference

Specifies the virtual display affected. The display-id argument is the address of an unsigned longword that contains the display identifier.

The display identifier is returned by SMG$CREATE_VIRTUAL_DISPLAY.

text


OpenVMS usage: char_string
type: character string
access: read only
mechanism: by descriptor

Characters to be written to the virtual display. The text argument is the address of a descriptor pointing to the text.

start-row


OpenVMS usage: longword_signed
type: longword (signed)
access: read only
mechanism: by reference

Specifies the line at which output begins. The start-row argument is the address of a signed longword that contains the line number. If start-row is omitted or if it is equal to zero, output begins on the current line.

start-column


OpenVMS usage: longword_signed
type: longword (signed)
access: read only
mechanism: by reference

Specifies the column at which output begins. The start-column argument is the address of a signed longword that contains the column number. If start-column is omitted or if it is equal to zero, output begins on the current column.

rendition-set


OpenVMS usage: mask_longword
type: longword (unsigned)
access: read only
mechanism: by reference

Attribute specifier. The optional rendition-set argument is the address of a longword bit mask in which each attribute set causes the corresponding attribute to be set in the display. The following attributes can be specified using the rendition-set argument:
SMG$M_BLINK Displays blinking characters.
SMG$M_BOLD Displays characters in higher-than-normal intensity.
SMG$M_REVERSE Displays characters in reverse video; that is, using the opposite of the default rendition of the virtual display.
SMG$M_UNDERLINE Displays underlined characters.
SMG$M_INVISIBLE Specifies invisible characters; that is, the characters exist in the virtual display but do not appear on the pasteboard.
SMG$M_USER1 through
SMG$M_USER8
Displays user-defined attributes.

The display-id argument must be specified when you use the rendition-set argument.

rendition-complement


OpenVMS usage: mask_longword
type: longword (unsigned)
access: read only
mechanism: by reference

Attribute complement specifier. The optional rendition-complement argument is the address of a longword bit mask in which each attribute set causes the corresponding attribute to be complemented in the display. All attributes that can be specified with the rendition-set argument can be complemented with the rendition-complement argument. The display-id argument must be specified when you use the rendition-complement argument.

The optional arguments rendition-set and rendition-complement let the user control the attributes of the virtual display. The rendition-set argument sets certain virtual display attributes, while rendition-complement complements these attributes. If the same bit is specified in both the rendition-set and rendition-complement parameters, rendition-set is evaluated first, followed by rendition-complement. By using these two parameters together, the user can control each virtual display attribute in a single procedure call. On a single-attribute basis, the user can cause the following transformations:
Set Complement Action
0 0 Attribute set to default
1 0 Attribute on
0 1 Attribute set to complement of default setting
1 1 Attribute off

character-set


OpenVMS usage: longword_unsigned
type: longword (unsigned)
access: read only
mechanism: by reference

Specifies the default character set for all text in this virtual display. The character-set argument is the address of an unsigned longword that contains the character set code. Valid values are SMG$C_ASCII (the default) and SMG$C_SPEC_GRAPHICS.

Description

SMG$PUT_CHARS_HIGHWIDE writes double-height, double-width characters to the specified virtual display. The corresponding pasteboard line cannot contain a mixture of single-height/width and double-height/width characters; if the line contains any single-height/width characters, those characters will be replaced with blanks. If the text does not span the line, it is padded with blanks. The virtual cursor remains at the character position immediately following the last text written.

Note that if the terminal does not support double-height characters, the same characters will be displayed on two successive lines.

If the display has the SMG$M_TRUNC_ICON attribute, SMG$PUT_CHAR_HIGHWIDE outputs the truncation icon when the line overflows the display.


Condition Values Returned

SS$_NORMAL Normal successful completion.
SMG$_INVCOL Invalid column.
SMG$_INVDIS_ID Invalid display-id.
SMG$_INVROW Invalid row.
SMG$_WILUSERMS Pasteboard is not a video terminal.
SMG$_WRONUMARG Wrong number of arguments.
LIB$_INVSTRDES Invalid string descriptor.

SMG$PUT_CHARS_MULTI

The Put Text with Multiple Renditions to Display routine writes text with multiple renditions to the virtual display.

Format

SMG$PUT_CHARS_MULTI display-id ,text [,start-row] [,start-column] [,flags] [,rendition-string] [,rendition-complement] [,character-set]


RETURNS


OpenVMS usage: cond_value
type: longword (unsigned)
access: write only
mechanism: by value


Arguments

display-id


OpenVMS usage: identifier
type: longword (unsigned)
access: read only
mechanism: by reference

Identifier of the virtual display to be affected. The display-id argument is the address of an unsigned longword that contains this identifier.

text


OpenVMS usage: char_string
type: character string
access: read only
mechanism: by descriptor

Text to be output. The text argument is the address of a descriptor pointing to the output string.

start-row


OpenVMS usage: longword_signed
type: longword (signed)
access: read only
mechanism: by reference

Optional row number at which to start output. The start-row argument is the address of a signed longword containing this number. If omitted, the current row number is used.

start-column


OpenVMS usage: longword_signed
type: longword (signed)
access: read only
mechanism: by reference

Optional column number at which to start output. The start-column argument is the address of a signed longword containing this number. If omitted, the current column number is used.

flags


OpenVMS usage: mask_longword
type: longword (unsigned)
access: read only
mechanism: by reference

Optional bit mask that specifies the action to take before the specified text is output. The flags argument is the address of an unsigned longword that contains the flag. The flags argument accepts the following values:
0 Does not erase line (the default).
SMG$M_ERASE_TO_EOL Erases the remaining part of the line.
SMG$M_ERASE_LINE Erases the entire line.

rendition-string


OpenVMS usage: char_string
type: character string
access: read only
mechanism: by descriptor

Optional bit mask string that controls the video attributes. The rendition-string argument is the address of a descriptor pointing to the bit mask string. Each attribute set causes the corresponding attribute to be set for the corresponding byte in the text string in the display. The following attributes can be specified for each byte using the rendition-string argument:
SMG$M_BLINK Displays blinking characters.
SMG$M_BOLD Displays characters in higher-than-normal intensity.
SMG$M_REVERSE Displays characters in reverse video; that is, using the opposite of the default rendition of the virtual display.
SMG$M_UNDERLINE Displays underlined characters.
SMG$M_INVISIBLE Specifies invisible characters; that is, the characters exist in the virtual display but do not appear on the pasteboard.

rendition-complement


OpenVMS usage: char_string
type: character string
access: read only
mechanism: by descriptor

Optional bit mask string that controls the video attributes. The rendition-complement is the address of a descriptor pointing to the bit mask string. Each attribute set causes the corresponding attribute to be complemented for the corresponding byte in the text string in the display.

If the same bit in the same byte is specified in both the rendition-string and rendition-complement arguments, rendition-string is evaluated first, followed by rendition-complement. By using these two parameters together, you can independently control each attribute in a single routine call. On a single-attribute basis, you can cause the following transformations:
Set Complement Action
0 0 Attribute set to default
1 0 Attribute on
0 1 Attribute set to complement of default setting
1 1 Attribute off

character-set


OpenVMS usage: longword_unsigned
type: longword (unsigned)
access: read only
mechanism: by reference

Specifies the default character set for all text in this virtual display. The character-set argument is the address of an unsigned longword that contains the character set code. Valid values are SMG$C_ASCII (the default) and SMG$C_SPEC_GRAPHICS.

Description

SMG$PUT_CHARS_MULTI lets you write text with multiple renditions to the virtual display. No additional cursor movement sequences are added. SMG$PUT_CHARS_MULTI overwrites any existing text in the positions you specify. Use SMG$INSERT_CHARS to write new text while preserving existing text.

By default, SMG$PUT_CHARS_MULTI modifies only those character positions where new text is written. However, you can erase the line before the new text is written by specifying SMG$M_ERASE_LINE for the flags argument, or you can erase the remainder of the line after the text is written by specifying SMG$M_ERASE_TO_EOL for the flags argument. The cursor remains at the character position immediately following the last text written. Note that this routine writes to a single line; excess characters at the end of the line are discarded. However, if the display has the SMG$M_TRUNC_ICON attribute, SMG$PUT_CHARS_MULTI outputs the truncation icon when the line overflows the display.


Condition Values Returned

SS$_NORMAL Normal successful completion.
SMG$_INVCOL Invalid column specification.
SMG$_INVROW Invalid row specification.
SMG$_WILUSERMS Pasteboard is not a video terminal.
SMG$_WRONUMARG Wrong number (or combination of) arguments.
LIB$_INVSTRDES Invalid string descriptor.


Previous Next Contents Index

[Site home] [Send comments] [Help with this site] [How to order documentation] [OpenVMS site] [Compaq site]
[OpenVMS documentation]

Copyright © Compaq Computer Corporation 1998. All rights reserved.

Legal
5935PRO_026.HTML