DWRITE_HIT_TEST_METRICS structure (dwrite.h)

Describes the region obtained by a hit test.

Syntax

struct DWRITE_HIT_TEST_METRICS {
  UINT32 textPosition;
  UINT32 length;
  FLOAT  left;
  FLOAT  top;
  FLOAT  width;
  FLOAT  height;
  UINT32 bidiLevel;
  BOOL   isText;
  BOOL   isTrimmed;
};

Members

textPosition

Type: UINT32

The first text position within the hit region.

length

Type: UINT32

The number of text positions within the hit region.

left

Type: FLOAT

The x-coordinate of the upper-left corner of the hit region.

top

Type: FLOAT

The y-coordinate of the upper-left corner of the hit region.

width

Type: FLOAT

The width of the hit region.

height

Type: FLOAT

The height of the hit region.

bidiLevel

Type: UINT32

The BIDI level of the text positions within the hit region.

isText

Type: BOOL

true if the hit region contains text; otherwise, false.

isTrimmed

Type: BOOL

true if the text range is trimmed; otherwise, false.

Requirements

Requirement Value
Minimum supported client Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps | UWP apps]
Minimum supported server Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008 [desktop apps | UWP apps]
Header dwrite.h