Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(60)

Side by Side Diff: source/common/unicode/uscript.h

Issue 845603002: Update ICU to 54.1 step 1 (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@master
Patch Set: remove unusued directories Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « source/common/unicode/ures.h ('k') | source/common/unicode/uset.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 ********************************************************************** 2 **********************************************************************
3 * Copyright (C) 1997-2013, International Business Machines 3 * Copyright (C) 1997-2014, International Business Machines
4 * Corporation and others. All Rights Reserved. 4 * Corporation and others. All Rights Reserved.
5 ********************************************************************** 5 **********************************************************************
6 * 6 *
7 * File USCRIPT.H 7 * File USCRIPT.H
8 * 8 *
9 * Modification History: 9 * Modification History:
10 * 10 *
11 * Date Name Description 11 * Date Name Description
12 * 07/06/2001 Ram Creation. 12 * 07/06/2001 Ram Creation.
13 ****************************************************************************** 13 ******************************************************************************
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 USCRIPT_KHAROSHTHI = 57, /* Khar */ 179 USCRIPT_KHAROSHTHI = 57, /* Khar */
180 /** @stable ICU 3.4 */ 180 /** @stable ICU 3.4 */
181 USCRIPT_SYLOTI_NAGRI = 58, /* Sylo */ 181 USCRIPT_SYLOTI_NAGRI = 58, /* Sylo */
182 /** @stable ICU 3.4 */ 182 /** @stable ICU 3.4 */
183 USCRIPT_NEW_TAI_LUE = 59, /* Talu */ 183 USCRIPT_NEW_TAI_LUE = 59, /* Talu */
184 /** @stable ICU 3.4 */ 184 /** @stable ICU 3.4 */
185 USCRIPT_TIFINAGH = 60, /* Tfng */ 185 USCRIPT_TIFINAGH = 60, /* Tfng */
186 /** @stable ICU 3.4 */ 186 /** @stable ICU 3.4 */
187 USCRIPT_OLD_PERSIAN = 61, /* Xpeo */ 187 USCRIPT_OLD_PERSIAN = 61, /* Xpeo */
188 188
189 /* New script codes from ISO 15924 */ 189 /* New script codes from Unicode and ISO 15924 */
190 /** @stable ICU 3.6 */ 190 /** @stable ICU 3.6 */
191 USCRIPT_BALINESE = 62, /* Bali */ 191 USCRIPT_BALINESE = 62, /* Bali */
192 /** @stable ICU 3.6 */ 192 /** @stable ICU 3.6 */
193 USCRIPT_BATAK = 63, /* Batk */ 193 USCRIPT_BATAK = 63, /* Batk */
194 /** @stable ICU 3.6 */ 194 /** @stable ICU 3.6 */
195 USCRIPT_BLISSYMBOLS = 64, /* Blis */ 195 USCRIPT_BLISSYMBOLS = 64, /* Blis */
196 /** @stable ICU 3.6 */ 196 /** @stable ICU 3.6 */
197 USCRIPT_BRAHMI = 65, /* Brah */ 197 USCRIPT_BRAHMI = 65, /* Brah */
198 /** @stable ICU 3.6 */ 198 /** @stable ICU 3.6 */
199 USCRIPT_CHAM = 66, /* Cham */ 199 USCRIPT_CHAM = 66, /* Cham */
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 USCRIPT_VAI = 99, /* Vaii */ 271 USCRIPT_VAI = 99, /* Vaii */
272 /** @stable ICU 3.6 */ 272 /** @stable ICU 3.6 */
273 USCRIPT_VISIBLE_SPEECH = 100,/* Visp */ 273 USCRIPT_VISIBLE_SPEECH = 100,/* Visp */
274 /** @stable ICU 3.6 */ 274 /** @stable ICU 3.6 */
275 USCRIPT_CUNEIFORM = 101,/* Xsux */ 275 USCRIPT_CUNEIFORM = 101,/* Xsux */
276 /** @stable ICU 3.6 */ 276 /** @stable ICU 3.6 */
277 USCRIPT_UNWRITTEN_LANGUAGES = 102,/* Zxxx */ 277 USCRIPT_UNWRITTEN_LANGUAGES = 102,/* Zxxx */
278 /** @stable ICU 3.6 */ 278 /** @stable ICU 3.6 */
279 USCRIPT_UNKNOWN = 103,/* Zzzz */ /* Unknown="Code fo r uncoded script", for unassigned code points */ 279 USCRIPT_UNKNOWN = 103,/* Zzzz */ /* Unknown="Code fo r uncoded script", for unassigned code points */
280 280
281 /* New script codes from ISO 15924 */
282 /** @stable ICU 3.8 */ 281 /** @stable ICU 3.8 */
283 USCRIPT_CARIAN = 104,/* Cari */ 282 USCRIPT_CARIAN = 104,/* Cari */
284 /** @stable ICU 3.8 */ 283 /** @stable ICU 3.8 */
285 USCRIPT_JAPANESE = 105,/* Jpan */ 284 USCRIPT_JAPANESE = 105,/* Jpan */
286 /** @stable ICU 3.8 */ 285 /** @stable ICU 3.8 */
287 USCRIPT_LANNA = 106,/* Lana */ 286 USCRIPT_LANNA = 106,/* Lana */
288 /** @stable ICU 3.8 */ 287 /** @stable ICU 3.8 */
289 USCRIPT_LYCIAN = 107,/* Lyci */ 288 USCRIPT_LYCIAN = 107,/* Lyci */
290 /** @stable ICU 3.8 */ 289 /** @stable ICU 3.8 */
291 USCRIPT_LYDIAN = 108,/* Lydi */ 290 USCRIPT_LYDIAN = 108,/* Lydi */
292 /** @stable ICU 3.8 */ 291 /** @stable ICU 3.8 */
293 USCRIPT_OL_CHIKI = 109,/* Olck */ 292 USCRIPT_OL_CHIKI = 109,/* Olck */
294 /** @stable ICU 3.8 */ 293 /** @stable ICU 3.8 */
295 USCRIPT_REJANG = 110,/* Rjng */ 294 USCRIPT_REJANG = 110,/* Rjng */
296 /** @stable ICU 3.8 */ 295 /** @stable ICU 3.8 */
297 USCRIPT_SAURASHTRA = 111,/* Saur */ 296 USCRIPT_SAURASHTRA = 111,/* Saur */
298 /** @stable ICU 3.8 */ 297 /** @stable ICU 3.8 */
299 USCRIPT_SIGN_WRITING = 112,/* Sgnw */ 298 USCRIPT_SIGN_WRITING = 112,/* Sgnw */
300 /** @stable ICU 3.8 */ 299 /** @stable ICU 3.8 */
301 USCRIPT_SUNDANESE = 113,/* Sund */ 300 USCRIPT_SUNDANESE = 113,/* Sund */
302 /** @stable ICU 3.8 */ 301 /** @stable ICU 3.8 */
303 USCRIPT_MOON = 114,/* Moon */ 302 USCRIPT_MOON = 114,/* Moon */
304 /** @stable ICU 3.8 */ 303 /** @stable ICU 3.8 */
305 USCRIPT_MEITEI_MAYEK = 115,/* Mtei */ 304 USCRIPT_MEITEI_MAYEK = 115,/* Mtei */
306 305
307 /* New script codes from ISO 15924 */
308 /** @stable ICU 4.0 */ 306 /** @stable ICU 4.0 */
309 USCRIPT_IMPERIAL_ARAMAIC = 116,/* Armi */ 307 USCRIPT_IMPERIAL_ARAMAIC = 116,/* Armi */
310 /** @stable ICU 4.0 */ 308 /** @stable ICU 4.0 */
311 USCRIPT_AVESTAN = 117,/* Avst */ 309 USCRIPT_AVESTAN = 117,/* Avst */
312 /** @stable ICU 4.0 */ 310 /** @stable ICU 4.0 */
313 USCRIPT_CHAKMA = 118,/* Cakm */ 311 USCRIPT_CHAKMA = 118,/* Cakm */
314 /** @stable ICU 4.0 */ 312 /** @stable ICU 4.0 */
315 USCRIPT_KOREAN = 119,/* Kore */ 313 USCRIPT_KOREAN = 119,/* Kore */
316 /** @stable ICU 4.0 */ 314 /** @stable ICU 4.0 */
317 USCRIPT_KAITHI = 120,/* Kthi */ 315 USCRIPT_KAITHI = 120,/* Kthi */
318 /** @stable ICU 4.0 */ 316 /** @stable ICU 4.0 */
319 USCRIPT_MANICHAEAN = 121,/* Mani */ 317 USCRIPT_MANICHAEAN = 121,/* Mani */
320 /** @stable ICU 4.0 */ 318 /** @stable ICU 4.0 */
321 USCRIPT_INSCRIPTIONAL_PAHLAVI = 122,/* Phli */ 319 USCRIPT_INSCRIPTIONAL_PAHLAVI = 122,/* Phli */
322 /** @stable ICU 4.0 */ 320 /** @stable ICU 4.0 */
323 USCRIPT_PSALTER_PAHLAVI = 123,/* Phlp */ 321 USCRIPT_PSALTER_PAHLAVI = 123,/* Phlp */
324 /** @stable ICU 4.0 */ 322 /** @stable ICU 4.0 */
325 USCRIPT_BOOK_PAHLAVI = 124,/* Phlv */ 323 USCRIPT_BOOK_PAHLAVI = 124,/* Phlv */
326 /** @stable ICU 4.0 */ 324 /** @stable ICU 4.0 */
327 USCRIPT_INSCRIPTIONAL_PARTHIAN = 125,/* Prti */ 325 USCRIPT_INSCRIPTIONAL_PARTHIAN = 125,/* Prti */
328 /** @stable ICU 4.0 */ 326 /** @stable ICU 4.0 */
329 USCRIPT_SAMARITAN = 126,/* Samr */ 327 USCRIPT_SAMARITAN = 126,/* Samr */
330 /** @stable ICU 4.0 */ 328 /** @stable ICU 4.0 */
331 USCRIPT_TAI_VIET = 127,/* Tavt */ 329 USCRIPT_TAI_VIET = 127,/* Tavt */
332 /** @stable ICU 4.0 */ 330 /** @stable ICU 4.0 */
333 USCRIPT_MATHEMATICAL_NOTATION = 128,/* Zmth */ 331 USCRIPT_MATHEMATICAL_NOTATION = 128,/* Zmth */
334 /** @stable ICU 4.0 */ 332 /** @stable ICU 4.0 */
335 USCRIPT_SYMBOLS = 129,/* Zsym */ 333 USCRIPT_SYMBOLS = 129,/* Zsym */
336 334
337 /* New script codes from ISO 15924 */
338 /** @stable ICU 4.4 */ 335 /** @stable ICU 4.4 */
339 USCRIPT_BAMUM = 130,/* Bamu */ 336 USCRIPT_BAMUM = 130,/* Bamu */
340 /** @stable ICU 4.4 */ 337 /** @stable ICU 4.4 */
341 USCRIPT_LISU = 131,/* Lisu */ 338 USCRIPT_LISU = 131,/* Lisu */
342 /** @stable ICU 4.4 */ 339 /** @stable ICU 4.4 */
343 USCRIPT_NAKHI_GEBA = 132,/* Nkgb */ 340 USCRIPT_NAKHI_GEBA = 132,/* Nkgb */
344 /** @stable ICU 4.4 */ 341 /** @stable ICU 4.4 */
345 USCRIPT_OLD_SOUTH_ARABIAN = 133,/* Sarb */ 342 USCRIPT_OLD_SOUTH_ARABIAN = 133,/* Sarb */
346 343
347 /* New script codes from ISO 15924 */
348 /** @stable ICU 4.6 */ 344 /** @stable ICU 4.6 */
349 USCRIPT_BASSA_VAH = 134,/* Bass */ 345 USCRIPT_BASSA_VAH = 134,/* Bass */
350 /** @stable ICU 4.6 */ 346 /** @stable ICU 54 */
351 USCRIPT_DUPLOYAN_SHORTAND = 135,/* Dupl */ 347 USCRIPT_DUPLOYAN = 135,/* Dupl */
348 #ifndef U_HIDE_DEPRECATED_API
349 /** @deprecated ICU 54 Typo, use USCRIPT_DUPLOYAN */
350 USCRIPT_DUPLOYAN_SHORTAND = USCRIPT_DUPLOYAN,
351 #endif /* U_HIDE_DEPRECATED_API */
352 /** @stable ICU 4.6 */ 352 /** @stable ICU 4.6 */
353 USCRIPT_ELBASAN = 136,/* Elba */ 353 USCRIPT_ELBASAN = 136,/* Elba */
354 /** @stable ICU 4.6 */ 354 /** @stable ICU 4.6 */
355 USCRIPT_GRANTHA = 137,/* Gran */ 355 USCRIPT_GRANTHA = 137,/* Gran */
356 /** @stable ICU 4.6 */ 356 /** @stable ICU 4.6 */
357 USCRIPT_KPELLE = 138,/* Kpel */ 357 USCRIPT_KPELLE = 138,/* Kpel */
358 /** @stable ICU 4.6 */ 358 /** @stable ICU 4.6 */
359 USCRIPT_LOMA = 139,/* Loma */ 359 USCRIPT_LOMA = 139,/* Loma */
360 /** @stable ICU 4.6 */ 360 /** Mende Kikakui @stable ICU 4.6 */
361 USCRIPT_MENDE = 140,/* Mend */ 361 USCRIPT_MENDE = 140,/* Mend */
362 /** @stable ICU 4.6 */ 362 /** @stable ICU 4.6 */
363 USCRIPT_MEROITIC_CURSIVE = 141,/* Merc */ 363 USCRIPT_MEROITIC_CURSIVE = 141,/* Merc */
364 /** @stable ICU 4.6 */ 364 /** @stable ICU 4.6 */
365 USCRIPT_OLD_NORTH_ARABIAN = 142,/* Narb */ 365 USCRIPT_OLD_NORTH_ARABIAN = 142,/* Narb */
366 /** @stable ICU 4.6 */ 366 /** @stable ICU 4.6 */
367 USCRIPT_NABATAEAN = 143,/* Nbat */ 367 USCRIPT_NABATAEAN = 143,/* Nbat */
368 /** @stable ICU 4.6 */ 368 /** @stable ICU 4.6 */
369 USCRIPT_PALMYRENE = 144,/* Palm */ 369 USCRIPT_PALMYRENE = 144,/* Palm */
370 /** @stable ICU 54 */
371 USCRIPT_KHUDAWADI = 145,/* Sind */
370 /** @stable ICU 4.6 */ 372 /** @stable ICU 4.6 */
371 USCRIPT_SINDHI = 145,/* Sind */ 373 USCRIPT_SINDHI = USCRIPT_KHUDAWADI,
372 /** @stable ICU 4.6 */ 374 /** @stable ICU 4.6 */
373 USCRIPT_WARANG_CITI = 146,/* Wara */ 375 USCRIPT_WARANG_CITI = 146,/* Wara */
374 376
375 /** @stable ICU 4.8 */ 377 /** @stable ICU 4.8 */
376 USCRIPT_AFAKA = 147,/* Afak */ 378 USCRIPT_AFAKA = 147,/* Afak */
377 /** @stable ICU 4.8 */ 379 /** @stable ICU 4.8 */
378 USCRIPT_JURCHEN = 148,/* Jurc */ 380 USCRIPT_JURCHEN = 148,/* Jurc */
379 /** @stable ICU 4.8 */ 381 /** @stable ICU 4.8 */
380 USCRIPT_MRO = 149,/* Mroo */ 382 USCRIPT_MRO = 149,/* Mroo */
381 /** @stable ICU 4.8 */ 383 /** @stable ICU 4.8 */
(...skipping 14 matching lines...) Expand all
396 /** @stable ICU 49 */ 398 /** @stable ICU 49 */
397 USCRIPT_KHOJKI = 157,/* Khoj */ 399 USCRIPT_KHOJKI = 157,/* Khoj */
398 /** @stable ICU 49 */ 400 /** @stable ICU 49 */
399 USCRIPT_TIRHUTA = 158,/* Tirh */ 401 USCRIPT_TIRHUTA = 158,/* Tirh */
400 402
401 /** @stable ICU 52 */ 403 /** @stable ICU 52 */
402 USCRIPT_CAUCASIAN_ALBANIAN = 159,/* Aghb */ 404 USCRIPT_CAUCASIAN_ALBANIAN = 159,/* Aghb */
403 /** @stable ICU 52 */ 405 /** @stable ICU 52 */
404 USCRIPT_MAHAJANI = 160,/* Mahj */ 406 USCRIPT_MAHAJANI = 160,/* Mahj */
405 407
408 /** @stable ICU 54 */
409 USCRIPT_AHOM = 161,/* Ahom */
410 /** @stable ICU 54 */
411 USCRIPT_HATRAN = 162,/* Hatr */
412 /** @stable ICU 54 */
413 USCRIPT_MODI = 163,/* Modi */
414 /** @stable ICU 54 */
415 USCRIPT_MULTANI = 164,/* Mult */
416 /** @stable ICU 54 */
417 USCRIPT_PAU_CIN_HAU = 165,/* Pauc */
418 /** @stable ICU 54 */
419 USCRIPT_SIDDHAM = 166,/* Sidd */
420
406 /* Private use codes from Qaaa - Qabx are not supported */ 421 /* Private use codes from Qaaa - Qabx are not supported */
407 422
408 /** @stable ICU 2.2 */ 423 /** @stable ICU 2.2 */
409 USCRIPT_CODE_LIMIT = 161 424 USCRIPT_CODE_LIMIT = 167
410 } UScriptCode; 425 } UScriptCode;
411 426
412 /** 427 /**
413 * Gets script codes associated with the given locale or ISO 15924 abbreviation or name. 428 * Gets the script codes associated with the given locale or ISO 15924 abbreviat ion or name.
414 * Fills in USCRIPT_MALAYALAM given "Malayam" OR "Mlym". 429 * Fills in USCRIPT_MALAYALAM given "Malayam" OR "Mlym".
415 * Fills in USCRIPT_LATIN given "en" OR "en_US" 430 * Fills in USCRIPT_LATIN given "en" OR "en_US"
416 * If required capacity is greater than capacity of the destination buffer then the error code 431 * If the required capacity is greater than the capacity of the destination buff er,
417 * is set to U_BUFFER_OVERFLOW_ERROR and the required capacity is returned 432 * then the error code is set to U_BUFFER_OVERFLOW_ERROR and the required capaci ty is returned.
418 * 433 *
419 * <p>Note: To search by short or long script alias only, use 434 * <p>Note: To search by short or long script alias only, use
420 * u_getPropertyValueEnum(UCHAR_SCRIPT, alias) instead. This does 435 * u_getPropertyValueEnum(UCHAR_SCRIPT, alias) instead. That does
421 * a fast lookup with no access of the locale data. 436 * a fast lookup with no access of the locale data.
437 *
422 * @param nameOrAbbrOrLocale name of the script, as given in 438 * @param nameOrAbbrOrLocale name of the script, as given in
423 * PropertyValueAliases.txt, or ISO 15924 code or locale 439 * PropertyValueAliases.txt, or ISO 15924 code or locale
424 * @param fillIn the UScriptCode buffer to fill in the script code 440 * @param fillIn the UScriptCode buffer to fill in the script code
425 * @param capacity the capacity (size) fo UScriptCode buffer passed in. 441 * @param capacity the capacity (size) fo UScriptCode buffer passed in.
426 * @param err the error status code. 442 * @param err the error status code.
427 * @return The number of script codes filled in the buffer passed in 443 * @return The number of script codes filled in the buffer passed in
428 * @stable ICU 2.4 444 * @stable ICU 2.4
429 */ 445 */
430 U_STABLE int32_t U_EXPORT2 446 U_STABLE int32_t U_EXPORT2
431 uscript_getCode(const char* nameOrAbbrOrLocale,UScriptCode* fillIn,int32_t capac ity,UErrorCode *err); 447 uscript_getCode(const char* nameOrAbbrOrLocale,UScriptCode* fillIn,int32_t capac ity,UErrorCode *err);
432 448
433 /** 449 /**
434 * Gets a script name associated with the given script code. 450 * Returns the long Unicode script name, if there is one.
435 * Returns "Malayam" given USCRIPT_MALAYALAM 451 * Otherwise returns the 4-letter ISO 15924 script code.
452 * Returns "Malayam" given USCRIPT_MALAYALAM.
453 *
436 * @param scriptCode UScriptCode enum 454 * @param scriptCode UScriptCode enum
437 * @return script long name as given in 455 * @return long script name as given in PropertyValueAliases.txt, or the 4-lette r code,
438 * PropertyValueAliases.txt, or NULL if scriptCode is invalid 456 * or NULL if scriptCode is invalid
439 * @stable ICU 2.4 457 * @stable ICU 2.4
440 */ 458 */
441 U_STABLE const char* U_EXPORT2 459 U_STABLE const char* U_EXPORT2
442 uscript_getName(UScriptCode scriptCode); 460 uscript_getName(UScriptCode scriptCode);
443 461
444 /** 462 /**
445 * Gets a script name associated with the given script code. 463 * Returns the 4-letter ISO 15924 script code,
446 * Returns "Mlym" given USCRIPT_MALAYALAM 464 * which is the same as the short Unicode script name if Unicode has names for t he script.
465 * Returns "Mlym" given USCRIPT_MALAYALAM.
466 *
447 * @param scriptCode UScriptCode enum 467 * @param scriptCode UScriptCode enum
448 * @return script abbreviated name as given in 468 * @return short script name (4-letter code), or NULL if scriptCode is invalid
449 * PropertyValueAliases.txt, or NULL if scriptCode is invalid
450 * @stable ICU 2.4 469 * @stable ICU 2.4
451 */ 470 */
452 U_STABLE const char* U_EXPORT2 471 U_STABLE const char* U_EXPORT2
453 uscript_getShortName(UScriptCode scriptCode); 472 uscript_getShortName(UScriptCode scriptCode);
454 473
455 /** 474 /**
456 * Gets the script code associated with the given codepoint. 475 * Gets the script code associated with the given codepoint.
457 * Returns USCRIPT_MALAYALAM given 0x0D02 476 * Returns USCRIPT_MALAYALAM given 0x0D02
458 * @param codepoint UChar32 codepoint 477 * @param codepoint UChar32 codepoint
459 * @param err the error status code. 478 * @param err the error status code.
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
510 * function chaining. (See User Guide for details.) 529 * function chaining. (See User Guide for details.)
511 * @return number of script codes in c's Script_Extensions, or 1 for the single Script value, 530 * @return number of script codes in c's Script_Extensions, or 1 for the single Script value,
512 * written to scripts unless U_BUFFER_OVERFLOW_ERROR indicates insuffici ent capacity 531 * written to scripts unless U_BUFFER_OVERFLOW_ERROR indicates insuffici ent capacity
513 * @stable ICU 49 532 * @stable ICU 49
514 */ 533 */
515 U_STABLE int32_t U_EXPORT2 534 U_STABLE int32_t U_EXPORT2
516 uscript_getScriptExtensions(UChar32 c, 535 uscript_getScriptExtensions(UChar32 c,
517 UScriptCode *scripts, int32_t capacity, 536 UScriptCode *scripts, int32_t capacity,
518 UErrorCode *errorCode); 537 UErrorCode *errorCode);
519 538
520 #ifndef U_HIDE_DRAFT_API
521
522 /** 539 /**
523 * Script usage constants. 540 * Script usage constants.
524 * See UAX #31 Unicode Identifier and Pattern Syntax. 541 * See UAX #31 Unicode Identifier and Pattern Syntax.
525 * http://www.unicode.org/reports/tr31/#Table_Candidate_Characters_for_Exclusion _from_Identifiers 542 * http://www.unicode.org/reports/tr31/#Table_Candidate_Characters_for_Exclusion _from_Identifiers
526 * 543 *
527 * @draft ICU 51 544 * @stable ICU 51
528 */ 545 */
529 typedef enum UScriptUsage { 546 typedef enum UScriptUsage {
530 /** Not encoded in Unicode. @draft ICU 51 */ 547 /** Not encoded in Unicode. @stable ICU 51 */
531 USCRIPT_USAGE_NOT_ENCODED, 548 USCRIPT_USAGE_NOT_ENCODED,
532 /** Unknown script usage. @draft ICU 51 */ 549 /** Unknown script usage. @stable ICU 51 */
533 USCRIPT_USAGE_UNKNOWN, 550 USCRIPT_USAGE_UNKNOWN,
534 /** Candidate for Exclusion from Identifiers. @draft ICU 51 */ 551 /** Candidate for Exclusion from Identifiers. @stable ICU 51 */
535 USCRIPT_USAGE_EXCLUDED, 552 USCRIPT_USAGE_EXCLUDED,
536 /** Limited Use script. @draft ICU 51 */ 553 /** Limited Use script. @stable ICU 51 */
537 USCRIPT_USAGE_LIMITED_USE, 554 USCRIPT_USAGE_LIMITED_USE,
538 /** Aspirational Use script. @draft ICU 51 */ 555 /** Aspirational Use script. @stable ICU 51 */
539 USCRIPT_USAGE_ASPIRATIONAL, 556 USCRIPT_USAGE_ASPIRATIONAL,
540 /** Recommended script. @draft ICU 51 */ 557 /** Recommended script. @stable ICU 51 */
541 USCRIPT_USAGE_RECOMMENDED 558 USCRIPT_USAGE_RECOMMENDED
542 } UScriptUsage; 559 } UScriptUsage;
543 560
544 /** 561 /**
545 * Writes the script sample character string. 562 * Writes the script sample character string.
546 * This string normally consists of one code point but might be longer. 563 * This string normally consists of one code point but might be longer.
547 * The string is empty if the script is not encoded. 564 * The string is empty if the script is not encoded.
548 * 565 *
549 * @param script script code 566 * @param script script code
550 * @param dest output string array 567 * @param dest output string array
551 * @param capacity number of UChars in the dest array 568 * @param capacity number of UChars in the dest array
552 * @param pErrorCode standard ICU in/out error code, must pass U_SUCCESS() on in put 569 * @param pErrorCode standard ICU in/out error code, must pass U_SUCCESS() on in put
553 * @return the string length, even if U_BUFFER_OVERFLOW_ERROR 570 * @return the string length, even if U_BUFFER_OVERFLOW_ERROR
554 * @draft ICU 51 571 * @stable ICU 51
555 */ 572 */
556 U_DRAFT int32_t U_EXPORT2 573 U_STABLE int32_t U_EXPORT2
557 uscript_getSampleString(UScriptCode script, UChar *dest, int32_t capacity, UErro rCode *pErrorCode); 574 uscript_getSampleString(UScriptCode script, UChar *dest, int32_t capacity, UErro rCode *pErrorCode);
558 575
559 #if U_SHOW_CPLUSPLUS_API 576 #if U_SHOW_CPLUSPLUS_API
560 577
561 U_NAMESPACE_BEGIN 578 U_NAMESPACE_BEGIN
562 class UnicodeString; 579 class UnicodeString;
563 U_NAMESPACE_END 580 U_NAMESPACE_END
564 581
565 /** 582 /**
566 * Returns the script sample character string. 583 * Returns the script sample character string.
567 * This string normally consists of one code point but might be longer. 584 * This string normally consists of one code point but might be longer.
568 * The string is empty if the script is not encoded. 585 * The string is empty if the script is not encoded.
569 * 586 *
570 * @param script script code 587 * @param script script code
571 * @return the sample character string 588 * @return the sample character string
572 * @draft ICU 51 589 * @stable ICU 51
573 */ 590 */
574 U_COMMON_API icu::UnicodeString U_EXPORT2 591 U_COMMON_API icu::UnicodeString U_EXPORT2
575 uscript_getSampleUnicodeString(UScriptCode script); 592 uscript_getSampleUnicodeString(UScriptCode script);
576 593
577 #endif 594 #endif
578 595
579 /** 596 /**
580 * Returns the script usage according to UAX #31 Unicode Identifier and Pattern Syntax. 597 * Returns the script usage according to UAX #31 Unicode Identifier and Pattern Syntax.
581 * Returns USCRIPT_USAGE_NOT_ENCODED if the script is not encoded in Unicode. 598 * Returns USCRIPT_USAGE_NOT_ENCODED if the script is not encoded in Unicode.
582 * 599 *
583 * @param script script code 600 * @param script script code
584 * @return script usage 601 * @return script usage
585 * @see UScriptUsage 602 * @see UScriptUsage
586 * @draft ICU 51 603 * @stable ICU 51
587 */ 604 */
588 U_DRAFT UScriptUsage U_EXPORT2 605 U_STABLE UScriptUsage U_EXPORT2
589 uscript_getUsage(UScriptCode script); 606 uscript_getUsage(UScriptCode script);
590 607
591 /** 608 /**
592 * Returns TRUE if the script is written right-to-left. 609 * Returns TRUE if the script is written right-to-left.
593 * For example, Arab and Hebr. 610 * For example, Arab and Hebr.
594 * 611 *
595 * @param script script code 612 * @param script script code
596 * @return TRUE if the script is right-to-left 613 * @return TRUE if the script is right-to-left
597 * @draft ICU 51 614 * @stable ICU 51
598 */ 615 */
599 U_DRAFT UBool U_EXPORT2 616 U_STABLE UBool U_EXPORT2
600 uscript_isRightToLeft(UScriptCode script); 617 uscript_isRightToLeft(UScriptCode script);
601 618
602 /** 619 /**
603 * Returns TRUE if the script allows line breaks between letters (excluding hyph enation). 620 * Returns TRUE if the script allows line breaks between letters (excluding hyph enation).
604 * Such a script typically requires dictionary-based line breaking. 621 * Such a script typically requires dictionary-based line breaking.
605 * For example, Hani and Thai. 622 * For example, Hani and Thai.
606 * 623 *
607 * @param script script code 624 * @param script script code
608 * @return TRUE if the script allows line breaks between letters 625 * @return TRUE if the script allows line breaks between letters
609 * @draft ICU 51 626 * @stable ICU 51
610 */ 627 */
611 U_DRAFT UBool U_EXPORT2 628 U_STABLE UBool U_EXPORT2
612 uscript_breaksBetweenLetters(UScriptCode script); 629 uscript_breaksBetweenLetters(UScriptCode script);
613 630
614 /** 631 /**
615 * Returns TRUE if in modern (or most recent) usage of the script case distincti ons are customary. 632 * Returns TRUE if in modern (or most recent) usage of the script case distincti ons are customary.
616 * For example, Latn and Cyrl. 633 * For example, Latn and Cyrl.
617 * 634 *
618 * @param script script code 635 * @param script script code
619 * @return TRUE if the script is cased 636 * @return TRUE if the script is cased
620 * @draft ICU 51 637 * @stable ICU 51
621 */ 638 */
622 U_DRAFT UBool U_EXPORT2 639 U_STABLE UBool U_EXPORT2
623 uscript_isCased(UScriptCode script); 640 uscript_isCased(UScriptCode script);
624 641
625 #endif /* U_HIDE_DRAFT_API */
626
627 #endif 642 #endif
OLDNEW
« no previous file with comments | « source/common/unicode/ures.h ('k') | source/common/unicode/uset.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698