Jump to content

GreAreaSetAttributes: Difference between revisions

From EDM2
Tag: Manual revert
No edit summary
 
Line 1: Line 1:
This function is simulated by a handling routine in the graphics engine.
GreAreaSetAttributes is called by the graphics engine after processing a call to GreSetAttrs received inside an area or path bracket. The handling routine in the graphics engine does nothing. Its purpose is to provide an entry in the dispatch table that can be hooked by presentation drivers. This function must be hooked by presentation drivers that perform their own area or path simulations.


GreAreaSetAttributes is called by the graphics engine after processing a call to GreSetAttrs received inside an area or path bracket. The handling routine in the graphics engine does nothing. Its purpose is to provide an entry in the dispatch table that can be hooked by presentation drivers. This function must be hooked by presentation drivers that perform their own area or path simulations.
; Simulation support: This function is simulated by a handling routine in the graphics engine.  


==Syntax==
==Syntax==
Line 7: Line 7:


==Parameters==
==Parameters==
;hdc (HDC) - input;Device context handle.
;''hdc'' ([[HDC]]) - input:Device context handle.
;lPrimType (LONG) - input; Bundle primitive type.
;''lPrimType'' ([[LONG]]) - input: Bundle primitive type.
::PRIM_LINE Line attribute bundle
::PRIM_LINE Line attribute bundle
::PRIM_CHAR Character attribute bundle
::PRIM_CHAR Character attribute bundle
Line 14: Line 14:
::PRIM_AREA Pattern attribute bundle
::PRIM_AREA Pattern attribute bundle
::PRIM_IMAGE Image attribute bundle
::PRIM_IMAGE Image attribute bundle
;flDefsMask (ULONG) - input; Flags attributes for default. Flags indicating which attributes are to be set to default.
;''flDefsMask'' (ULONG) - input: Flags attributes for default. Flags indicating which attributes are to be set to default.
;flAttrsMask (ULONG) - input; Flags attributes for modification. Flags indicating which attributes are to be modified.
;''flAttrsMask'' (ULONG) - input: Flags attributes for modification. Flags indicating which attributes are to be modified.
;pAttrs (PBUNDLE) - input : Pointer to fixed-format record bundle.
;''pAttrs'' (PBUNDLE) - input : Pointer to fixed-format record bundle.
::This is a pointer to the fixed-format bundle record containing the attribute values to be set as specified by flAttrsMask. Only the attribute fields corresponding to attribute flags set in flAttrsMask, and not set in flDefsMask, contain valid values. This buffer must only be large enough to contain data for the highest offset attribute referenced.
::This is a pointer to the fixed-format bundle record containing the attribute values to be set as specified by flAttrsMask. Only the attribute fields corresponding to attribute flags set in flAttrsMask, and not set in flDefsMask, contain valid values. This buffer must only be large enough to contain data for the highest offset attribute referenced.
;pInstance (PVOID) - input : Pointer to instance data.
;''pInstance'' ([[PVOID]]) - input : Pointer to instance data.
;lFunction (ULONG) - input : High-order WORD=flags; low-order WORD=NGreAreaSetAttributes.
;''lFunction'' (ULONG) - input : High-order WORD=flags; low-order WORD=NGreAreaSetAttributes.


==Return Code==
==Return Code==
;fSuccess (BOOL) - returns : This function returns BOOLEAN (fSuccess).
;fSuccess ([[BOOL]]) - returns : This function returns BOOLEAN (fSuccess).
::TRUE Successful  
::TRUE Successful  
::FALSE Error
::FALSE Error
==Remarks==


==Example Code==
==Example Code==
Line 43: Line 41:
fSuccess = GreAreaSetAttributes(hdc, lPrimType, flDefsMask, flAttrsMask, pAttrs, pInstance, lFunction);
fSuccess = GreAreaSetAttributes(hdc, lPrimType, flDefsMask, flAttrsMask, pAttrs, pInstance, lFunction);
</PRE>
</PRE>
==Related Functions==
* GreSetAttrs


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

Latest revision as of 19:31, 19 May 2025

GreAreaSetAttributes is called by the graphics engine after processing a call to GreSetAttrs received inside an area or path bracket. The handling routine in the graphics engine does nothing. Its purpose is to provide an entry in the dispatch table that can be hooked by presentation drivers. This function must be hooked by presentation drivers that perform their own area or path simulations.

Simulation support
This function is simulated by a handling routine in the graphics engine.

Syntax

GreAreaSetAttributes(hdc, lPrimType, flDefsMask, flAttrsMask, pAttrs, pInstance, lFunction)

Parameters

hdc (HDC) - input
Device context handle.
lPrimType (LONG) - input
Bundle primitive type.
PRIM_LINE Line attribute bundle
PRIM_CHAR Character attribute bundle
PRIM_MARKER Marker attribute bundle
PRIM_AREA Pattern attribute bundle
PRIM_IMAGE Image attribute bundle
flDefsMask (ULONG) - input
Flags attributes for default. Flags indicating which attributes are to be set to default.
flAttrsMask (ULONG) - input
Flags attributes for modification. Flags indicating which attributes are to be modified.
pAttrs (PBUNDLE) - input
Pointer to fixed-format record bundle.
This is a pointer to the fixed-format bundle record containing the attribute values to be set as specified by flAttrsMask. Only the attribute fields corresponding to attribute flags set in flAttrsMask, and not set in flDefsMask, contain valid values. This buffer must only be large enough to contain data for the highest offset attribute referenced.
pInstance (PVOID) - input
Pointer to instance data.
lFunction (ULONG) - input
High-order WORD=flags; low-order WORD=NGreAreaSetAttributes.

Return Code

fSuccess (BOOL) - returns
This function returns BOOLEAN (fSuccess).
TRUE Successful
FALSE Error

Example Code

#define INCL_GRE_PATHS
#include <os2.h>
HDC     hdc;         /* Device context handle. */
LONG    lPrimType;   /* Bundle primitive type. */
ULONG   flDefsMask;  /* Flags attributes for default. */
ULONG   flAttrsMask; /* Flags attributes for modification. */
PBUNDLE pAttrs;      /* Pointer to fixed-format record bundle. */
PVOID   pInstance;   /* Pointer to instance data. */
ULONG   lFunction;   /* High-order WORD=flags; low-order WORD=NGreAreaSetAttributes. */
BOOL    fSuccess;    /* This function returns BOOLEAN (fSuccess). */

fSuccess = GreAreaSetAttributes(hdc, lPrimType, flDefsMask, flAttrsMask, pAttrs, pInstance, lFunction);