ImmGetCompositionString

This function retrieves information about the composition string.

LONG ImmGetCompositionString(
HIMC hIMC, 
DWORD dwIndex, 
LPVOID lpBuf, 
DWORD dwBufLen);

Parameters

  • hIMC
    [in] Handle to the input context. In Windows CE versions 2.10 and later, if hIMC is NULL, then the length of the composition string, dwBufLen, is returned for the current active context.
  • dwIndex
    [in] Specifies the index of the information to retrieve. For each value except GCS_CURSORPOS and GCS_DELTASTART, the function copies the requested information to the specified buffer. The function returns the cursor and delta position values in the low 16-bits of the return value.
  • lpBuf
    [out] Long pointer to the buffer that receives the requested information.
  • dwBufLen
    [in] Specifies the size of the buffer, in bytes. If zero, the ImmGetCompositionString function returns the buffer size needed for the complete information.

Return Values

The number of bytes copied to the destination buffer or, if dwBufLen is zero, the buffer size, in bytes, needed to receive all of the requested information indicates success. IMM_ERROR_NODATA indicates that the composition data is not ready in the input context. IMM_ERROR_GENERAL indicates that a general error was detected by IME.

Remarks

An application calls this function in response to the WM_IME_COMPOSITION or WM_IME_STARTCOMPOSITION message. The IMM removes the information when an application calls the ImmReleaseContext function.

Requirements

Runs on Versions Defined in Include Link to
Windows CE OS 2.10 and later (Japanese version 1.0 and later) Imm.h   Coreimm.lib

Note   This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.

See Also

ImmReleaseContext, WM_IME_COMPOSITION

 Last updated on Tuesday, July 13, 2004

© 1992-2000 Microsoft Corporation. All rights reserved.