Jump to content

GreSetColorCursor: Difference between revisions

From EDM2
Created page with "GreSetColorCursor sets the bit maps that define a color cursor or pointer. ;Simulation support: This function is mandatory for display drivers. For other drivers, it is simu..."
 
Ak120 (talk | contribs)
mNo edit summary
 
Line 1: Line 1:
GreSetColorCursor sets the bit maps that define a color cursor or pointer.  
GreSetColorCursor sets the bit maps that define a color cursor or pointer.


;Simulation support: This function is mandatory for display drivers. For other drivers, it is simulated by a handling routine in the graphics engine.  
;Simulation support: This function is mandatory for display drivers. For other drivers, it is simulated by a handling routine in the graphics engine.


==Syntax==
==Syntax==
  GreSetColorCursor(hdc, pPointerInfo, pInstance, lFunction);
  GreSetColorCursor(hdc, pPointerInfo, pInstance, lFunction)


==Parameters==
==Parameters==
;hdc (HDC) - input  
;hdc (HDC) - input:The device context handle.
:The device context handle.  
;pPointerInfo (PPOINTERINFO) - input:A pointer to a pointer information structure.
 
;pInstance (PVOID) - input:A pointer to instance data.
;pPointerInfo (PPOINTERINFO) - input  
;lFunction (ULONG) - input:High-order WORD=flags; low-order WORD=NGreDeviceSetCursor.
:A pointer to a pointer information structure.  
 
;pInstance (PVOID) - input  
:A pointer to instance data.  
 
;lFunction (ULONG) - input  
:High-order WORD=flags; low-order WORD=NGreDeviceSetCursor.  


==Return Code==
==Return Code==
;fSuccess (BOOL) - returns  
;fSuccess (BOOL) - returns:Return codes.
:Return codes.  
:On completion, the handling routine must return BOOLEAN (fSuccess).
 
:*TRUE Successful
:On completion, the handling routine must return BOOLEAN (fSuccess).  
:*FALSE Error
 
:Possible Errors Detected: When an error is detected, the handling routine must call WinSetErrorInfo to post the condition. Error codes for conditions that the handling routine is expected to check include:
:*TRUE Successful  
:*PMERR_DEV_FUNC_NOT_INSTALLED
:*FALSE Error  
:*PMERR_INV_COORDINATE
 
:*PMERR_INV_CURSOR_BITMAP
:Possible Errors Detected: When an error is detected, the handling routine must call WinSetErrorInfo to post the condition. Error codes for conditions that the handling routine is expected to check include:  
:*PMERR_INV_HDC
 
:*PMERR_DEV_FUNC_NOT_INSTALLED  
:*PMERR_INV_COORDINATE  
:*PMERR_INV_CURSOR_BITMAP  
:*PMERR_INV_HDC  
 


==Remarks==
==Remarks==
The handling routine in the presentation driver updates its copy of the pointer definition to that identified by pPointerInfo.  
The handling routine in the presentation driver updates its copy of the pointer definition to that identified by pPointerInfo.


==Declaration==
==Declaration==
Line 52: Line 39:
fSuccess = GreSetColorCursor(hdc, pPointerInfo, pInstance, lFunction);
fSuccess = GreSetColorCursor(hdc, pPointerInfo, pInstance, lFunction);
</PRE>
</PRE>


[[Category:Gre]]
[[Category:Gre]]

Latest revision as of 16:11, 29 February 2020

GreSetColorCursor sets the bit maps that define a color cursor or pointer.

Simulation support
This function is mandatory for display drivers. For other drivers, it is simulated by a handling routine in the graphics engine.

Syntax

GreSetColorCursor(hdc, pPointerInfo, pInstance, lFunction)

Parameters

hdc (HDC) - input
The device context handle.
pPointerInfo (PPOINTERINFO) - input
A pointer to a pointer information structure.
pInstance (PVOID) - input
A pointer to instance data.
lFunction (ULONG) - input
High-order WORD=flags; low-order WORD=NGreDeviceSetCursor.

Return Code

fSuccess (BOOL) - returns
Return codes.
On completion, the handling routine must return BOOLEAN (fSuccess).
  • TRUE Successful
  • FALSE Error
Possible Errors Detected: When an error is detected, the handling routine must call WinSetErrorInfo to post the condition. Error codes for conditions that the handling routine is expected to check include:
  • PMERR_DEV_FUNC_NOT_INSTALLED
  • PMERR_INV_COORDINATE
  • PMERR_INV_CURSOR_BITMAP
  • PMERR_INV_HDC

Remarks

The handling routine in the presentation driver updates its copy of the pointer definition to that identified by pPointerInfo.

Declaration

#define INCL_WINPOINTERS
#include <os2.h>

HDC             hdc;           /*  The device context handle. */
PPOINTERINFO    pPointerInfo;  /*  A pointer to a pointer information structure. */
PVOID           pInstance;     /*  A pointer to instance data. */
ULONG           lFunction;     /*  High-order WORD=flags; low-order WORD=NGreDeviceSetCursor. */
BOOL            fSuccess;      /*  Return codes. */

fSuccess = GreSetColorCursor(hdc, pPointerInfo, pInstance, lFunction);