Tizen Native API
3.0
|
The Uchar module provides low-level access to the Unicode Character Database.
Required Header
#include <utils_i18n.h>
Overview
The Uchar module provides low-level access to the Unicode Character Database.
Sample Code 1
Gets the property value of 'east asian width' among an enumerated property, and the unicode allocation block that contains the character.
int ret = I18N_ERROR_NONE; i18n_uchar32 code_point = 0; int property_value = 0; i18n_uchar_u_east_asian_width_e east_asian_width = I18N_UCHAR_U_EA_NEUTRAL; i18n_uchar_ublock_code_e block_code = I18N_UCHAR_UBLOCK_NO_BLOCK; // How to get the east asian width type for 's' code_point = 0x73; // 's' ret = i18n_uchar_get_int_property_value(code_point, I18N_UCHAR_EAST_ASIAN_WIDTH, &property_value); if (ret != I18N_ERROR_NONE) { dlog_print(DLOG_INFO, LOG_TAG, "Error occured!!\n"); } else { east_asian_width = (i18n_uchar_u_east_asian_width_e)property_value; dlog_print(DLOG_INFO, LOG_TAG, "East Asian Width Type for ( %.4x ) is ( %d )\n", code_point, east_asian_width); // East Asian Width Type for ( 0073 ) is ( 4 ) which is I18N_UCHAR_U_EA_NARROW } // How to get the block code for 's' ret = i18n_uchar_get_ublock_code(code_point, &block_code); if (ret != I18N_ERROR_NONE) { dlog_print(DLOG_INFO, LOG_TAG, "Error occured!!\n"); } else { dlog_print(DLOG_INFO, LOG_TAG, "block name for ( %.4x ) is ( %d )\n", code_point, block_code); // block code for ( 0073 ) is ( 1 ) which is I18N_UCHAR_UBLOCK_BASIC_LATIN } // How to get the east asian width type for 'sung' as ideographs code_point = 0x661F; // 'sung' as ideographs ret = i18n_uchar_get_int_property_value(code_point, I18N_UCHAR_EAST_ASIAN_WIDTH, &property_value); if (ret != I18N_ERROR_NONE) { dlog_print(DLOG_INFO, LOG_TAG, "Error occured!!\n"); } else { east_asian_width = (i18n_uchar_u_east_asian_width_e)property_value; dlog_print(DLOG_INFO, LOG_TAG, "East Asian Width Type for ( %.4x ) is ( %d )\n", code_point, east_asian_width); // East Asian Width Type for ( 661f ) is ( 5 ) which is I18N_UCHAR_U_EA_WIDE } // How to get the block code for 'sung' as ideographs ret = i18n_uchar_get_ublock_code(code_point, &block_code); if (ret != I18N_ERROR_NONE) { dlog_print(DLOG_INFO, LOG_TAG, "Error occured!!\n"); } else { dlog_print(DLOG_INFO, LOG_TAG, "block name for ( %.4x ) is ( %d )\n", code_point, block_code); // block code for ( 661f ) is ( 71 ) which is I18N_UCHAR_UBLOCK_CJK_UNIFIED_IDEOGRAPHS } // How to get the east asian width type for 'sung' as hangul code_point = 0xC131; // 'sung' as hangul ret = i18n_uchar_get_int_property_value(code_point, I18N_UCHAR_EAST_ASIAN_WIDTH, &property_value); if (ret != I18N_ERROR_NONE) { dlog_print(DLOG_INFO, LOG_TAG, "Error occured!!\n"); } else { east_asian_width = (i18n_uchar_u_east_asian_width_e)property_value; dlog_print(DLOG_INFO, LOG_TAG, "East Asian Width Type for ( %.4x ) is ( %d )\n", code_point, east_asian_width); // East Asian Width Type for ( c131 ) is ( 5 ) which is I18N_UCHAR_U_EA_WIDE } // How to get the block code for 'sung' as hangul ret = i18n_uchar_get_ublock_code(code_point, &block_code); if (ret != I18N_ERROR_NONE) { dlog_print(DLOG_INFO, LOG_TAG, "Error occured!!\n"); } else { dlog_print(DLOG_INFO, LOG_TAG, "block name for ( %.4x ) is ( %d )\n", code_point, block_code); // block code for ( c131 ) is ( 74 ) which is I18N_UCHAR_UBLOCK_HANGUL_SYLLABLES }
Define Documentation
#define I18N_U_FOLD_CASE_DEFAULT 0 |
Option value for case folding: use default mappings defined in CaseFolding.txt.
- Since :
- 2.3.1
#define I18N_U_FOLD_CASE_EXCLUDE_SPECIAL_I 1 |
Option value for case folding:
Use the modified set of mappings provided in CaseFolding.txt to handle dotted I and dotless i appropriately for Turkic languages (tr, az).
Before Unicode 3.2, CaseFolding.txt contains mappings marked with 'I' that are to be included for default mappings and excluded for the Turkic-specific mappings.
Unicode 3.2 CaseFolding.txt instead contains mappings marked with 'T' that are to be excluded for default mappings and included for the Turkic-specific mappings.
- Since :
- 2.3.1
#define I18N_U_GC_C_MASK (I18N_U_GC_CN_MASK|I18N_U_GC_CC_MASK|I18N_U_GC_CF_MASK|I18N_U_GC_CO_MASK|I18N_U_GC_CS_MASK) |
Mask constant for multiple i18n_uchar_category_e bits (C Others).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
U_GC_XX_MASK constants are bit flags corresponding to Unicode general category values.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
#define I18N_U_GC_L_MASK (I18N_U_GC_LU_MASK|I18N_U_GC_LL_MASK|I18N_U_GC_LT_MASK|I18N_U_GC_LM_MASK|I18N_U_GC_LO_MASK) |
Mask constant for multiple i18n_uchar_category_e bits (L Letters).
- Since :
- 2.3.1
Mask constant for multiple i18n_uchar_category_e bits (LC Cased Letters).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for multiple i18n_uchar_category_e bits (M Marks).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for multiple i18n_uchar_category_e bits (N Numbers).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
#define I18N_U_GC_P_MASK (I18N_U_GC_PD_MASK|I18N_U_GC_PS_MASK|I18N_U_GC_PE_MASK|I18N_U_GC_PC_MASK|I18N_U_GC_PO_MASK|I18N_U_GC_PI_MASK|I18N_U_GC_PF_MASK) |
Mask constant for multiple i18n_uchar_category_e bits (P Punctuation).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for multiple i18n_uchar_category_e bits (S Symbols).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for multiple i18n_uchar_category_e bits (Z Separators).
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
Mask constant for a i18n_uchar_category_e.
- Since :
- 2.3.1
#define I18N_U_GET_GC_MASK | ( | c | ) | I18N_U_MASK(u_charType(c)) |
Get a single-bit bit set for the general category of a character.
- Since :
- 2.3.1
#define I18N_U_MASK | ( | x | ) | ((uint32_t)1<<(x)) |
Get a single-bit bit set (a flag) from a bit number 0..31.
- Since :
- 2.3.1
#define I18N_U_NO_NUMERIC_VALUE ((double)-123456789.) |
Special value that is returned by i18n_uchar_get_numeric_value()(not implemented yet) when no numeric value is defined for a code point.
- Since :
- 2.3.1
#define I18N_USEARCH_DONE -1 |
DONE is returned by i18n_usearch_previous() and i18n_usearch_next() after all valid matches have been returned, and by, i18n_usearch_first() and i18n_usearch_last() if there are no matches at all.
- Since :
- 2.3.1
Typedef Documentation
typedef int8_t i18n_ubool |
i18n_ubool.
- Since :
- 2.3.1
typedef uint16_t i18n_uchar |
i18n_uchar.
- Since :
- 2.3.1
typedef int32_t i18n_uchar32 |
i18n_uchar32.
- Since :
- 2.3.1
Enumeration Type Documentation
Enumeration for Unicode general category types.
- Since :
- 2.3.1
- Enumerator:
I18N_UCHAR_U_UNASSIGNED Non-category for unassigned and non-character code points
I18N_UCHAR_U_GENERAL_OTHER_TYPES Cn "Other, Not Assigned (no characters in [UnicodeData.txt] have this property)" (same as I18N_UCHAR_U_UNASSIGNED!)
I18N_UCHAR_U_UPPERCASE_LETTER Lu
I18N_UCHAR_U_LOWERCASE_LETTER Ll
I18N_UCHAR_U_TITLECASE_LETTER Lt
I18N_UCHAR_U_MODIFIER_LETTER Lm
I18N_UCHAR_U_OTHER_LETTER Lo
I18N_UCHAR_U_NON_SPACING_MARK Mn
I18N_UCHAR_U_ENCLOSING_MARK Me
I18N_UCHAR_U_COMBINING_SPACING_MARK Mc
I18N_UCHAR_U_DECIMAL_DIGIT_NUMBER Nd
I18N_UCHAR_U_LETTER_NUMBER Nl
I18N_UCHAR_U_OTHER_NUMBER No
I18N_UCHAR_U_SPACE_SEPARATOR Zs
I18N_UCHAR_U_LINE_SEPARATOR Zl
I18N_UCHAR_U_PARAGRAPH_SEPARATOR Zp
I18N_UCHAR_U_CONTROL_CHAR Cc
I18N_UCHAR_U_FORMAT_CHAR Cf
I18N_UCHAR_U_PRIVATE_USE_CHAR Co
I18N_UCHAR_U_SURROGATE Cs
I18N_UCHAR_U_DASH_PUNCTUATION Pd
I18N_UCHAR_U_START_PUNCTUATION Ps
I18N_UCHAR_U_END_PUNCTUATION Pe
I18N_UCHAR_U_CONNECTOR_PUNCTUATION Pc
I18N_UCHAR_U_OTHER_PUNCTUATION Po
I18N_UCHAR_U_MATH_SYMBOL Sm
I18N_UCHAR_U_CURRENCY_SYMBOL Sc
I18N_UCHAR_U_MODIFIER_SYMBOL Sk
I18N_UCHAR_U_OTHER_SYMBOL So
I18N_UCHAR_U_INITIAL_PUNCTUATION Pi
I18N_UCHAR_U_FINAL_PUNCTUATION Pf
I18N_UCHAR_U_CHAR_CATEGORY_COUNT One higher than the last enum i18n_uchar_category_e constant
Enumeration for the language directional property of a character set.
- Since :
- 2.3.1
- Enumerator:
Enumeration for Decomposition Type constants.
- Since :
- 2.3.1
- Enumerator:
Enumeration for Grapheme Cluster Break constants.
- Since :
- 2.3.1
- Enumerator:
Enumeration for Hangul Syllable Type constants.
- Since :
- 2.3.1
Enumeration for Joining Group constants.
- Since :
- 2.3.1
- Enumerator:
Enumeration for Line Break constants.
- Since :
- 2.3.1
- Enumerator:
Enumeration for Sentence Break constants.
- Since :
- 2.3.1
- Enumerator:
Enumeration for Word Break constants.
- Since :
- 2.3.1
- Enumerator:
Constants for Unicode blocks, see the Unicode Data file Blocks.txt.
- Since :
- 2.3.1
- Enumerator:
Enumeration of constants for Unicode properties. The properties APIs are intended to reflect Unicode properties as defined in the Unicode Character Database (UCD) and Unicode Technical Reports (UTR). For details about the properties see http://www.unicode.org/ucd/ . For names of Unicode properties see the UCD file PropertyAliases.txt.
- Since :
- 2.3.1
- Enumerator:
I18N_UCHAR_ALPHABETIC Binary property Alphabetic.
Lu+Ll+Lt+Lm+Lo+Nl+Other_AlphabeticI18N_UCHAR_BINARY_START First constant for binary Unicode properties.
I18N_UCHAR_ASCII_HEX_DIGIT Binary property ASCII_Hex_Digit.
0-9 A-F a-fI18N_UCHAR_BIDI_CONTROL Binary property Bidi_Control.
Format controls which have specific functions in the Bidi Algorithm.I18N_UCHAR_BIDI_MIRRORED Binary property Bidi_Mirrored.
Characters that may change display in RTL text. See Bidi Algorithm, UTR 9.I18N_UCHAR_DASH Binary property Dash.
Variations of dashes.I18N_UCHAR_DEFAULT_IGNORABLE_CODE_POINT Binary property Default_Ignorable_Code_Point (new in Unicode 3.2).
Ignorable in most processing. <2060..206F, FFF0..FFFB, E0000..E0FFF>+Other_Default_Ignorable_Code_Point+(Cf+Cc+Cs-White_Space)I18N_UCHAR_DEPRECATED Binary property Deprecated (new in Unicode 3.2).
The usage of deprecated characters is strongly discouraged.I18N_UCHAR_DIACRITIC Binary property Diacritic.
Characters that linguistically modify the meaning of another character to which they apply.I18N_UCHAR_EXTENDER Binary property Extender.
Extend the value or shape of a preceding alphabetic character, e.g. length and iteration marks.I18N_UCHAR_FULL_COMPOSITION_EXCLUSION Binary property Full_Composition_Exclusion.
CompositionExclusions.txt+Singleton Decompositions+ Non-Starter Decompositions.I18N_UCHAR_GRAPHEME_BASE Binary property Grapheme_Base (new in Unicode 3.2).
For programmatic determination of grapheme cluster boundaries. [0..10FFFF]-Cc-Cf-Cs-Co-Cn-Zl-Zp-Grapheme_Link-Grapheme_Extend-CGJI18N_UCHAR_GRAPHEME_EXTEND Binary property Grapheme_Extend (new in Unicode 3.2).
For programmatic determination of grapheme cluster boundaries. Me+Mn+Mc+Other_Grapheme_Extend-Grapheme_Link-CGJI18N_UCHAR_GRAPHEME_LINK Binary property Grapheme_Link (new in Unicode 3.2).
For programmatic determination of grapheme cluster boundaries.I18N_UCHAR_HEX_DIGIT Binary property Hex_Digit.
Characters commonly used for hexadecimal numbers.I18N_UCHAR_HYPHEN Binary property Hyphen.
Dashes used to mark connections between pieces of words, plus the Katakana middle dot.I18N_UCHAR_ID_CONTINUE Binary property ID_Continue.
Characters that can continue an identifier. DerivedCoreProperties.txt also says "NOTE: Cf characters should be filtered out." ID_Start+Mn+Mc+Nd+PcI18N_UCHAR_ID_START Binary property ID_Start.
Characters that can start an identifier. Lu+Ll+Lt+Lm+Lo+NlI18N_UCHAR_IDEOGRAPHIC Binary property Ideographic.
CJKV ideographs.I18N_UCHAR_IDS_BINARY_OPERATOR Binary property IDS_Binary_Operator (new in Unicode 3.2).
For programmatic determination of Ideographic Description Sequences.I18N_UCHAR_IDS_TRINARY_OPERATOR Binary property IDS_Trinary_Operator (new in Unicode 3.2).
For programmatic determination of Ideographic Description Sequences.I18N_UCHAR_JOIN_CONTROL Binary property Join_Control.
Format controls for cursive joining and ligation.I18N_UCHAR_LOGICAL_ORDER_EXCEPTION Binary property Logical_Order_Exception (new in Unicode 3.2).
Characters that do not use logical order and require special handling in most processing.I18N_UCHAR_LOWERCASE Binary property Lowercase.
Ll+Other_LowercaseI18N_UCHAR_MATH Binary property Math.
Sm+Other_MathI18N_UCHAR_NONCHARACTER_CODE_POINT Binary property Noncharacter_Code_Point.
Code points that are explicitly defined as illegal for the encoding of characters.I18N_UCHAR_QUOTATION_MARK Binary property Quotation_Mark.
I18N_UCHAR_RADICAL Binary property Radical (new in Unicode 3.2).
For programmatic determination of Ideographic Description Sequences.I18N_UCHAR_SOFT_DOTTED Binary property Soft_Dotted (new in Unicode 3.2).
Characters with a "soft dot", like i or j. An accent placed on these characters causes the dot to disappear.I18N_UCHAR_TERMINAL_PUNCTUATION Binary property Terminal_Punctuation.
Punctuation characters that generally mark the end of textual units.I18N_UCHAR_UNIFIED_IDEOGRAPH Binary property Unified_Ideograph (new in Unicode 3.2).
For programmatic determination of Ideographic Description Sequences.I18N_UCHAR_UPPERCASE Binary property Uppercase.
Lu+Other_UppercaseI18N_UCHAR_WHITE_SPACE Binary property White_Space.
Space characters+TAB+CR+LF-ZWSP-ZWNBSPI18N_UCHAR_XID_CONTINUE Binary property XID_Continue.
ID_Continue modified to allow closure under normalization forms NFKC and NFKD.I18N_UCHAR_XID_START Binary property XID_Start.
ID_Start modified to allow closure under normalization forms NFKC and NFKD.I18N_UCHAR_CASE_SENSITIVE Binary property Case_Sensitive.
Either the source of a case mapping or in the target of a case mapping. Not the same as the general category Cased_Letter.I18N_UCHAR_S_TERM Binary property STerm (new in Unicode 4.0.1).
I18N_UCHAR_VARIATION_SELECTOR Binary property Variation_Selector (new in Unicode 4.0.1).
Indicates all those characters that qualify as Variation Selectors.I18N_UCHAR_NFD_INERT Binary property NFD_Inert.
ICU-specific property for characters that are inert under NFD, i.e., they do not interact with adjacent characters.I18N_UCHAR_NFKD_INERT Binary property NFKD_Inert.
ICU-specific property for characters that are inert under NFKD, i.e., they do not interact with adjacent characters.I18N_UCHAR_NFC_INERT Binary property NFC_Inert.
ICU-specific property for characters that are inert under NFC, i.e., they do not interact with adjacent characters.I18N_UCHAR_NFKC_INERT Binary property NFKC_Inert.
ICU-specific property for characters that are inert under NFKC, i.e., they do not interact with adjacent characters.I18N_UCHAR_SEGMENT_STARTER Binary Property Segment_Starter.
Property for characters that are starters in terms of Unicode normalization and combining character sequences. They have ccc=0 and do not occur in non-initial position of the canonical decomposition of any character (like a-umlaut in NFD and a Jamo T in an NFD(Hangul LVT)).I18N_UCHAR_PATTERN_SYNTAX Binary property Pattern_Syntax (new in Unicode 4.1).
I18N_UCHAR_PATTERN_WHITE_SPACE Binary property Pattern_White_Space (new in Unicode 4.1).
I18N_UCHAR_POSIX_ALNUM Binary property alnum (a C/POSIX character class).
I18N_UCHAR_POSIX_BLANK Binary property blank (a C/POSIX character class).
I18N_UCHAR_POSIX_GRAPH Binary property graph (a C/POSIX character class).
I18N_UCHAR_POSIX_PRINT Binary property print (a C/POSIX character class).
I18N_UCHAR_POSIX_XDIGIT Binary property xdigit (a C/POSIX character class).
I18N_UCHAR_CASED Binary property Cased.
For Lowercase, Uppercase and Titlecase characters.I18N_UCHAR_CASE_IGNORABLE Binary property Case_Ignorable.
Used in context-sensitive case mappings.I18N_UCHAR_CHANGES_WHEN_LOWERCASED Binary property Changes_When_Lowercased.
I18N_UCHAR_CHANGES_WHEN_UPPERCASED Binary property Changes_When_Uppercased.
I18N_UCHAR_CHANGES_WHEN_TITLECASED Binary property Changes_When_Titlecased.
I18N_UCHAR_CHANGES_WHEN_CASEFOLDED Binary property Changes_When_Casefolded.
I18N_UCHAR_CHANGES_WHEN_CASEMAPPED Binary property Changes_When_Casemapped.
I18N_UCHAR_CHANGES_WHEN_NFKC_CASEFOLDED Binary property Changes_When_NFKC_Casefolded.
I18N_UCHAR_BINARY_LIMIT One more than the last constant for binary Unicode properties.
I18N_UCHAR_BIDI_CLASS Enumerated property Bidi_Class.
Same as u_charDirection, returns i18n_uchar_direction_e values.I18N_UCHAR_INT_START First constant for enumerated/integer Unicode properties.
I18N_UCHAR_BLOCK Enumerated property Block.
Returns i18n_uchar_ublock_code_e values.I18N_UCHAR_CANONICAL_COMBINING_CLASS Enumerated property Canonical_Combining_Class.
Returns 8-bit numeric values.I18N_UCHAR_DECOMPOSITION_TYPE Enumerated property Decomposition_Type.
Returns i18n_uchar_u_decomposition_type_e values.I18N_UCHAR_EAST_ASIAN_WIDTH Enumerated property East_Asian_Width.
Returns i18n_uchar_u_east_asian_width_e values.I18N_UCHAR_GENERAL_CATEGORY Enumerated property General_Category.
Returns i18n_uchar_category_e values.I18N_UCHAR_JOINING_GROUP Enumerated property Joining_Group.
Returns i18n_uchar_u_joining_group_e values.I18N_UCHAR_JOINING_TYPE Enumerated property Joining_Type.
Returns i18n_uchar_u_joining_type_e values.I18N_UCHAR_LINE_BREAK Enumerated property Line_Break.
Returns i18n_uchar_u_line_break_e values.I18N_UCHAR_NUMERIC_TYPE Enumerated property Numeric_Type.
Returns i18n_uchar_u_numeric_type_e values.I18N_UCHAR_SCRIPT Enumerated property Script.
Returns i18n_uscript_code_e values.I18N_UCHAR_HANGUL_SYLLABLE_TYPE Enumerated property Hangul_Syllable_Type, new in Unicode 4.
Returns i18n_uchar_u_hangul_syllable_type_e values.I18N_UCHAR_NFD_QUICK_CHECK Enumerated property NFD_Quick_Check.
Returns i18n_unormalization_check_result_e values.I18N_UCHAR_NFKD_QUICK_CHECK Enumerated property NFKD_Quick_Check.
Returns i18n_unormalization_check_result_e values.I18N_UCHAR_NFC_QUICK_CHECK Enumerated property NFC_Quick_Check.
Returns i18n_unormalization_check_result_e values.I18N_UCHAR_NFKC_QUICK_CHECK Enumerated property NFKC_Quick_Check.
Returns i18n_unormalization_check_result_e values.I18N_UCHAR_LEAD_CANONICAL_COMBINING_CLASS Enumerated property Lead_Canonical_Combining_Class.
Returns 8-bit numeric values.I18N_UCHAR_TRAIL_CANONICAL_COMBINING_CLASS Enumerated property Trail_Canonical_Combining_Class.
Returns 8-bit numeric values.I18N_UCHAR_GRAPHEME_CLUSTER_BREAK Enumerated property Grapheme_Cluster_Break (new in Unicode 4.1).
Returns i18n_uchar_u_grapheme_cluster_break_e values.I18N_UCHAR_SENTENCE_BREAK Enumerated property Sentence_Break (new in Unicode 4.1).
Returns i18n_uchar_u_sentence_break_e values.I18N_UCHAR_WORD_BREAK Enumerated property Word_Break (new in Unicode 4.1).
Returns i18n_uchar_u_word_break_values_e values.I18N_UCHAR_BIDI_PAIRED_BRACKET_TYPE Enumerated property Bidi_Paired_Bracket_Type.
Returns i18n_uchar_u_bidi_paired_bracket_type_e values .I18N_UCHAR_INT_LIMIT One more than the last constant for enumerated/integer Unicode properties.
I18N_UCHAR_GENERAL_CATEGORY_MASK Bitmask property General_Category_Mask.
Mask values should be cast to uint32_t.I18N_UCHAR_MASK_START First constant for bit-mask Unicode properties.
I18N_UCHAR_MASK_LIMIT One more than the last constant for bit-mask Unicode properties.
I18N_UCHAR_NUMERIC_VALUE Double property Numeric_Value.
I18N_UCHAR_DOUBLE_START First constant for double Unicode properties.
I18N_UCHAR_DOUBLE_LIMIT One more than the last constant for double Unicode properties.
I18N_UCHAR_AGE String property Age.
I18N_UCHAR_STRING_START First constant for string Unicode properties.
I18N_UCHAR_BIDI_MIRRORING_GLYPH String property Bidi_Mirroring_Glyph.
I18N_UCHAR_CASE_FOLDING String property Case_Folding.
I18N_UCHAR_LOWERCASE_MAPPING String property Lowercase_Mapping.
I18N_UCHAR_NAME String property Name.
I18N_UCHAR_SIMPLE_CASE_FOLDING String property Simple_Case_Folding.
I18N_UCHAR_SIMPLE_LOWERCASE_MAPPING String property Simple_Lowercase_Mapping.
I18N_UCHAR_SIMPLE_TITLECASE_MAPPING String property Simple_Titlecase_Mapping.
I18N_UCHAR_SIMPLE_UPPERCASE_MAPPING String property Simple_Uppercase_Mapping.
I18N_UCHAR_TITLECASE_MAPPING String property Titlecase_Mapping.
I18N_UCHAR_UPPERCASE_MAPPING String property Uppercase_Mapping.
I18N_UCHAR_BIDI_PAIRED_BRACKET String property Bidi_Paired_Bracket.
I18N_UCHAR_STRING_LIMIT One more than the last constant for string Unicode properties.
I18N_UCHAR_SCRIPT_EXTENSIONS Provisional property Script_Extensions (new in Unicode 6.0).
I18N_UCHAR_OTHER_PROPERTY_START First constant for Unicode properties with unusual value types.
I18N_UCHAR_OTHER_PROPERTY_LIMIT One more than the last constant for Unicode properties with unusual value types.
I18N_UCHAR_INVALID_CODE Represents a nonexistent or invalid property or property value.
enum i18n_uscript_code_e |
Constants for ISO 15924 script codes.
- Since :
- 2.4
- Enumerator:
Function Documentation
int i18n_uchar_get_int_property_value | ( | i18n_uchar32 | c, |
i18n_uchar_uproperty_e | which, | ||
int32_t * | property_val | ||
) |
Gets the property value for an enumerated property for a code point.
int property_value;
i18n_uchar_u_east_asian_width_e east_asian_width;
i18n_uchar_get_int_property_value (c, I18N_UCHAR_EAST_ASIAN_WIDTH, &property_value);
east_asian_width = (i18n_uchar_u_east_asian_width_e)property_value;
int property_value;
bool is_ideographic;
i18n_uchar_get_int_property_value(c, I18N_UCHAR_IDEOGRAPHIC, &property_value);
is_ideographic = (bool)property_value;
- Since :
- 2.3.1
- Parameters:
-
[in] c The code point to test. [in] which The i18n_uchar_uproperty_e selector constant, identifies which property to check
Must be I18N_UCHAR_BINARY_START<=which<I18N_UCHAR_BINARY_LIMIT or I18N_UCHAR_INT_START<=which<I18N_UCHAR_INT_LIMIT or I18N_UCHAR_MASK_START<=which<I18N_UCHAR_MASK_LIMIT.[out] property_val The numeric value that is directly the property value or, for enumerated properties, corresponds to the numeric value of the enumerated constant of the respective property value enumeration type (cast to enum type if necessary)
Returns0
or1
(for false/true) for binary Unicode properties
Returns a bit-mask for mask properties
Returns0
if 'which' is out of bounds or if the Unicode version does not have data for the property at all, or not for this code point.
- Return values:
-
I18N_ERROR_NONE Successful I18N_ERROR_INVALID_PARAMETER Invalid function parameter
int i18n_uchar_get_ublock_code | ( | i18n_uchar32 | c, |
i18n_uchar_ublock_code_e * | block_val | ||
) |
Gets the Unicode allocation block that contains the character.
- Since :
- 2.3.1
- Parameters:
-
[in] c The code point to test [out] block_val The block value for the code point
- Return values:
-
I18N_ERROR_NONE Successful I18N_ERROR_INVALID_PARAMETER Invalid function parameter