Export (0) Print
Expand All
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

GetCharWidth32

Windows Mobile 6.5
A version of this page is also available for
4/8/2010

This function retrieves the widths, in logical coordinates, of consecutive characters in a specified range from the current font.


WINGDIAPI BOOL WINAPI GetCharWidth32(
  HDC hdc,
  UINT iFirstChar,
  UINT iLastChar,
  LPINT lpBuffer
);

hdc

[in] Handle to the device context.

iFirstChar

[in] Unsigned integer that specifies the first character in the group of consecutive characters.

iLastChar

[in] Unsigned integer that specifies the last character in the group of consecutive characters. This last character must not precede the first character that you specified in iFirstChar.

lpBuffer

[out] Pointer to a buffer that receives the character widths, in logical coordinates.

A nonzero value indicates success. Zero indicates failure. To get extended error information, call GetLastError.

The range of characters that you establish by setting iFirstChar and iLastChar is inclusive; that is, the returned widths include the widths of the characters specified by iFirstChar and iLastChar.

If a character does not exist in the current font, GetCharWidth32 assigns the width of the default character to that character.

Headerwindows.h
Librarycoredll.lib
Windows Embedded CEWindows CE .NET 4.0 and later
Windows MobilePocket PC for Windows Mobile Version 5.0 and later, Smartphone for Windows Mobile Version 5.0 and later

Community Additions

Show:
© 2014 Microsoft