Simulation support:

None. This function is mandatory for all drivers.

Description:

GreDeviceQueryFontAttributes stores the metrics of the currently selected font at the location addressed by pfmMetrics. Note that the handling routine must transform device coordinates to world coordinates before returning the results to the calling routine. This transformation can be done by using GreConvert.

This function must be supported by the presentation driver.

#define INCL_GRE_DEVMISC2
#include <os2.h>

HDC             hdc;         /*  Device context handle. */
ULONG           cMetrics;    /*  Size of FONTMETRICS structure. */
PFONTMETRICS    pfmMetrics;  /*  Pointer to FONTMETRICS structure. */
PVOID           pInstance;   /*  Pointer to instance data. */
ULONG           lFunction;   /*  High-order WORD=flags; low-order WORD=NGreDeviceQueryFontAttributes. */
BOOL            rc;          /*  Return Codes. */

rc = GreDeviceQueryFontAttributes(hdc, cMetrics,
       pfmMetrics, pInstance, lFunction);


[Back: GreDeviceQueryFontAttributes]
[Next: GreDeviceQueryFontAttributes Parameter - hdc]