VioWrtCharStrAtt (FAPI): Difference between revisions
Appearance
m Ak120 moved page OS2 API:CPI:LEGACY:VioWrtCharStrAtt to VioWrtCharStrAtt (FAPI) |
mNo edit summary |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
This call writes a character string with repeated attribute to the display. | This call writes a character string with repeated attribute to the display. | ||
==Syntax== | ==Syntax== | ||
Line 5: | Line 5: | ||
==Parameters== | ==Parameters== | ||
;CharStr (PCH) - input : Address of the character string to be written. | ;CharStr (PCH) - input: Address of the character string to be written. | ||
;Length (USHORT) - input : Length, in bytes, of the character string. | ;Length (USHORT) - input: Length, in bytes, of the character string. | ||
;Row (USHORT) - input : Starting cursor row. | ;Row (USHORT) - input: Starting cursor row. | ||
;Column (USHORT) - input : Starting cursor column. | ;Column (USHORT) - input: Starting cursor column. | ||
;Attr (PBYTE) - input : Address of the attribute(s) (1 or 3 bytes) to be used in the display buffer for each character of the string written. | ;Attr (PBYTE) - input: Address of the attribute(s) (1 or 3 bytes) to be used in the display buffer for each character of the string written. | ||
;VioHandle (HVIO) - input : This must be zero unless the caller is a Presentation Manager application, in which case it must be the value returned by VioGetPs. | ;VioHandle (HVIO) - input: This must be zero unless the caller is a Presentation Manager application, in which case it must be the value returned by VioGetPs. | ||
==Return Code== | ==Return Code== | ||
;rc (USHORT) - return:Return code descriptions are: | |||
Return code descriptions are: | *0 NO_ERROR | ||
* 0 | *355 ERROR_VIO_MODE | ||
* 355 | *358 ERROR_VIO_ROW | ||
* 358 | *359 ERROR_VIO_COL | ||
* 359 | *436 ERROR_VIO_INVALID_HANDLE | ||
* 436 | *465 ERROR_VIO_DETACHED | ||
* 465 | |||
==Remarks== | ==Remarks== | ||
Line 28: | Line 27: | ||
Write a character string with a repeated attribute string to the Advanced VIO presentation space. The caller must specify the starting location on the presentation space where the string is to be written. | Write a character string with a repeated attribute string to the Advanced VIO presentation space. The caller must specify the starting location on the presentation space where the string is to be written. | ||
== | ==Bindings== | ||
=== C | ===C=== | ||
<PRE> | <PRE> | ||
#define INCL_VIO | #define INCL_VIO | ||
USHORT rc = VioWrtCharStrAtt(CharStr, Length, Row, Column, Attr, | USHORT rc = VioWrtCharStrAtt(CharStr, Length, Row, Column, Attr, VioHandle); | ||
PCH | PCH CharStr; /* String to be written */ | ||
USHORT | USHORT Length; /* Length of string */ | ||
USHORT | USHORT Row; /* Starting row position for output */ | ||
USHORT | USHORT Column; /* Starting column position for output */ | ||
PBYTE | PBYTE Attr; /* Attribute to be replicated */ | ||
HVIO | HVIO VioHandle; /* Video handle */ | ||
USHORT rc; /* return code */ | |||
</PRE> | </PRE> | ||
===MASM | ===MASM=== | ||
<PRE> | <PRE> | ||
EXTRN VioWrtCharStrAtt:FAR | EXTRN VioWrtCharStrAtt:FAR | ||
Line 62: | Line 59: | ||
Returns WORD | Returns WORD | ||
</PRE> | </PRE> | ||
[[Category:Vio]] | [[Category:Vio]] |
Latest revision as of 13:21, 29 February 2020
This call writes a character string with repeated attribute to the display.
Syntax
VioWrtCharStrAtt (CharStr, Length, Row, Column, Attr, VioHandle)
Parameters
- CharStr (PCH) - input
- Address of the character string to be written.
- Length (USHORT) - input
- Length, in bytes, of the character string.
- Row (USHORT) - input
- Starting cursor row.
- Column (USHORT) - input
- Starting cursor column.
- Attr (PBYTE) - input
- Address of the attribute(s) (1 or 3 bytes) to be used in the display buffer for each character of the string written.
- VioHandle (HVIO) - input
- This must be zero unless the caller is a Presentation Manager application, in which case it must be the value returned by VioGetPs.
Return Code
- rc (USHORT) - return
- Return code descriptions are:
- 0 NO_ERROR
- 355 ERROR_VIO_MODE
- 358 ERROR_VIO_ROW
- 359 ERROR_VIO_COL
- 436 ERROR_VIO_INVALID_HANDLE
- 465 ERROR_VIO_DETACHED
Remarks
If a string write gets to the end of the line and is not complete, the string write continues at the beginning of the next line. If the write gets to the end of the screen, the write terminates.
PM Considerations
Write a character string with a repeated attribute string to the Advanced VIO presentation space. The caller must specify the starting location on the presentation space where the string is to be written.
Bindings
C
#define INCL_VIO USHORT rc = VioWrtCharStrAtt(CharStr, Length, Row, Column, Attr, VioHandle); PCH CharStr; /* String to be written */ USHORT Length; /* Length of string */ USHORT Row; /* Starting row position for output */ USHORT Column; /* Starting column position for output */ PBYTE Attr; /* Attribute to be replicated */ HVIO VioHandle; /* Video handle */ USHORT rc; /* return code */
MASM
EXTRN VioWrtCharStrAtt:FAR INCL_VIO EQU 1 PUSH@ OTHER CharStr ;String to be written PUSH WORD Length ;Length of string PUSH WORD Row ;Starting row position for output PUSH WORD Column ;Starting column position for output PUSH@ OTHER Attr ;Attribute to be replicated PUSH WORD VioHandle ;Video handle CALL VioWrtCharStrAtt Returns WORD