---
name: "GetCharacterPlacementW"
section: "3w"
platform: "linux"
package: "libwine-dev"
version: "1.4.1-4"
release: "Debian 7 (Wheezy)"
platforms: ["linux"]
url: "https://new.carta.tech/GetCharacterPlacementW"
---

# GetCharacterPlacementW(3w)

## NAME

**GetCharacterPlacementW** (GDI32.@)

## SYNOPSIS

DWORD GetCharacterPlacementW\
  (\
   HDC           *hdc*,\
   LPCWSTR       *lpString*,\
   INT           *uCount*,\
   INT           *nMaxExtent*,\
   GCP\_RESULTSW\* *lpResults*,\
   DWORD         *dwFlags*\
  )

## PARAMS

*hdc* **\[In\]**  Device context for which the rendering is to be done.

*lpString* **\[In\]**  The string for which information is to be returned.

*uCount* **\[In\]**  Number of **WORDS** in string.

*nMaxExtent* **\[In\]**  Maximum extent the string is to take (in **HDC** logical units).

*lpResults* **\[In/Out\]**  A pointer to a **GCP\_RESULTSW** struct.

**\[In\]**  Flags specifying how to process the string.

## DESCRIPTION

Retrieve information about a string. This includes the width, reordering, Glyphing and so on.

## RETURNS

The width and height of the string if successful, **0** if failed.

## BUGS

All flags except **GCP\_REORDER** are not yet implemented. Reordering is not 100% compliant to the Windows(tm) BiDi method. Caret positioning is not yet implemented for BiDi. Classes are not yet implemented.

## IMPLEMENTATION

Declared in **"wingdi.h"**.

Implemented in **"dlls/gdi32/font.c"**.

Debug channel **"font"**.
