Export (0) Print
Expand All

_ismbc Routines

Each of the _ismbc routines tests a given multibyte character c for a particular condition.

Remarks

The test result of each of the _ismbc routines depends on the multibyte code page in effect. Multibyte code pages have single byte alphabetic characters. By default, the multibyte code page is set to the system-default ANSI code page obtained from the operating system at program startup. You can query or change the multibyte code page in use with _getmbcp or _setmbcp, respectively.

Routine Test condition Code page 932 example
_ismbcalnum Alphanumeric Returns nonzero if and only if c is a single-byte representation of an ASCII English letter: See examples for _ismbcdigit and _ismbcalpha.
_ismbcalpha Alphabetic Returns nonzero if and only if c is a single-byte representation of an ASCII English letter: See examples for _ismbcupper and _ismbclower; or a katakana letter: 0xA6<=c<=0xDF.
_ismbcdigit Digit Returns nonzero if and only if c is a single-byte representation of an ASCII digit: 0x30<=c<=0x39.
_ismbcgraph Graphic Returns nonzero if and only if c is a single-byte representation of any ASCII or katakana printable character except a white space ( ). See examples for _ismbcdigit, _ismbcalpha, and _ismbcpunct.
_ismbclegal Valid multibyte character Returns nonzero if and only if the first byte of c is within ranges 0x81 – 0x9F or 0xE0 – 0xFC, while the second byte is within ranges 0x40 – 0x7E or 0x80 - FC.
_ismbclower Lowercase alphabetic Returns nonzero if and only if c is a single-byte representation of an ASCII lowercase English letter: 0x61<=c<=0x7A.
_ismbcprint Printable Returns nonzero if and only if c is a single-byte representation of any ASCII or katakana printable character including a white space ( ): See examples for _ismbcspace, _ismbcdigit, _ismbcalpha, and _ismbcpunct.
_ismbcpunct Punctuation Returns nonzero if and only if c is a single-byte representation of any ASCII or katakana punctuation character.
_ismbcspace Whitespace Returns nonzero if and only if c is a whitespace character: c=0x20 or 0x09<=c<=0x0D.
_ismbcsymbol Multibyte symbol Returns nonzero if and only if 0x8141<=c<=0x81AC.
_ismbcupper Uppercase alphabetic Returns nonzero if and only if c is a single-byte representation of an ASCII uppercase English letter: 0x41<=c<=0x5A.

Code Page 932 Specific

The following routines are specific to code page 932.

Routine Test condition (code page 932 only)
_ismbchira Double-byte Hiragana: 0x829F<=c<=0x82F1.
_ismbckata Double-byte katakana: 0x8340<=c<=0x8396.
_ismbcl0 JIS non-Kanji: 0x8140<=c<=0x889E.
_ismbcl1 JIS level-1: 0x889F<=c<=0x9872.
_ismbcl2 JIS level-2: 0x989F<=c<=0xEA9E.

_ismbcl0, _ismbcl1, and _ismbcl2 check that the specified value c matches the test conditions described in the preceding table, but do not check that c is a valid multibyte character. If the lower byte is in the ranges 0x00 – 0x3F, 0x7F, or 0xFD – 0xFF, these functions return a nonzero value, indicating that the character satisfies the test condition. Use _ismbbtrail to test whether the multibyte character is defined.

END Code Page 932 Specific

See Also

Character Classification Routines | is, isw Function Overview | _ismbb Routines | Run-Time Routines and .NET Framework Equivalents

Show:
© 2014 Microsoft