Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

IDWriteTextLayout3::GetLineMetrics method (dwrite_3.h)

Retrieves properties of each line.

Syntax

HRESULT GetLineMetrics(
 [out] DWRITE_LINE_METRICS1 *lineMetrics,
 UINT32 maxLineCount,
 [out] UINT32 *actualLineCount
);

Parameters

[out] lineMetrics

The array to fill with line information.

maxLineCount

The maximum size of the lineMetrics array.

[out] actualLineCount

The actual size of the lineMetrics
array that is needed.

Return value

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

If maxLineCount is not large enough E_NOT_SUFFICIENT_BUFFER,
which is equivalent to HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER),
is returned and actualLineCount is set to the number of lines
needed.

Requirements

Requirement Value
Minimum supported client Windows 10 [desktop apps only]
Minimum supported server Windows Server 2016 [desktop apps only]
Target Platform Windows
Header dwrite_3.h
Library Dwrite.lib
DLL Dwrite.dll

See also

IDWriteTextLayout3


Feedback

Was this page helpful?

Additional resources