Windows Dev Center

ScriptIsComplex function

Determines whether a Unicode string requires complex script processing.

Syntax


HRESULT ScriptIsComplex(
  _In_ const WCHAR *pwcInChars,
  _In_       int   cInChars,
  _In_       DWORD dwFlags
);

Parameters

pwcInChars [in]

Pointer to the string to test.

cInChars [in]

Length of the input string, in characters.

dwFlags [in]

Flags specifying testing details. This parameter can have one of the following values.

ValueMeaning
SIC_ASCIIDIGIT

Treat digits U+0030 to U+0039 as complex. The application sets this flag if the string is displayed with digit substitution enabled. If the application is following the user's National Language Support (NLS) settings using the ScriptRecordDigitSubstitution function, it can pass a SCRIPT_DIGITSUBSTITUTE structure with the DigitSubstitute member set to SCRIPT_DIGITSUBSTITUTE_NONE.

SIC_COMPLEX

Treat complex script letters as complex. This flag should normally be set.

SIC_NEUTRAL

Treat neutrals as complex. The application sets this flag to display the string with right-to-left reading order.

 

Return value

Returns S_OK if the string requires complex script processing. The function returns S_FALSE if the string can be handled by standard API function calls, that is, it contains only characters laid out side-by-side and left-to-right. The function returns a nonzero HRESULT value if it does not succeed.

Remarks

See Displaying Text with Uniscribe for a discussion of the context in which this function is normally called.

Important  Starting with Windows 8: To maintain the ability to run on Windows 7, a module that uses Uniscribe must specify Usp10.lib before gdi32.lib in its library list.
 

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Redistributable

Internet Explorer 5 or later on Windows Me/98/95

Header

Usp10.h

Library

Usp10.lib

DLL

Usp10.dll

See also

Uniscribe
Uniscribe Functions
Displaying Text with Uniscribe
ScriptRecordDigitSubstitution
SCRIPT_DIGITSUBSTITUTE

 

 

Community Additions

ADD
Show:
© 2015 Microsoft