Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
en:docs:fapi:viogetcurtype [2021/08/20 08:05] – prokushev | en:docs:fapi:viogetcurtype [2021/09/19 02:14] (current) – prokushev | ||
---|---|---|---|
Line 1: | Line 1: | ||
{{page> | {{page> | ||
- | ==Syntax== | + | ====== VioGetCurType ====== |
+ | |||
+ | ===== Syntax ===== | ||
+ | <code c> | ||
| | ||
+ | </ | ||
+ | ===== Parameters ===== | ||
- | ==Parameters== | + | * CursorData ([[PVIOCURSORINFO]]) - output : Address of the cursor characteristics structure: |
- | ;CursorData (PVIOCURSORINFO) - output : Address of the cursor characteristics structure: | + | * startline ([[USHORT]]) : Horizontal scan line in the character cell that marks the top line of the cursor. If the character cell has n scan lines, 0 is the top scan line of the character cell and (n-1) is the bottom scan line. |
+ | * endline ([[USHORT]]) : Horizontal scan line in the character cell that marks the bottom line of the cursor. Scan lines within a character cell are numbered as defined in startline. | ||
+ | * cursorwidth ([[USHORT]]) : Width of the cursor. In text modes, cursorwidth is the number of columns. The maximum number supported by the OS/2 base video subsystem is 1. In graphics modes, cursorwidth is the number of pels. | ||
+ | * cursorattrib ([[USHORT]]) : A value of -1 denotes a hidden cursor, all other values in text mode denote normal cursor and in graphics mode denote color attribute. | ||
+ | * VioHandle ([[HVIO]]) - input : This must be zero unless the caller is a Presentation Manager application, | ||
- | startline (USHORT) : Horizontal scan line in the character cell that marks the top line of the cursor. If the character cell has n scan lines, 0 is the top scan line of the character cell and (n-1) is the bottom scan line. | + | ===== Return Code ===== |
- | endline | + | rc ([[USHORT]]) - return |
- | cursorwidth (USHORT) | + | Return code descriptions are: |
- | cursorattrib (USHORT) : A value of -1 denotes a hidden cursor, all other values in text mode denote normal cursor and in graphics mode denote color attribute. | + | * 0 |
+ | *355 ERROR_VIO_MODE | ||
+ | *436 ERROR_VIO_INVALID_HANDLE | ||
+ | *465 ERROR_VIO_DETACHED | ||
- | ; VioHandle (HVIO) - input : This must be zero unless the caller is a Presentation Manager application, | + | ===== Remarks ===== |
- | ==Return Code== | + | If CursorStartLine and CursorEndLine were originally specified as percentages on [[VioSetCurType]] |
- | | + | |
- | Return code descriptions | + | |
- | * 0 | + | |
- | *355 ERROR_VIO_MODE | + | |
- | *436 ERROR_VIO_INVALID_HANDLE | + | |
- | *465 ERROR_VIO_DETACHED | + | |
- | ==Remarks== | + | ==== Family API Considerations ==== |
- | If CursorStartLine and CursorEndLine were originally specified as percentages on VioSetCurType (using negative values), the positive values into which they were translated are returned. Refer to VioSetCurType for more information on how percentages can be used to set CursorStartLine and CursorEndLine independent of the number of scan lines per character cell. | + | |
- | ===Family API Considerations=== | ||
In DOS mode, VioGetCurType returns only two values for cursorattrib: | In DOS mode, VioGetCurType returns only two values for cursorattrib: | ||
- | ==Example Code== | + | ===== Bindings ===== |
- | === C Binding=== | + | |
- | <PRE> | + | ==== C Binding==== |
+ | <code c> | ||
typedef struct _VIOCURSORINFO { /* vioci */ | typedef struct _VIOCURSORINFO { /* vioci */ | ||
USHORT | USHORT | ||
Line 50: | Line 55: | ||
USHORT | USHORT | ||
- | </PRE> | + | </code> |
- | ===MASM Binding=== | + | ====MASM Binding==== |
- | <PRE> | + | <code asm> |
VIOCURSORINFO struc | VIOCURSORINFO struc | ||
vioci_yStart dw ? ;cursor start line | vioci_yStart dw ? ;cursor start line | ||
Line 69: | Line 74: | ||
Returns WORD | Returns WORD | ||
- | </PRE> | + | </code> |
- | ====== Note ====== | + | ===== Note ===== |
Text based on [[http:// | Text based on [[http:// |