EE_IS_CHAR_HALF_OR_FULL

Determines whether a specified character expressed as a (1) UTF-16 character value or (2) scaler value is a half-width or full-width character. (3) It can also count the total widths of the specified string. You can send this message explicitly or use the Editor_IsCharHalfOrFull inline function.

(1) EE_IS_CHAR_HALF_OR_FULL
(WCHAR)wParam = ch
(int)lParam = 0
(2) EE_IS_CHAR_HALF_OR_FULL
(UINT)wParam = nScaler
(int)lParam = -1
(3) EE_IS_CHAR_HALF_OR_FULL
(INT_PTR)wParam = cchStr
(LPCWSTR)lParam = pStr

Parameters

ch

The Unicode character to be queried.

ch

(1) The Unicode character to be queried expressed as a UTF-16 character value.

nScaler

(2) The Unicode character to be queried expressed as a scaler value.

pStr

(3) The UTF-16 string to be queried.

cchStr

(3) The length of the string in characters to be queried.

Return Values

(1) Returns 1 if ch is a halfwidth character, or returns 2 if ch is a fullwidth or a high or low surrogate character. It may return 0 if the specified character does not advance the character position.

(2) Returns 1 if nScaler is a halfwidth character, or returns 2 if nScaler is a fullwidth character. It may return 0 if the specified character does not advance the character position.

(3) Returns the total number of widths of the specified string and length.