pango 2.2.0-x86-mingw32 → 2.2.1-x86-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +21 -2
- data/lib/2.0/pango.so +0 -0
- data/vendor/local/bin/derb.exe +0 -0
- data/vendor/local/bin/genbrk.exe +0 -0
- data/vendor/local/bin/genccode.exe +0 -0
- data/vendor/local/bin/gencfu.exe +0 -0
- data/vendor/local/bin/gencmn.exe +0 -0
- data/vendor/local/bin/gencnval.exe +0 -0
- data/vendor/local/bin/gendict.exe +0 -0
- data/vendor/local/bin/gennorm2.exe +0 -0
- data/vendor/local/bin/genrb.exe +0 -0
- data/vendor/local/bin/gensprep.exe +0 -0
- data/vendor/local/bin/hb-ot-shape-closure.exe +0 -0
- data/vendor/local/bin/hb-shape.exe +0 -0
- data/vendor/local/bin/hb-view.exe +0 -0
- data/vendor/local/bin/icu-config +820 -0
- data/vendor/local/bin/icuinfo.exe +0 -0
- data/vendor/local/bin/icupkg.exe +0 -0
- data/vendor/local/bin/libharfbuzz-0.dll +0 -0
- data/vendor/local/bin/libpango-1.0-0.dll +0 -0
- data/vendor/local/bin/libpangocairo-1.0-0.dll +0 -0
- data/vendor/local/bin/libpangoft2-1.0-0.dll +0 -0
- data/vendor/local/bin/libpangowin32-1.0-0.dll +0 -0
- data/vendor/local/bin/libstdc++-6.dll +0 -0
- data/vendor/local/bin/makeconv.exe +0 -0
- data/vendor/local/bin/pango-querymodules.exe +0 -0
- data/vendor/local/bin/pango-view.exe +0 -0
- data/vendor/local/bin/pkgdata.exe +0 -0
- data/vendor/local/bin/uconv.exe +0 -0
- data/vendor/local/etc/pango/pango.modules +3 -3
- data/vendor/local/include/harfbuzz/hb-blob.h +3 -4
- data/vendor/local/include/harfbuzz/hb-buffer.h +22 -1
- data/vendor/local/include/harfbuzz/hb-common.h +23 -18
- data/vendor/local/include/harfbuzz/hb-icu.h +52 -0
- data/vendor/local/include/harfbuzz/hb-ot-font.h +41 -0
- data/vendor/local/include/harfbuzz/hb-ot-layout.h +11 -3
- data/vendor/local/include/harfbuzz/hb-ot-shape.h +10 -11
- data/vendor/local/include/harfbuzz/hb-ot.h +1 -0
- data/vendor/local/include/harfbuzz/hb-version.h +7 -7
- data/vendor/local/include/layout/LEFontInstance.h +550 -0
- data/vendor/local/include/layout/LEGlyphFilter.h +45 -0
- data/vendor/local/include/layout/LEGlyphStorage.h +546 -0
- data/vendor/local/include/layout/LEInsertionList.h +177 -0
- data/vendor/local/include/layout/LELanguages.h +112 -0
- data/vendor/local/include/layout/LEScripts.h +263 -0
- data/vendor/local/include/layout/LESwaps.h +100 -0
- data/vendor/local/include/layout/LETableReference.h +418 -0
- data/vendor/local/include/layout/LETypes.h +728 -0
- data/vendor/local/include/layout/LayoutEngine.h +518 -0
- data/vendor/local/include/layout/ParagraphLayout.h +747 -0
- data/vendor/local/include/layout/RunArrays.h +676 -0
- data/vendor/local/include/layout/loengine.h +225 -0
- data/vendor/local/include/layout/playout.h +466 -0
- data/vendor/local/include/layout/plruns.h +441 -0
- data/vendor/local/include/pango-1.0/pango/pango-features.h +2 -2
- data/vendor/local/include/pango-1.0/pango/pango-font.h +3 -1
- data/vendor/local/include/pango-1.0/pango/pango-item.h +11 -2
- data/vendor/local/include/unicode/alphaindex.h +752 -0
- data/vendor/local/include/unicode/appendable.h +232 -0
- data/vendor/local/include/unicode/basictz.h +214 -0
- data/vendor/local/include/unicode/brkiter.h +655 -0
- data/vendor/local/include/unicode/bytestream.h +257 -0
- data/vendor/local/include/unicode/bytestrie.h +519 -0
- data/vendor/local/include/unicode/bytestriebuilder.h +181 -0
- data/vendor/local/include/unicode/calendar.h +2519 -0
- data/vendor/local/include/unicode/caniter.h +208 -0
- data/vendor/local/include/unicode/chariter.h +722 -0
- data/vendor/local/include/unicode/choicfmt.h +594 -0
- data/vendor/local/include/unicode/coleitr.h +404 -0
- data/vendor/local/include/unicode/coll.h +1267 -0
- data/vendor/local/include/unicode/compactdecimalformat.h +330 -0
- data/vendor/local/include/unicode/curramt.h +130 -0
- data/vendor/local/include/unicode/currpinf.h +258 -0
- data/vendor/local/include/unicode/currunit.h +110 -0
- data/vendor/local/include/unicode/datefmt.h +883 -0
- data/vendor/local/include/unicode/dbbi.h +40 -0
- data/vendor/local/include/unicode/dcfmtsym.h +482 -0
- data/vendor/local/include/unicode/decimfmt.h +2479 -0
- data/vendor/local/include/unicode/docmain.h +215 -0
- data/vendor/local/include/unicode/dtfmtsym.h +912 -0
- data/vendor/local/include/unicode/dtintrv.h +158 -0
- data/vendor/local/include/unicode/dtitvfmt.h +985 -0
- data/vendor/local/include/unicode/dtitvinf.h +514 -0
- data/vendor/local/include/unicode/dtptngen.h +498 -0
- data/vendor/local/include/unicode/dtrule.h +250 -0
- data/vendor/local/include/unicode/enumset.h +64 -0
- data/vendor/local/include/unicode/errorcode.h +137 -0
- data/vendor/local/include/unicode/fieldpos.h +291 -0
- data/vendor/local/include/unicode/filteredbrk.h +131 -0
- data/vendor/local/include/unicode/fmtable.h +760 -0
- data/vendor/local/include/unicode/format.h +305 -0
- data/vendor/local/include/unicode/fpositer.h +117 -0
- data/vendor/local/include/unicode/gender.h +111 -0
- data/vendor/local/include/unicode/gregocal.h +777 -0
- data/vendor/local/include/unicode/icudataver.h +41 -0
- data/vendor/local/include/unicode/icuplug.h +371 -0
- data/vendor/local/include/unicode/idna.h +323 -0
- data/vendor/local/include/unicode/listformatter.h +167 -0
- data/vendor/local/include/unicode/localpointer.h +304 -0
- data/vendor/local/include/unicode/locdspnm.h +204 -0
- data/vendor/local/include/unicode/locid.h +815 -0
- data/vendor/local/include/unicode/measfmt.h +389 -0
- data/vendor/local/include/unicode/measunit.h +1443 -0
- data/vendor/local/include/unicode/measure.h +159 -0
- data/vendor/local/include/unicode/messagepattern.h +943 -0
- data/vendor/local/include/unicode/msgfmt.h +1093 -0
- data/vendor/local/include/unicode/normalizer2.h +658 -0
- data/vendor/local/include/unicode/normlzr.h +797 -0
- data/vendor/local/include/unicode/numfmt.h +1187 -0
- data/vendor/local/include/unicode/numsys.h +208 -0
- data/vendor/local/include/unicode/parseerr.h +92 -0
- data/vendor/local/include/unicode/parsepos.h +230 -0
- data/vendor/local/include/unicode/platform.h +751 -0
- data/vendor/local/include/unicode/plurfmt.h +615 -0
- data/vendor/local/include/unicode/plurrule.h +501 -0
- data/vendor/local/include/unicode/ptypes.h +126 -0
- data/vendor/local/include/unicode/putil.h +181 -0
- data/vendor/local/include/unicode/rbbi.h +782 -0
- data/vendor/local/include/unicode/rbnf.h +1032 -0
- data/vendor/local/include/unicode/rbtz.h +362 -0
- data/vendor/local/include/unicode/regex.h +1857 -0
- data/vendor/local/include/unicode/region.h +228 -0
- data/vendor/local/include/unicode/reldatefmt.h +498 -0
- data/vendor/local/include/unicode/rep.h +261 -0
- data/vendor/local/include/unicode/resbund.h +490 -0
- data/vendor/local/include/unicode/schriter.h +187 -0
- data/vendor/local/include/unicode/scientificformathelper.h +139 -0
- data/vendor/local/include/unicode/search.h +575 -0
- data/vendor/local/include/unicode/selfmt.h +367 -0
- data/vendor/local/include/unicode/simpletz.h +928 -0
- data/vendor/local/include/unicode/smpdtfmt.h +1592 -0
- data/vendor/local/include/unicode/sortkey.h +338 -0
- data/vendor/local/include/unicode/std_string.h +37 -0
- data/vendor/local/include/unicode/strenum.h +276 -0
- data/vendor/local/include/unicode/stringpiece.h +224 -0
- data/vendor/local/include/unicode/stringtriebuilder.h +402 -0
- data/vendor/local/include/unicode/stsearch.h +504 -0
- data/vendor/local/include/unicode/symtable.h +112 -0
- data/vendor/local/include/unicode/tblcoll.h +873 -0
- data/vendor/local/include/unicode/timezone.h +948 -0
- data/vendor/local/include/unicode/tmunit.h +129 -0
- data/vendor/local/include/unicode/tmutamt.h +168 -0
- data/vendor/local/include/unicode/tmutfmt.h +243 -0
- data/vendor/local/include/unicode/translit.h +1342 -0
- data/vendor/local/include/unicode/tzfmt.h +1098 -0
- data/vendor/local/include/unicode/tznames.h +404 -0
- data/vendor/local/include/unicode/tzrule.h +828 -0
- data/vendor/local/include/unicode/tztrans.h +195 -0
- data/vendor/local/include/unicode/ubidi.h +2186 -0
- data/vendor/local/include/unicode/ubrk.h +540 -0
- data/vendor/local/include/unicode/ucal.h +1560 -0
- data/vendor/local/include/unicode/ucasemap.h +423 -0
- data/vendor/local/include/unicode/ucat.h +158 -0
- data/vendor/local/include/unicode/uchar.h +3426 -0
- data/vendor/local/include/unicode/ucharstrie.h +576 -0
- data/vendor/local/include/unicode/ucharstriebuilder.h +185 -0
- data/vendor/local/include/unicode/uchriter.h +381 -0
- data/vendor/local/include/unicode/uclean.h +258 -0
- data/vendor/local/include/unicode/ucnv.h +2036 -0
- data/vendor/local/include/unicode/ucnv_cb.h +162 -0
- data/vendor/local/include/unicode/ucnv_err.h +463 -0
- data/vendor/local/include/unicode/ucnvsel.h +187 -0
- data/vendor/local/include/unicode/ucol.h +1474 -0
- data/vendor/local/include/unicode/ucoleitr.h +266 -0
- data/vendor/local/include/unicode/uconfig.h +430 -0
- data/vendor/local/include/unicode/ucsdet.h +413 -0
- data/vendor/local/include/unicode/ucurr.h +424 -0
- data/vendor/local/include/unicode/udat.h +1536 -0
- data/vendor/local/include/unicode/udata.h +430 -0
- data/vendor/local/include/unicode/udateintervalformat.h +181 -0
- data/vendor/local/include/unicode/udatpg.h +588 -0
- data/vendor/local/include/unicode/udisplaycontext.h +150 -0
- data/vendor/local/include/unicode/uenum.h +206 -0
- data/vendor/local/include/unicode/uformattable.h +280 -0
- data/vendor/local/include/unicode/ugender.h +82 -0
- data/vendor/local/include/unicode/uidna.h +762 -0
- data/vendor/local/include/unicode/uiter.h +707 -0
- data/vendor/local/include/unicode/uldnames.h +302 -0
- data/vendor/local/include/unicode/uloc.h +1256 -0
- data/vendor/local/include/unicode/ulocdata.h +277 -0
- data/vendor/local/include/unicode/umachine.h +356 -0
- data/vendor/local/include/unicode/umisc.h +60 -0
- data/vendor/local/include/unicode/umsg.h +623 -0
- data/vendor/local/include/unicode/unifilt.h +120 -0
- data/vendor/local/include/unicode/unifunct.h +125 -0
- data/vendor/local/include/unicode/unimatch.h +163 -0
- data/vendor/local/include/unicode/unirepl.h +97 -0
- data/vendor/local/include/unicode/uniset.h +1691 -0
- data/vendor/local/include/unicode/unistr.h +4470 -0
- data/vendor/local/include/unicode/unorm.h +561 -0
- data/vendor/local/include/unicode/unorm2.h +528 -0
- data/vendor/local/include/unicode/unum.h +1328 -0
- data/vendor/local/include/unicode/unumsys.h +170 -0
- data/vendor/local/include/unicode/uobject.h +320 -0
- data/vendor/local/include/unicode/upluralrules.h +145 -0
- data/vendor/local/include/unicode/uregex.h +1591 -0
- data/vendor/local/include/unicode/uregion.h +248 -0
- data/vendor/local/include/unicode/urename.h +1784 -0
- data/vendor/local/include/unicode/urep.h +155 -0
- data/vendor/local/include/unicode/ures.h +887 -0
- data/vendor/local/include/unicode/uscript.h +642 -0
- data/vendor/local/include/unicode/usearch.h +885 -0
- data/vendor/local/include/unicode/uset.h +1126 -0
- data/vendor/local/include/unicode/usetiter.h +318 -0
- data/vendor/local/include/unicode/ushape.h +474 -0
- data/vendor/local/include/unicode/uspoof.h +1064 -0
- data/vendor/local/include/unicode/usprep.h +269 -0
- data/vendor/local/include/unicode/ustdio.h +1018 -0
- data/vendor/local/include/unicode/ustream.h +68 -0
- data/vendor/local/include/unicode/ustring.h +1700 -0
- data/vendor/local/include/unicode/ustringtrie.h +95 -0
- data/vendor/local/include/unicode/utext.h +1600 -0
- data/vendor/local/include/unicode/utf.h +223 -0
- data/vendor/local/include/unicode/utf16.h +623 -0
- data/vendor/local/include/unicode/utf32.h +23 -0
- data/vendor/local/include/unicode/utf8.h +824 -0
- data/vendor/local/include/unicode/utf_old.h +1169 -0
- data/vendor/local/include/unicode/utmscale.h +481 -0
- data/vendor/local/include/unicode/utrace.h +359 -0
- data/vendor/local/include/unicode/utrans.h +658 -0
- data/vendor/local/include/unicode/utypes.h +723 -0
- data/vendor/local/include/unicode/uvernum.h +170 -0
- data/vendor/local/include/unicode/uversion.h +193 -0
- data/vendor/local/include/unicode/vtzone.h +455 -0
- data/vendor/local/lib/girepository-1.0/Pango-1.0.typelib +0 -0
- data/vendor/local/lib/girepository-1.0/PangoCairo-1.0.typelib +0 -0
- data/vendor/local/lib/girepository-1.0/PangoFT2-1.0.typelib +0 -0
- data/vendor/local/lib/icu/54.1/Makefile.inc +293 -0
- data/vendor/local/lib/icu/54.1/pkgdata.inc +17 -0
- data/vendor/local/lib/icu/Makefile.inc +293 -0
- data/vendor/local/lib/icu/pkgdata.inc +17 -0
- data/vendor/local/lib/icudt.dll +0 -0
- data/vendor/local/lib/icudt54.dll +0 -0
- data/vendor/local/lib/icuin.dll +0 -0
- data/vendor/local/lib/icuin54.dll +0 -0
- data/vendor/local/lib/icuio.dll +0 -0
- data/vendor/local/lib/icuio54.dll +0 -0
- data/vendor/local/lib/icule.dll +0 -0
- data/vendor/local/lib/icule54.dll +0 -0
- data/vendor/local/lib/iculx.dll +0 -0
- data/vendor/local/lib/iculx54.dll +0 -0
- data/vendor/local/lib/icutest.dll +0 -0
- data/vendor/local/lib/icutest54.dll +0 -0
- data/vendor/local/lib/icutu.dll +0 -0
- data/vendor/local/lib/icutu54.dll +0 -0
- data/vendor/local/lib/icuuc.dll +0 -0
- data/vendor/local/lib/icuuc54.dll +0 -0
- data/vendor/local/lib/libharfbuzz-icu.a +0 -0
- data/vendor/local/lib/libharfbuzz-icu.la +41 -0
- data/vendor/local/lib/libharfbuzz.dll.a +0 -0
- data/vendor/local/lib/libharfbuzz.la +3 -3
- data/vendor/local/lib/libicudt.dll.a +0 -0
- data/vendor/local/lib/libicuin.dll.a +0 -0
- data/vendor/local/lib/libicuio.dll.a +0 -0
- data/vendor/local/lib/libicule.dll.a +0 -0
- data/vendor/local/lib/libiculx.dll.a +0 -0
- data/vendor/local/lib/libicutest.dll.a +0 -0
- data/vendor/local/lib/libicutu.dll.a +0 -0
- data/vendor/local/lib/libicuuc.dll.a +0 -0
- data/vendor/local/lib/libpango-1.0.dll.a +0 -0
- data/vendor/local/lib/libpango-1.0.la +2 -2
- data/vendor/local/lib/libpangocairo-1.0.dll.a +0 -0
- data/vendor/local/lib/libpangocairo-1.0.la +2 -2
- data/vendor/local/lib/libpangoft2-1.0.dll.a +0 -0
- data/vendor/local/lib/libpangoft2-1.0.la +2 -2
- data/vendor/local/lib/libpangowin32-1.0.dll.a +0 -0
- data/vendor/local/lib/libpangowin32-1.0.la +2 -2
- data/vendor/local/lib/pango/1.8.0/modules/pango-arabic-lang.dll +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-arabic-lang.dll.a +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-arabic-lang.la +1 -1
- data/vendor/local/lib/pango/1.8.0/modules/pango-basic-fc.dll +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-basic-fc.dll.a +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-basic-fc.la +1 -1
- data/vendor/local/lib/pango/1.8.0/modules/pango-basic-win32.dll +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-basic-win32.dll.a +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-basic-win32.la +1 -1
- data/vendor/local/lib/pango/1.8.0/modules/pango-indic-lang.dll +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-indic-lang.dll.a +0 -0
- data/vendor/local/lib/pango/1.8.0/modules/pango-indic-lang.la +1 -1
- data/vendor/local/lib/pkgconfig/harfbuzz-icu.pc +13 -0
- data/vendor/local/lib/pkgconfig/harfbuzz.pc +1 -1
- data/vendor/local/lib/pkgconfig/icu-i18n.pc +38 -0
- data/vendor/local/lib/pkgconfig/icu-io.pc +38 -0
- data/vendor/local/lib/pkgconfig/icu-le.pc +38 -0
- data/vendor/local/lib/pkgconfig/icu-lx.pc +38 -0
- data/vendor/local/lib/pkgconfig/icu-uc.pc +38 -0
- data/vendor/local/lib/pkgconfig/pango.pc +1 -1
- data/vendor/local/lib/pkgconfig/pangocairo.pc +1 -1
- data/vendor/local/lib/pkgconfig/pangoft2.pc +1 -1
- data/vendor/local/lib/pkgconfig/pangowin32.pc +1 -1
- data/vendor/local/share/gir-1.0/Pango-1.0.gir +3009 -462
- data/vendor/local/share/gir-1.0/PangoCairo-1.0.gir +64 -22
- data/vendor/local/share/gir-1.0/PangoFT2-1.0.gir +4 -2
- data/vendor/local/share/gtk-doc/html/harfbuzz/annotation-glossary.html +30 -26
- data/vendor/local/share/gtk-doc/html/harfbuzz/api-index-full.html +343 -313
- data/vendor/local/share/gtk-doc/html/harfbuzz/ch01.html +5 -5
- data/vendor/local/share/gtk-doc/html/harfbuzz/deprecated-api-index.html +6 -8
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-blob.html +442 -247
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-buffer.html +1389 -654
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-common.html +954 -698
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-coretext.html +95 -18
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-deprecated.html +36 -27
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-face.html +477 -191
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-font.html +1951 -1039
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-ft.html +123 -65
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-glib.html +66 -21
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-gobject.html +11 -13
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-graphite2.html +67 -23
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-icu.html +66 -21
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-ot-layout.html +574 -347
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-ot-tag.html +104 -37
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-ot.html +10 -27
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-set.html +744 -318
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-shape-plan.html +294 -153
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-shape.html +196 -104
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-unicode.html +1100 -757
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-uniscribe.html +51 -18
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb-version.html +110 -84
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz-hb.html +11 -13
- data/vendor/local/share/gtk-doc/html/harfbuzz/harfbuzz.devhelp2 +289 -503
- data/vendor/local/share/gtk-doc/html/harfbuzz/index.html +3 -3
- data/vendor/local/share/gtk-doc/html/harfbuzz/index.sgml +161 -316
- data/vendor/local/share/gtk-doc/html/harfbuzz/object-tree.html +31 -4
- data/vendor/local/share/gtk-doc/html/harfbuzz/style.css +260 -105
- data/vendor/local/share/gtk-doc/html/pango/PangoEngineLang.html +143 -105
- data/vendor/local/share/gtk-doc/html/pango/PangoEngineShape.html +150 -108
- data/vendor/local/share/gtk-doc/html/pango/PangoFcDecoder.html +163 -112
- data/vendor/local/share/gtk-doc/html/pango/PangoFcFont.html +348 -229
- data/vendor/local/share/gtk-doc/html/pango/PangoFcFontMap.html +746 -514
- data/vendor/local/share/gtk-doc/html/pango/PangoMarkupFormat.html +9 -9
- data/vendor/local/share/gtk-doc/html/pango/PangoRenderer.html +853 -623
- data/vendor/local/share/gtk-doc/html/pango/annotation-glossary.html +29 -13
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-10.html +31 -33
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-12.html +10 -12
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-14.html +12 -14
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-16.html +53 -55
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-18.html +28 -30
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-2.html +29 -31
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-20.html +17 -19
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-22.html +28 -30
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-24.html +17 -19
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-26.html +9 -11
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-30.html +6 -6
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-31-0.html +6 -6
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-32-4.html +11 -13
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-32.html +7 -9
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-34.html +5 -5
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-4.html +49 -51
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-6.html +36 -38
- data/vendor/local/share/gtk-doc/html/pango/api-index-1-8.html +37 -39
- data/vendor/local/share/gtk-doc/html/pango/api-index-deprecated.html +68 -70
- data/vendor/local/share/gtk-doc/html/pango/api-index-full.html +568 -570
- data/vendor/local/share/gtk-doc/html/pango/index.html +3 -3
- data/vendor/local/share/gtk-doc/html/pango/index.sgml +229 -399
- data/vendor/local/share/gtk-doc/html/pango/lowlevel.html +4 -4
- data/vendor/local/share/gtk-doc/html/pango/pango-Bidirectional-Text.html +345 -259
- data/vendor/local/share/gtk-doc/html/pango/pango-Cairo-Rendering.html +979 -664
- data/vendor/local/share/gtk-doc/html/pango/pango-CoreText-Fonts.html +70 -43
- data/vendor/local/share/gtk-doc/html/pango/pango-Coverage-Maps.html +349 -229
- data/vendor/local/share/gtk-doc/html/pango/pango-Engines.html +236 -153
- data/vendor/local/share/gtk-doc/html/pango/pango-Fonts.html +3100 -2159
- data/vendor/local/share/gtk-doc/html/pango/pango-FreeType-Fonts-and-Rendering.html +659 -472
- data/vendor/local/share/gtk-doc/html/pango/pango-Glyph-Storage.html +1952 -1384
- data/vendor/local/share/gtk-doc/html/pango/pango-Layout-Objects.html +3050 -2135
- data/vendor/local/share/gtk-doc/html/pango/pango-Miscellaneous-Utilities.html +676 -463
- data/vendor/local/share/gtk-doc/html/pango/pango-Modules.html +223 -146
- data/vendor/local/share/gtk-doc/html/pango/pango-OpenType-Font-Handling.html +1589 -1199
- data/vendor/local/share/gtk-doc/html/pango/pango-Scripts-and-Languages.html +1072 -842
- data/vendor/local/share/gtk-doc/html/pango/pango-Tab-Stops.html +406 -276
- data/vendor/local/share/gtk-doc/html/pango/pango-Text-Attributes.html +2541 -1792
- data/vendor/local/share/gtk-doc/html/pango/pango-Text-Processing.html +1479 -1033
- data/vendor/local/share/gtk-doc/html/pango/pango-Version-Checking.html +214 -154
- data/vendor/local/share/gtk-doc/html/pango/pango-Vertical-Text.html +374 -291
- data/vendor/local/share/gtk-doc/html/pango/pango-Win32-Fonts-and-Rendering.html +733 -498
- data/vendor/local/share/gtk-doc/html/pango/pango-Xft-Fonts-and-Rendering.html +893 -617
- data/vendor/local/share/gtk-doc/html/pango/pango-hierarchy.html +59 -59
- data/vendor/local/share/gtk-doc/html/pango/pango-querymodules.html +5 -5
- data/vendor/local/share/gtk-doc/html/pango/pango.devhelp2 +578 -782
- data/vendor/local/share/gtk-doc/html/pango/pango.html +4 -4
- data/vendor/local/share/gtk-doc/html/pango/rendering.html +4 -4
- data/vendor/local/share/gtk-doc/html/pango/style.css +260 -105
- data/vendor/local/share/gtk-doc/html/pango/tools.html +4 -4
- data/vendor/local/share/icu/54.1/config/mh-mingw +158 -0
- data/vendor/local/share/icu/54.1/install-sh +251 -0
- data/vendor/local/share/icu/54.1/license.html +385 -0
- data/vendor/local/share/icu/54.1/mkinstalldirs +43 -0
- data/vendor/local/share/license/harfbuzz/AUTHORS +1 -0
- data/vendor/local/share/man/man1/derb.1 +196 -0
- data/vendor/local/share/man/man1/genbrk.1 +112 -0
- data/vendor/local/share/man/man1/gencfu.1 +91 -0
- data/vendor/local/share/man/man1/gencnval.1 +91 -0
- data/vendor/local/share/man/man1/gendict.1 +131 -0
- data/vendor/local/share/man/man1/genrb.1 +146 -0
- data/vendor/local/share/man/man1/icu-config.1 +288 -0
- data/vendor/local/share/man/man1/makeconv.1 +112 -0
- data/vendor/local/share/man/man1/pango-querymodules.1 +2 -2
- data/vendor/local/share/man/man1/pango-view.1 +1 -118
- data/vendor/local/share/man/man1/pkgdata.1 +258 -0
- data/vendor/local/share/man/man1/uconv.1 +443 -0
- data/vendor/local/share/man/man8/genccode.8 +106 -0
- data/vendor/local/share/man/man8/gencmn.8 +129 -0
- data/vendor/local/share/man/man8/gensprep.8 +102 -0
- data/vendor/local/share/man/man8/icupkg.8 +204 -0
- metadata +266 -14
- data/lib/1.9/pango.so +0 -0
- data/lib/2.1/pango.so +0 -0
@@ -0,0 +1,302 @@
|
|
1
|
+
/*
|
2
|
+
*******************************************************************************
|
3
|
+
* Copyright (C) 2010-2014, International Business Machines Corporation and *
|
4
|
+
* others. All Rights Reserved. *
|
5
|
+
*******************************************************************************
|
6
|
+
*/
|
7
|
+
|
8
|
+
#ifndef __ULDNAMES_H__
|
9
|
+
#define __ULDNAMES_H__
|
10
|
+
|
11
|
+
/**
|
12
|
+
* \file
|
13
|
+
* \brief C API: Provides display names of Locale ids and their components.
|
14
|
+
*/
|
15
|
+
|
16
|
+
#include "unicode/utypes.h"
|
17
|
+
#include "unicode/localpointer.h"
|
18
|
+
#include "unicode/uscript.h"
|
19
|
+
#include "unicode/udisplaycontext.h"
|
20
|
+
|
21
|
+
/**
|
22
|
+
* Enum used in LocaleDisplayNames::createInstance.
|
23
|
+
* @stable ICU 4.4
|
24
|
+
*/
|
25
|
+
typedef enum {
|
26
|
+
/**
|
27
|
+
* Use standard names when generating a locale name,
|
28
|
+
* e.g. en_GB displays as 'English (United Kingdom)'.
|
29
|
+
* @stable ICU 4.4
|
30
|
+
*/
|
31
|
+
ULDN_STANDARD_NAMES = 0,
|
32
|
+
/**
|
33
|
+
* Use dialect names, when generating a locale name,
|
34
|
+
* e.g. en_GB displays as 'British English'.
|
35
|
+
* @stable ICU 4.4
|
36
|
+
*/
|
37
|
+
ULDN_DIALECT_NAMES
|
38
|
+
} UDialectHandling;
|
39
|
+
|
40
|
+
/**
|
41
|
+
* Opaque C service object type for the locale display names API
|
42
|
+
* @stable ICU 4.4
|
43
|
+
*/
|
44
|
+
struct ULocaleDisplayNames;
|
45
|
+
|
46
|
+
/**
|
47
|
+
* C typedef for struct ULocaleDisplayNames.
|
48
|
+
* @stable ICU 4.4
|
49
|
+
*/
|
50
|
+
typedef struct ULocaleDisplayNames ULocaleDisplayNames;
|
51
|
+
|
52
|
+
#if !UCONFIG_NO_FORMATTING
|
53
|
+
|
54
|
+
/**
|
55
|
+
* Returns an instance of LocaleDisplayNames that returns names
|
56
|
+
* formatted for the provided locale, using the provided
|
57
|
+
* dialectHandling. The usual value for dialectHandling is
|
58
|
+
* ULOC_STANDARD_NAMES.
|
59
|
+
*
|
60
|
+
* @param locale the display locale
|
61
|
+
* @param dialectHandling how to select names for locales
|
62
|
+
* @return a ULocaleDisplayNames instance
|
63
|
+
* @param pErrorCode the status code
|
64
|
+
* @stable ICU 4.4
|
65
|
+
*/
|
66
|
+
U_STABLE ULocaleDisplayNames * U_EXPORT2
|
67
|
+
uldn_open(const char * locale,
|
68
|
+
UDialectHandling dialectHandling,
|
69
|
+
UErrorCode *pErrorCode);
|
70
|
+
|
71
|
+
/**
|
72
|
+
* Closes a ULocaleDisplayNames instance obtained from uldn_open().
|
73
|
+
* @param ldn the ULocaleDisplayNames instance to be closed
|
74
|
+
* @stable ICU 4.4
|
75
|
+
*/
|
76
|
+
U_STABLE void U_EXPORT2
|
77
|
+
uldn_close(ULocaleDisplayNames *ldn);
|
78
|
+
|
79
|
+
#if U_SHOW_CPLUSPLUS_API
|
80
|
+
|
81
|
+
U_NAMESPACE_BEGIN
|
82
|
+
|
83
|
+
/**
|
84
|
+
* \class LocalULocaleDisplayNamesPointer
|
85
|
+
* "Smart pointer" class, closes a ULocaleDisplayNames via uldn_close().
|
86
|
+
* For most methods see the LocalPointerBase base class.
|
87
|
+
*
|
88
|
+
* @see LocalPointerBase
|
89
|
+
* @see LocalPointer
|
90
|
+
* @stable ICU 4.4
|
91
|
+
*/
|
92
|
+
U_DEFINE_LOCAL_OPEN_POINTER(LocalULocaleDisplayNamesPointer, ULocaleDisplayNames, uldn_close);
|
93
|
+
|
94
|
+
U_NAMESPACE_END
|
95
|
+
|
96
|
+
#endif
|
97
|
+
|
98
|
+
/* getters for state */
|
99
|
+
|
100
|
+
/**
|
101
|
+
* Returns the locale used to determine the display names. This is
|
102
|
+
* not necessarily the same locale passed to {@link #uldn_open}.
|
103
|
+
* @param ldn the LocaleDisplayNames instance
|
104
|
+
* @return the display locale
|
105
|
+
* @stable ICU 4.4
|
106
|
+
*/
|
107
|
+
U_STABLE const char * U_EXPORT2
|
108
|
+
uldn_getLocale(const ULocaleDisplayNames *ldn);
|
109
|
+
|
110
|
+
/**
|
111
|
+
* Returns the dialect handling used in the display names.
|
112
|
+
* @param ldn the LocaleDisplayNames instance
|
113
|
+
* @return the dialect handling enum
|
114
|
+
* @stable ICU 4.4
|
115
|
+
*/
|
116
|
+
U_STABLE UDialectHandling U_EXPORT2
|
117
|
+
uldn_getDialectHandling(const ULocaleDisplayNames *ldn);
|
118
|
+
|
119
|
+
/* names for entire locales */
|
120
|
+
|
121
|
+
/**
|
122
|
+
* Returns the display name of the provided locale.
|
123
|
+
* @param ldn the LocaleDisplayNames instance
|
124
|
+
* @param locale the locale whose display name to return
|
125
|
+
* @param result receives the display name
|
126
|
+
* @param maxResultSize the size of the result buffer
|
127
|
+
* @param pErrorCode the status code
|
128
|
+
* @return the actual buffer size needed for the display name. If it's
|
129
|
+
* greater than maxResultSize, the returned name will be truncated.
|
130
|
+
* @stable ICU 4.4
|
131
|
+
*/
|
132
|
+
U_STABLE int32_t U_EXPORT2
|
133
|
+
uldn_localeDisplayName(const ULocaleDisplayNames *ldn,
|
134
|
+
const char *locale,
|
135
|
+
UChar *result,
|
136
|
+
int32_t maxResultSize,
|
137
|
+
UErrorCode *pErrorCode);
|
138
|
+
|
139
|
+
/* names for components of a locale */
|
140
|
+
|
141
|
+
/**
|
142
|
+
* Returns the display name of the provided language code.
|
143
|
+
* @param ldn the LocaleDisplayNames instance
|
144
|
+
* @param lang the language code whose display name to return
|
145
|
+
* @param result receives the display name
|
146
|
+
* @param maxResultSize the size of the result buffer
|
147
|
+
* @param pErrorCode the status code
|
148
|
+
* @return the actual buffer size needed for the display name. If it's
|
149
|
+
* greater than maxResultSize, the returned name will be truncated.
|
150
|
+
* @stable ICU 4.4
|
151
|
+
*/
|
152
|
+
U_STABLE int32_t U_EXPORT2
|
153
|
+
uldn_languageDisplayName(const ULocaleDisplayNames *ldn,
|
154
|
+
const char *lang,
|
155
|
+
UChar *result,
|
156
|
+
int32_t maxResultSize,
|
157
|
+
UErrorCode *pErrorCode);
|
158
|
+
|
159
|
+
/**
|
160
|
+
* Returns the display name of the provided script.
|
161
|
+
* @param ldn the LocaleDisplayNames instance
|
162
|
+
* @param script the script whose display name to return
|
163
|
+
* @param result receives the display name
|
164
|
+
* @param maxResultSize the size of the result buffer
|
165
|
+
* @param pErrorCode the status code
|
166
|
+
* @return the actual buffer size needed for the display name. If it's
|
167
|
+
* greater than maxResultSize, the returned name will be truncated.
|
168
|
+
* @stable ICU 4.4
|
169
|
+
*/
|
170
|
+
U_STABLE int32_t U_EXPORT2
|
171
|
+
uldn_scriptDisplayName(const ULocaleDisplayNames *ldn,
|
172
|
+
const char *script,
|
173
|
+
UChar *result,
|
174
|
+
int32_t maxResultSize,
|
175
|
+
UErrorCode *pErrorCode);
|
176
|
+
|
177
|
+
/**
|
178
|
+
* Returns the display name of the provided script code.
|
179
|
+
* @param ldn the LocaleDisplayNames instance
|
180
|
+
* @param scriptCode the script code whose display name to return
|
181
|
+
* @param result receives the display name
|
182
|
+
* @param maxResultSize the size of the result buffer
|
183
|
+
* @param pErrorCode the status code
|
184
|
+
* @return the actual buffer size needed for the display name. If it's
|
185
|
+
* greater than maxResultSize, the returned name will be truncated.
|
186
|
+
* @stable ICU 4.4
|
187
|
+
*/
|
188
|
+
U_STABLE int32_t U_EXPORT2
|
189
|
+
uldn_scriptCodeDisplayName(const ULocaleDisplayNames *ldn,
|
190
|
+
UScriptCode scriptCode,
|
191
|
+
UChar *result,
|
192
|
+
int32_t maxResultSize,
|
193
|
+
UErrorCode *pErrorCode);
|
194
|
+
|
195
|
+
/**
|
196
|
+
* Returns the display name of the provided region code.
|
197
|
+
* @param ldn the LocaleDisplayNames instance
|
198
|
+
* @param region the region code whose display name to return
|
199
|
+
* @param result receives the display name
|
200
|
+
* @param maxResultSize the size of the result buffer
|
201
|
+
* @param pErrorCode the status code
|
202
|
+
* @return the actual buffer size needed for the display name. If it's
|
203
|
+
* greater than maxResultSize, the returned name will be truncated.
|
204
|
+
* @stable ICU 4.4
|
205
|
+
*/
|
206
|
+
U_STABLE int32_t U_EXPORT2
|
207
|
+
uldn_regionDisplayName(const ULocaleDisplayNames *ldn,
|
208
|
+
const char *region,
|
209
|
+
UChar *result,
|
210
|
+
int32_t maxResultSize,
|
211
|
+
UErrorCode *pErrorCode);
|
212
|
+
|
213
|
+
/**
|
214
|
+
* Returns the display name of the provided variant
|
215
|
+
* @param ldn the LocaleDisplayNames instance
|
216
|
+
* @param variant the variant whose display name to return
|
217
|
+
* @param result receives the display name
|
218
|
+
* @param maxResultSize the size of the result buffer
|
219
|
+
* @param pErrorCode the status code
|
220
|
+
* @return the actual buffer size needed for the display name. If it's
|
221
|
+
* greater than maxResultSize, the returned name will be truncated.
|
222
|
+
* @stable ICU 4.4
|
223
|
+
*/
|
224
|
+
U_STABLE int32_t U_EXPORT2
|
225
|
+
uldn_variantDisplayName(const ULocaleDisplayNames *ldn,
|
226
|
+
const char *variant,
|
227
|
+
UChar *result,
|
228
|
+
int32_t maxResultSize,
|
229
|
+
UErrorCode *pErrorCode);
|
230
|
+
|
231
|
+
/**
|
232
|
+
* Returns the display name of the provided locale key
|
233
|
+
* @param ldn the LocaleDisplayNames instance
|
234
|
+
* @param key the locale key whose display name to return
|
235
|
+
* @param result receives the display name
|
236
|
+
* @param maxResultSize the size of the result buffer
|
237
|
+
* @param pErrorCode the status code
|
238
|
+
* @return the actual buffer size needed for the display name. If it's
|
239
|
+
* greater than maxResultSize, the returned name will be truncated.
|
240
|
+
* @stable ICU 4.4
|
241
|
+
*/
|
242
|
+
U_STABLE int32_t U_EXPORT2
|
243
|
+
uldn_keyDisplayName(const ULocaleDisplayNames *ldn,
|
244
|
+
const char *key,
|
245
|
+
UChar *result,
|
246
|
+
int32_t maxResultSize,
|
247
|
+
UErrorCode *pErrorCode);
|
248
|
+
|
249
|
+
/**
|
250
|
+
* Returns the display name of the provided value (used with the provided key).
|
251
|
+
* @param ldn the LocaleDisplayNames instance
|
252
|
+
* @param key the locale key
|
253
|
+
* @param value the locale key's value
|
254
|
+
* @param result receives the display name
|
255
|
+
* @param maxResultSize the size of the result buffer
|
256
|
+
* @param pErrorCode the status code
|
257
|
+
* @return the actual buffer size needed for the display name. If it's
|
258
|
+
* greater than maxResultSize, the returned name will be truncated.
|
259
|
+
* @stable ICU 4.4
|
260
|
+
*/
|
261
|
+
U_STABLE int32_t U_EXPORT2
|
262
|
+
uldn_keyValueDisplayName(const ULocaleDisplayNames *ldn,
|
263
|
+
const char *key,
|
264
|
+
const char *value,
|
265
|
+
UChar *result,
|
266
|
+
int32_t maxResultSize,
|
267
|
+
UErrorCode *pErrorCode);
|
268
|
+
|
269
|
+
/**
|
270
|
+
* Returns an instance of LocaleDisplayNames that returns names formatted
|
271
|
+
* for the provided locale, using the provided UDisplayContext settings.
|
272
|
+
*
|
273
|
+
* @param locale The display locale
|
274
|
+
* @param contexts List of one or more context settings (e.g. for dialect
|
275
|
+
* handling, capitalization, etc.
|
276
|
+
* @param length Number of items in the contexts list
|
277
|
+
* @param pErrorCode Pointer to UErrorCode input/output status. If at entry this indicates
|
278
|
+
* a failure status, the function will do nothing; otherwise this will be
|
279
|
+
* updated with any new status from the function.
|
280
|
+
* @return a ULocaleDisplayNames instance
|
281
|
+
* @stable ICU 51
|
282
|
+
*/
|
283
|
+
U_STABLE ULocaleDisplayNames * U_EXPORT2
|
284
|
+
uldn_openForContext(const char * locale, UDisplayContext *contexts,
|
285
|
+
int32_t length, UErrorCode *pErrorCode);
|
286
|
+
|
287
|
+
/**
|
288
|
+
* Returns the UDisplayContext value for the specified UDisplayContextType.
|
289
|
+
* @param ldn the ULocaleDisplayNames instance
|
290
|
+
* @param type the UDisplayContextType whose value to return
|
291
|
+
* @param pErrorCode Pointer to UErrorCode input/output status. If at entry this indicates
|
292
|
+
* a failure status, the function will do nothing; otherwise this will be
|
293
|
+
* updated with any new status from the function.
|
294
|
+
* @return the UDisplayContextValue for the specified type.
|
295
|
+
* @stable ICU 51
|
296
|
+
*/
|
297
|
+
U_STABLE UDisplayContext U_EXPORT2
|
298
|
+
uldn_getContext(const ULocaleDisplayNames *ldn, UDisplayContextType type,
|
299
|
+
UErrorCode *pErrorCode);
|
300
|
+
|
301
|
+
#endif /* !UCONFIG_NO_FORMATTING */
|
302
|
+
#endif /* __ULDNAMES_H__ */
|
@@ -0,0 +1,1256 @@
|
|
1
|
+
/*
|
2
|
+
**********************************************************************
|
3
|
+
* Copyright (C) 1997-2014, International Business Machines
|
4
|
+
* Corporation and others. All Rights Reserved.
|
5
|
+
**********************************************************************
|
6
|
+
*
|
7
|
+
* File ULOC.H
|
8
|
+
*
|
9
|
+
* Modification History:
|
10
|
+
*
|
11
|
+
* Date Name Description
|
12
|
+
* 04/01/97 aliu Creation.
|
13
|
+
* 08/22/98 stephen JDK 1.2 sync.
|
14
|
+
* 12/08/98 rtg New C API for Locale
|
15
|
+
* 03/30/99 damiba overhaul
|
16
|
+
* 03/31/99 helena Javadoc for uloc functions.
|
17
|
+
* 04/15/99 Madhu Updated Javadoc
|
18
|
+
********************************************************************************
|
19
|
+
*/
|
20
|
+
|
21
|
+
#ifndef ULOC_H
|
22
|
+
#define ULOC_H
|
23
|
+
|
24
|
+
#include "unicode/utypes.h"
|
25
|
+
#include "unicode/uenum.h"
|
26
|
+
|
27
|
+
/**
|
28
|
+
* \file
|
29
|
+
* \brief C API: Locale
|
30
|
+
*
|
31
|
+
* <h2> ULoc C API for Locale </h2>
|
32
|
+
* A <code>Locale</code> represents a specific geographical, political,
|
33
|
+
* or cultural region. An operation that requires a <code>Locale</code> to perform
|
34
|
+
* its task is called <em>locale-sensitive</em> and uses the <code>Locale</code>
|
35
|
+
* to tailor information for the user. For example, displaying a number
|
36
|
+
* is a locale-sensitive operation--the number should be formatted
|
37
|
+
* according to the customs/conventions of the user's native country,
|
38
|
+
* region, or culture. In the C APIs, a locales is simply a const char string.
|
39
|
+
*
|
40
|
+
* <P>
|
41
|
+
* You create a <code>Locale</code> with one of the three options listed below.
|
42
|
+
* Each of the component is separated by '_' in the locale string.
|
43
|
+
* \htmlonly<blockquote>\endhtmlonly
|
44
|
+
* <pre>
|
45
|
+
* \code
|
46
|
+
* newLanguage
|
47
|
+
*
|
48
|
+
* newLanguage + newCountry
|
49
|
+
*
|
50
|
+
* newLanguage + newCountry + newVariant
|
51
|
+
* \endcode
|
52
|
+
* </pre>
|
53
|
+
* \htmlonly</blockquote>\endhtmlonly
|
54
|
+
* The first option is a valid <STRONG>ISO
|
55
|
+
* Language Code.</STRONG> These codes are the lower-case two-letter
|
56
|
+
* codes as defined by ISO-639.
|
57
|
+
* You can find a full list of these codes at a number of sites, such as:
|
58
|
+
* <BR><a href ="http://www.ics.uci.edu/pub/ietf/http/related/iso639.txt">
|
59
|
+
* http://www.ics.uci.edu/pub/ietf/http/related/iso639.txt</a>
|
60
|
+
*
|
61
|
+
* <P>
|
62
|
+
* The second option includes an additonal <STRONG>ISO Country
|
63
|
+
* Code.</STRONG> These codes are the upper-case two-letter codes
|
64
|
+
* as defined by ISO-3166.
|
65
|
+
* You can find a full list of these codes at a number of sites, such as:
|
66
|
+
* <BR><a href="http://www.chemie.fu-berlin.de/diverse/doc/ISO_3166.html">
|
67
|
+
* http://www.chemie.fu-berlin.de/diverse/doc/ISO_3166.html</a>
|
68
|
+
*
|
69
|
+
* <P>
|
70
|
+
* The third option requires another additonal information--the
|
71
|
+
* <STRONG>Variant.</STRONG>
|
72
|
+
* The Variant codes are vendor and browser-specific.
|
73
|
+
* For example, use WIN for Windows, MAC for Macintosh, and POSIX for POSIX.
|
74
|
+
* Where there are two variants, separate them with an underscore, and
|
75
|
+
* put the most important one first. For
|
76
|
+
* example, a Traditional Spanish collation might be referenced, with
|
77
|
+
* "ES", "ES", "Traditional_WIN".
|
78
|
+
*
|
79
|
+
* <P>
|
80
|
+
* Because a <code>Locale</code> is just an identifier for a region,
|
81
|
+
* no validity check is performed when you specify a <code>Locale</code>.
|
82
|
+
* If you want to see whether particular resources are available for the
|
83
|
+
* <code>Locale</code> you asked for, you must query those resources. For
|
84
|
+
* example, ask the <code>UNumberFormat</code> for the locales it supports
|
85
|
+
* using its <code>getAvailable</code> method.
|
86
|
+
* <BR><STRONG>Note:</STRONG> When you ask for a resource for a particular
|
87
|
+
* locale, you get back the best available match, not necessarily
|
88
|
+
* precisely what you asked for. For more information, look at
|
89
|
+
* <code>UResourceBundle</code>.
|
90
|
+
*
|
91
|
+
* <P>
|
92
|
+
* The <code>Locale</code> provides a number of convenient constants
|
93
|
+
* that you can use to specify the commonly used
|
94
|
+
* locales. For example, the following refers to a locale
|
95
|
+
* for the United States:
|
96
|
+
* \htmlonly<blockquote>\endhtmlonly
|
97
|
+
* <pre>
|
98
|
+
* \code
|
99
|
+
* ULOC_US
|
100
|
+
* \endcode
|
101
|
+
* </pre>
|
102
|
+
* \htmlonly</blockquote>\endhtmlonly
|
103
|
+
*
|
104
|
+
* <P>
|
105
|
+
* Once you've specified a locale you can query it for information about
|
106
|
+
* itself. Use <code>uloc_getCountry</code> to get the ISO Country Code and
|
107
|
+
* <code>uloc_getLanguage</code> to get the ISO Language Code. You can
|
108
|
+
* use <code>uloc_getDisplayCountry</code> to get the
|
109
|
+
* name of the country suitable for displaying to the user. Similarly,
|
110
|
+
* you can use <code>uloc_getDisplayLanguage</code> to get the name of
|
111
|
+
* the language suitable for displaying to the user. Interestingly,
|
112
|
+
* the <code>uloc_getDisplayXXX</code> methods are themselves locale-sensitive
|
113
|
+
* and have two versions: one that uses the default locale and one
|
114
|
+
* that takes a locale as an argument and displays the name or country in
|
115
|
+
* a language appropriate to that locale.
|
116
|
+
*
|
117
|
+
* <P>
|
118
|
+
* The ICU provides a number of services that perform locale-sensitive
|
119
|
+
* operations. For example, the <code>unum_xxx</code> functions format
|
120
|
+
* numbers, currency, or percentages in a locale-sensitive manner.
|
121
|
+
* </P>
|
122
|
+
* \htmlonly<blockquote>\endhtmlonly
|
123
|
+
* <pre>
|
124
|
+
* \code
|
125
|
+
* UErrorCode success = U_ZERO_ERROR;
|
126
|
+
* UNumberFormat *nf;
|
127
|
+
* const char* myLocale = "fr_FR";
|
128
|
+
*
|
129
|
+
* nf = unum_open( UNUM_DEFAULT, NULL, success );
|
130
|
+
* unum_close(nf);
|
131
|
+
* nf = unum_open( UNUM_CURRENCY, NULL, success );
|
132
|
+
* unum_close(nf);
|
133
|
+
* nf = unum_open( UNUM_PERCENT, NULL, success );
|
134
|
+
* unum_close(nf);
|
135
|
+
* \endcode
|
136
|
+
* </pre>
|
137
|
+
* \htmlonly</blockquote>\endhtmlonly
|
138
|
+
* Each of these methods has two variants; one with an explicit locale
|
139
|
+
* and one without; the latter using the default locale.
|
140
|
+
* \htmlonly<blockquote>\endhtmlonly
|
141
|
+
* <pre>
|
142
|
+
* \code
|
143
|
+
*
|
144
|
+
* nf = unum_open( UNUM_DEFAULT, myLocale, success );
|
145
|
+
* unum_close(nf);
|
146
|
+
* nf = unum_open( UNUM_CURRENCY, myLocale, success );
|
147
|
+
* unum_close(nf);
|
148
|
+
* nf = unum_open( UNUM_PERCENT, myLocale, success );
|
149
|
+
* unum_close(nf);
|
150
|
+
* \endcode
|
151
|
+
* </pre>
|
152
|
+
* \htmlonly</blockquote>\endhtmlonly
|
153
|
+
* A <code>Locale</code> is the mechanism for identifying the kind of services
|
154
|
+
* (<code>UNumberFormat</code>) that you would like to get. The locale is
|
155
|
+
* <STRONG>just</STRONG> a mechanism for identifying these services.
|
156
|
+
*
|
157
|
+
* <P>
|
158
|
+
* Each international serivce that performs locale-sensitive operations
|
159
|
+
* allows you
|
160
|
+
* to get all the available objects of that type. You can sift
|
161
|
+
* through these objects by language, country, or variant,
|
162
|
+
* and use the display names to present a menu to the user.
|
163
|
+
* For example, you can create a menu of all the collation objects
|
164
|
+
* suitable for a given language. Such classes implement these
|
165
|
+
* three class methods:
|
166
|
+
* \htmlonly<blockquote>\endhtmlonly
|
167
|
+
* <pre>
|
168
|
+
* \code
|
169
|
+
* const char* uloc_getAvailable(int32_t index);
|
170
|
+
* int32_t uloc_countAvailable();
|
171
|
+
* int32_t
|
172
|
+
* uloc_getDisplayName(const char* localeID,
|
173
|
+
* const char* inLocaleID,
|
174
|
+
* UChar* result,
|
175
|
+
* int32_t maxResultSize,
|
176
|
+
* UErrorCode* err);
|
177
|
+
*
|
178
|
+
* \endcode
|
179
|
+
* </pre>
|
180
|
+
* \htmlonly</blockquote>\endhtmlonly
|
181
|
+
* <P>
|
182
|
+
* Concerning POSIX/RFC1766 Locale IDs,
|
183
|
+
* the getLanguage/getCountry/getVariant/getName functions do understand
|
184
|
+
* the POSIX type form of language_COUNTRY.ENCODING\@VARIANT
|
185
|
+
* and if there is not an ICU-stype variant, uloc_getVariant() for example
|
186
|
+
* will return the one listed after the \@at sign. As well, the hyphen
|
187
|
+
* "-" is recognized as a country/variant separator similarly to RFC1766.
|
188
|
+
* So for example, "en-us" will be interpreted as en_US.
|
189
|
+
* As a result, uloc_getName() is far from a no-op, and will have the
|
190
|
+
* effect of converting POSIX/RFC1766 IDs into ICU form, although it does
|
191
|
+
* NOT map any of the actual codes (i.e. russian->ru) in any way.
|
192
|
+
* Applications should call uloc_getName() at the point where a locale ID
|
193
|
+
* is coming from an external source (user entry, OS, web browser)
|
194
|
+
* and pass the resulting string to other ICU functions. For example,
|
195
|
+
* don't use de-de\@EURO as an argument to resourcebundle.
|
196
|
+
*
|
197
|
+
* @see UResourceBundle
|
198
|
+
*/
|
199
|
+
|
200
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
201
|
+
#define ULOC_CHINESE "zh"
|
202
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
203
|
+
#define ULOC_ENGLISH "en"
|
204
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
205
|
+
#define ULOC_FRENCH "fr"
|
206
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
207
|
+
#define ULOC_GERMAN "de"
|
208
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
209
|
+
#define ULOC_ITALIAN "it"
|
210
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
211
|
+
#define ULOC_JAPANESE "ja"
|
212
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
213
|
+
#define ULOC_KOREAN "ko"
|
214
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
215
|
+
#define ULOC_SIMPLIFIED_CHINESE "zh_CN"
|
216
|
+
/** Useful constant for this language. @stable ICU 2.0 */
|
217
|
+
#define ULOC_TRADITIONAL_CHINESE "zh_TW"
|
218
|
+
|
219
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
220
|
+
#define ULOC_CANADA "en_CA"
|
221
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
222
|
+
#define ULOC_CANADA_FRENCH "fr_CA"
|
223
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
224
|
+
#define ULOC_CHINA "zh_CN"
|
225
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
226
|
+
#define ULOC_PRC "zh_CN"
|
227
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
228
|
+
#define ULOC_FRANCE "fr_FR"
|
229
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
230
|
+
#define ULOC_GERMANY "de_DE"
|
231
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
232
|
+
#define ULOC_ITALY "it_IT"
|
233
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
234
|
+
#define ULOC_JAPAN "ja_JP"
|
235
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
236
|
+
#define ULOC_KOREA "ko_KR"
|
237
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
238
|
+
#define ULOC_TAIWAN "zh_TW"
|
239
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
240
|
+
#define ULOC_UK "en_GB"
|
241
|
+
/** Useful constant for this country/region. @stable ICU 2.0 */
|
242
|
+
#define ULOC_US "en_US"
|
243
|
+
|
244
|
+
/**
|
245
|
+
* Useful constant for the maximum size of the language part of a locale ID.
|
246
|
+
* (including the terminating NULL).
|
247
|
+
* @stable ICU 2.0
|
248
|
+
*/
|
249
|
+
#define ULOC_LANG_CAPACITY 12
|
250
|
+
|
251
|
+
/**
|
252
|
+
* Useful constant for the maximum size of the country part of a locale ID
|
253
|
+
* (including the terminating NULL).
|
254
|
+
* @stable ICU 2.0
|
255
|
+
*/
|
256
|
+
#define ULOC_COUNTRY_CAPACITY 4
|
257
|
+
/**
|
258
|
+
* Useful constant for the maximum size of the whole locale ID
|
259
|
+
* (including the terminating NULL and all keywords).
|
260
|
+
* @stable ICU 2.0
|
261
|
+
*/
|
262
|
+
#define ULOC_FULLNAME_CAPACITY 157
|
263
|
+
|
264
|
+
/**
|
265
|
+
* Useful constant for the maximum size of the script part of a locale ID
|
266
|
+
* (including the terminating NULL).
|
267
|
+
* @stable ICU 2.8
|
268
|
+
*/
|
269
|
+
#define ULOC_SCRIPT_CAPACITY 6
|
270
|
+
|
271
|
+
/**
|
272
|
+
* Useful constant for the maximum size of keywords in a locale
|
273
|
+
* @stable ICU 2.8
|
274
|
+
*/
|
275
|
+
#define ULOC_KEYWORDS_CAPACITY 96
|
276
|
+
|
277
|
+
/**
|
278
|
+
* Useful constant for the maximum total size of keywords and their values in a locale
|
279
|
+
* @stable ICU 2.8
|
280
|
+
*/
|
281
|
+
#define ULOC_KEYWORD_AND_VALUES_CAPACITY 100
|
282
|
+
|
283
|
+
/**
|
284
|
+
* Invariant character separating keywords from the locale string
|
285
|
+
* @stable ICU 2.8
|
286
|
+
*/
|
287
|
+
#define ULOC_KEYWORD_SEPARATOR '@'
|
288
|
+
|
289
|
+
/**
|
290
|
+
* Unicode code point for '@' separating keywords from the locale string.
|
291
|
+
* @see ULOC_KEYWORD_SEPARATOR
|
292
|
+
* @stable ICU 4.6
|
293
|
+
*/
|
294
|
+
#define ULOC_KEYWORD_SEPARATOR_UNICODE 0x40
|
295
|
+
|
296
|
+
/**
|
297
|
+
* Invariant character for assigning value to a keyword
|
298
|
+
* @stable ICU 2.8
|
299
|
+
*/
|
300
|
+
#define ULOC_KEYWORD_ASSIGN '='
|
301
|
+
|
302
|
+
/**
|
303
|
+
* Unicode code point for '=' for assigning value to a keyword.
|
304
|
+
* @see ULOC_KEYWORD_ASSIGN
|
305
|
+
* @stable ICU 4.6
|
306
|
+
*/
|
307
|
+
#define ULOC_KEYWORD_ASSIGN_UNICODE 0x3D
|
308
|
+
|
309
|
+
/**
|
310
|
+
* Invariant character separating keywords
|
311
|
+
* @stable ICU 2.8
|
312
|
+
*/
|
313
|
+
#define ULOC_KEYWORD_ITEM_SEPARATOR ';'
|
314
|
+
|
315
|
+
/**
|
316
|
+
* Unicode code point for ';' separating keywords
|
317
|
+
* @see ULOC_KEYWORD_ITEM_SEPARATOR
|
318
|
+
* @stable ICU 4.6
|
319
|
+
*/
|
320
|
+
#define ULOC_KEYWORD_ITEM_SEPARATOR_UNICODE 0x3B
|
321
|
+
|
322
|
+
/**
|
323
|
+
* Constants for *_getLocale()
|
324
|
+
* Allow user to select whether she wants information on
|
325
|
+
* requested, valid or actual locale.
|
326
|
+
* For example, a collator for "en_US_CALIFORNIA" was
|
327
|
+
* requested. In the current state of ICU (2.0),
|
328
|
+
* the requested locale is "en_US_CALIFORNIA",
|
329
|
+
* the valid locale is "en_US" (most specific locale supported by ICU)
|
330
|
+
* and the actual locale is "root" (the collation data comes unmodified
|
331
|
+
* from the UCA)
|
332
|
+
* The locale is considered supported by ICU if there is a core ICU bundle
|
333
|
+
* for that locale (although it may be empty).
|
334
|
+
* @stable ICU 2.1
|
335
|
+
*/
|
336
|
+
typedef enum {
|
337
|
+
/** This is locale the data actually comes from
|
338
|
+
* @stable ICU 2.1
|
339
|
+
*/
|
340
|
+
ULOC_ACTUAL_LOCALE = 0,
|
341
|
+
/** This is the most specific locale supported by ICU
|
342
|
+
* @stable ICU 2.1
|
343
|
+
*/
|
344
|
+
ULOC_VALID_LOCALE = 1,
|
345
|
+
|
346
|
+
#ifndef U_HIDE_DEPRECATED_API
|
347
|
+
/** This is the requested locale
|
348
|
+
* @deprecated ICU 2.8
|
349
|
+
*/
|
350
|
+
ULOC_REQUESTED_LOCALE = 2,
|
351
|
+
#endif /* U_HIDE_DEPRECATED_API */
|
352
|
+
|
353
|
+
ULOC_DATA_LOCALE_TYPE_LIMIT = 3
|
354
|
+
} ULocDataLocaleType ;
|
355
|
+
|
356
|
+
#ifndef U_HIDE_SYSTEM_API
|
357
|
+
/**
|
358
|
+
* Gets ICU's default locale.
|
359
|
+
* The returned string is a snapshot in time, and will remain valid
|
360
|
+
* and unchanged even when uloc_setDefault() is called.
|
361
|
+
* The returned storage is owned by ICU, and must not be altered or deleted
|
362
|
+
* by the caller.
|
363
|
+
*
|
364
|
+
* @return the ICU default locale
|
365
|
+
* @system
|
366
|
+
* @stable ICU 2.0
|
367
|
+
*/
|
368
|
+
U_STABLE const char* U_EXPORT2
|
369
|
+
uloc_getDefault(void);
|
370
|
+
|
371
|
+
/**
|
372
|
+
* Sets ICU's default locale.
|
373
|
+
* By default (without calling this function), ICU's default locale will be based
|
374
|
+
* on information obtained from the underlying system environment.
|
375
|
+
* <p>
|
376
|
+
* Changes to ICU's default locale do not propagate back to the
|
377
|
+
* system environment.
|
378
|
+
* <p>
|
379
|
+
* Changes to ICU's default locale to not affect any ICU services that
|
380
|
+
* may already be open based on the previous default locale value.
|
381
|
+
*
|
382
|
+
* @param localeID the new ICU default locale. A value of NULL will try to get
|
383
|
+
* the system's default locale.
|
384
|
+
* @param status the error information if the setting of default locale fails
|
385
|
+
* @system
|
386
|
+
* @stable ICU 2.0
|
387
|
+
*/
|
388
|
+
U_STABLE void U_EXPORT2
|
389
|
+
uloc_setDefault(const char* localeID,
|
390
|
+
UErrorCode* status);
|
391
|
+
#endif /* U_HIDE_SYSTEM_API */
|
392
|
+
|
393
|
+
/**
|
394
|
+
* Gets the language code for the specified locale.
|
395
|
+
*
|
396
|
+
* @param localeID the locale to get the ISO language code with
|
397
|
+
* @param language the language code for localeID
|
398
|
+
* @param languageCapacity the size of the language buffer to store the
|
399
|
+
* language code with
|
400
|
+
* @param err error information if retrieving the language code failed
|
401
|
+
* @return the actual buffer size needed for the language code. If it's greater
|
402
|
+
* than languageCapacity, the returned language code will be truncated.
|
403
|
+
* @stable ICU 2.0
|
404
|
+
*/
|
405
|
+
U_STABLE int32_t U_EXPORT2
|
406
|
+
uloc_getLanguage(const char* localeID,
|
407
|
+
char* language,
|
408
|
+
int32_t languageCapacity,
|
409
|
+
UErrorCode* err);
|
410
|
+
|
411
|
+
/**
|
412
|
+
* Gets the script code for the specified locale.
|
413
|
+
*
|
414
|
+
* @param localeID the locale to get the ISO language code with
|
415
|
+
* @param script the language code for localeID
|
416
|
+
* @param scriptCapacity the size of the language buffer to store the
|
417
|
+
* language code with
|
418
|
+
* @param err error information if retrieving the language code failed
|
419
|
+
* @return the actual buffer size needed for the language code. If it's greater
|
420
|
+
* than scriptCapacity, the returned language code will be truncated.
|
421
|
+
* @stable ICU 2.8
|
422
|
+
*/
|
423
|
+
U_STABLE int32_t U_EXPORT2
|
424
|
+
uloc_getScript(const char* localeID,
|
425
|
+
char* script,
|
426
|
+
int32_t scriptCapacity,
|
427
|
+
UErrorCode* err);
|
428
|
+
|
429
|
+
/**
|
430
|
+
* Gets the country code for the specified locale.
|
431
|
+
*
|
432
|
+
* @param localeID the locale to get the country code with
|
433
|
+
* @param country the country code for localeID
|
434
|
+
* @param countryCapacity the size of the country buffer to store the
|
435
|
+
* country code with
|
436
|
+
* @param err error information if retrieving the country code failed
|
437
|
+
* @return the actual buffer size needed for the country code. If it's greater
|
438
|
+
* than countryCapacity, the returned country code will be truncated.
|
439
|
+
* @stable ICU 2.0
|
440
|
+
*/
|
441
|
+
U_STABLE int32_t U_EXPORT2
|
442
|
+
uloc_getCountry(const char* localeID,
|
443
|
+
char* country,
|
444
|
+
int32_t countryCapacity,
|
445
|
+
UErrorCode* err);
|
446
|
+
|
447
|
+
/**
|
448
|
+
* Gets the variant code for the specified locale.
|
449
|
+
*
|
450
|
+
* @param localeID the locale to get the variant code with
|
451
|
+
* @param variant the variant code for localeID
|
452
|
+
* @param variantCapacity the size of the variant buffer to store the
|
453
|
+
* variant code with
|
454
|
+
* @param err error information if retrieving the variant code failed
|
455
|
+
* @return the actual buffer size needed for the variant code. If it's greater
|
456
|
+
* than variantCapacity, the returned variant code will be truncated.
|
457
|
+
* @stable ICU 2.0
|
458
|
+
*/
|
459
|
+
U_STABLE int32_t U_EXPORT2
|
460
|
+
uloc_getVariant(const char* localeID,
|
461
|
+
char* variant,
|
462
|
+
int32_t variantCapacity,
|
463
|
+
UErrorCode* err);
|
464
|
+
|
465
|
+
|
466
|
+
/**
|
467
|
+
* Gets the full name for the specified locale.
|
468
|
+
* Note: This has the effect of 'canonicalizing' the ICU locale ID to
|
469
|
+
* a certain extent. Upper and lower case are set as needed.
|
470
|
+
* It does NOT map aliased names in any way.
|
471
|
+
* See the top of this header file.
|
472
|
+
* This API supports preflighting.
|
473
|
+
*
|
474
|
+
* @param localeID the locale to get the full name with
|
475
|
+
* @param name fill in buffer for the name without keywords.
|
476
|
+
* @param nameCapacity capacity of the fill in buffer.
|
477
|
+
* @param err error information if retrieving the full name failed
|
478
|
+
* @return the actual buffer size needed for the full name. If it's greater
|
479
|
+
* than nameCapacity, the returned full name will be truncated.
|
480
|
+
* @stable ICU 2.0
|
481
|
+
*/
|
482
|
+
U_STABLE int32_t U_EXPORT2
|
483
|
+
uloc_getName(const char* localeID,
|
484
|
+
char* name,
|
485
|
+
int32_t nameCapacity,
|
486
|
+
UErrorCode* err);
|
487
|
+
|
488
|
+
/**
|
489
|
+
* Gets the full name for the specified locale.
|
490
|
+
* Note: This has the effect of 'canonicalizing' the string to
|
491
|
+
* a certain extent. Upper and lower case are set as needed,
|
492
|
+
* and if the components were in 'POSIX' format they are changed to
|
493
|
+
* ICU format. It does NOT map aliased names in any way.
|
494
|
+
* See the top of this header file.
|
495
|
+
*
|
496
|
+
* @param localeID the locale to get the full name with
|
497
|
+
* @param name the full name for localeID
|
498
|
+
* @param nameCapacity the size of the name buffer to store the
|
499
|
+
* full name with
|
500
|
+
* @param err error information if retrieving the full name failed
|
501
|
+
* @return the actual buffer size needed for the full name. If it's greater
|
502
|
+
* than nameCapacity, the returned full name will be truncated.
|
503
|
+
* @stable ICU 2.8
|
504
|
+
*/
|
505
|
+
U_STABLE int32_t U_EXPORT2
|
506
|
+
uloc_canonicalize(const char* localeID,
|
507
|
+
char* name,
|
508
|
+
int32_t nameCapacity,
|
509
|
+
UErrorCode* err);
|
510
|
+
|
511
|
+
/**
|
512
|
+
* Gets the ISO language code for the specified locale.
|
513
|
+
*
|
514
|
+
* @param localeID the locale to get the ISO language code with
|
515
|
+
* @return language the ISO language code for localeID
|
516
|
+
* @stable ICU 2.0
|
517
|
+
*/
|
518
|
+
U_STABLE const char* U_EXPORT2
|
519
|
+
uloc_getISO3Language(const char* localeID);
|
520
|
+
|
521
|
+
|
522
|
+
/**
|
523
|
+
* Gets the ISO country code for the specified locale.
|
524
|
+
*
|
525
|
+
* @param localeID the locale to get the ISO country code with
|
526
|
+
* @return country the ISO country code for localeID
|
527
|
+
* @stable ICU 2.0
|
528
|
+
*/
|
529
|
+
U_STABLE const char* U_EXPORT2
|
530
|
+
uloc_getISO3Country(const char* localeID);
|
531
|
+
|
532
|
+
/**
|
533
|
+
* Gets the Win32 LCID value for the specified locale.
|
534
|
+
* If the ICU locale is not recognized by Windows, 0 will be returned.
|
535
|
+
*
|
536
|
+
* @param localeID the locale to get the Win32 LCID value with
|
537
|
+
* @return country the Win32 LCID for localeID
|
538
|
+
* @stable ICU 2.0
|
539
|
+
*/
|
540
|
+
U_STABLE uint32_t U_EXPORT2
|
541
|
+
uloc_getLCID(const char* localeID);
|
542
|
+
|
543
|
+
/**
|
544
|
+
* Gets the language name suitable for display for the specified locale.
|
545
|
+
*
|
546
|
+
* @param locale the locale to get the ISO language code with
|
547
|
+
* @param displayLocale Specifies the locale to be used to display the name. In other words,
|
548
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
549
|
+
* inLocale would result in "Anglais", while passing Locale::getGerman()
|
550
|
+
* for inLocale would result in "Englisch".
|
551
|
+
* @param language the displayable language code for localeID
|
552
|
+
* @param languageCapacity the size of the language buffer to store the
|
553
|
+
* displayable language code with
|
554
|
+
* @param status error information if retrieving the displayable language code failed
|
555
|
+
* @return the actual buffer size needed for the displayable language code. If it's greater
|
556
|
+
* than languageCapacity, the returned language code will be truncated.
|
557
|
+
* @stable ICU 2.0
|
558
|
+
*/
|
559
|
+
U_STABLE int32_t U_EXPORT2
|
560
|
+
uloc_getDisplayLanguage(const char* locale,
|
561
|
+
const char* displayLocale,
|
562
|
+
UChar* language,
|
563
|
+
int32_t languageCapacity,
|
564
|
+
UErrorCode* status);
|
565
|
+
|
566
|
+
/**
|
567
|
+
* Gets the script name suitable for display for the specified locale.
|
568
|
+
*
|
569
|
+
* @param locale the locale to get the displayable script code with. NULL may be used to specify the default.
|
570
|
+
* @param displayLocale Specifies the locale to be used to display the name. In other words,
|
571
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
572
|
+
* inLocale would result in "", while passing Locale::getGerman()
|
573
|
+
* for inLocale would result in "". NULL may be used to specify the default.
|
574
|
+
* @param script the displayable country code for localeID
|
575
|
+
* @param scriptCapacity the size of the script buffer to store the
|
576
|
+
* displayable script code with
|
577
|
+
* @param status error information if retrieving the displayable script code failed
|
578
|
+
* @return the actual buffer size needed for the displayable script code. If it's greater
|
579
|
+
* than scriptCapacity, the returned displayable script code will be truncated.
|
580
|
+
* @stable ICU 2.8
|
581
|
+
*/
|
582
|
+
U_STABLE int32_t U_EXPORT2
|
583
|
+
uloc_getDisplayScript(const char* locale,
|
584
|
+
const char* displayLocale,
|
585
|
+
UChar* script,
|
586
|
+
int32_t scriptCapacity,
|
587
|
+
UErrorCode* status);
|
588
|
+
|
589
|
+
/**
|
590
|
+
* Gets the country name suitable for display for the specified locale.
|
591
|
+
*
|
592
|
+
* @param locale the locale to get the displayable country code with. NULL may be used to specify the default.
|
593
|
+
* @param displayLocale Specifies the locale to be used to display the name. In other words,
|
594
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
595
|
+
* inLocale would result in "Anglais", while passing Locale::getGerman()
|
596
|
+
* for inLocale would result in "Englisch". NULL may be used to specify the default.
|
597
|
+
* @param country the displayable country code for localeID
|
598
|
+
* @param countryCapacity the size of the country buffer to store the
|
599
|
+
* displayable country code with
|
600
|
+
* @param status error information if retrieving the displayable country code failed
|
601
|
+
* @return the actual buffer size needed for the displayable country code. If it's greater
|
602
|
+
* than countryCapacity, the returned displayable country code will be truncated.
|
603
|
+
* @stable ICU 2.0
|
604
|
+
*/
|
605
|
+
U_STABLE int32_t U_EXPORT2
|
606
|
+
uloc_getDisplayCountry(const char* locale,
|
607
|
+
const char* displayLocale,
|
608
|
+
UChar* country,
|
609
|
+
int32_t countryCapacity,
|
610
|
+
UErrorCode* status);
|
611
|
+
|
612
|
+
|
613
|
+
/**
|
614
|
+
* Gets the variant name suitable for display for the specified locale.
|
615
|
+
*
|
616
|
+
* @param locale the locale to get the displayable variant code with. NULL may be used to specify the default.
|
617
|
+
* @param displayLocale Specifies the locale to be used to display the name. In other words,
|
618
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
619
|
+
* inLocale would result in "Anglais", while passing Locale::getGerman()
|
620
|
+
* for inLocale would result in "Englisch". NULL may be used to specify the default.
|
621
|
+
* @param variant the displayable variant code for localeID
|
622
|
+
* @param variantCapacity the size of the variant buffer to store the
|
623
|
+
* displayable variant code with
|
624
|
+
* @param status error information if retrieving the displayable variant code failed
|
625
|
+
* @return the actual buffer size needed for the displayable variant code. If it's greater
|
626
|
+
* than variantCapacity, the returned displayable variant code will be truncated.
|
627
|
+
* @stable ICU 2.0
|
628
|
+
*/
|
629
|
+
U_STABLE int32_t U_EXPORT2
|
630
|
+
uloc_getDisplayVariant(const char* locale,
|
631
|
+
const char* displayLocale,
|
632
|
+
UChar* variant,
|
633
|
+
int32_t variantCapacity,
|
634
|
+
UErrorCode* status);
|
635
|
+
|
636
|
+
/**
|
637
|
+
* Gets the keyword name suitable for display for the specified locale.
|
638
|
+
* E.g: for the locale string de_DE\@collation=PHONEBOOK, this API gets the display
|
639
|
+
* string for the keyword collation.
|
640
|
+
* Usage:
|
641
|
+
* <code>
|
642
|
+
* UErrorCode status = U_ZERO_ERROR;
|
643
|
+
* const char* keyword =NULL;
|
644
|
+
* int32_t keywordLen = 0;
|
645
|
+
* int32_t keywordCount = 0;
|
646
|
+
* UChar displayKeyword[256];
|
647
|
+
* int32_t displayKeywordLen = 0;
|
648
|
+
* UEnumeration* keywordEnum = uloc_openKeywords("de_DE@collation=PHONEBOOK;calendar=TRADITIONAL", &status);
|
649
|
+
* for(keywordCount = uenum_count(keywordEnum, &status); keywordCount > 0 ; keywordCount--){
|
650
|
+
* if(U_FAILURE(status)){
|
651
|
+
* ...something went wrong so handle the error...
|
652
|
+
* break;
|
653
|
+
* }
|
654
|
+
* // the uenum_next returns NUL terminated string
|
655
|
+
* keyword = uenum_next(keywordEnum, &keywordLen, &status);
|
656
|
+
* displayKeywordLen = uloc_getDisplayKeyword(keyword, "en_US", displayKeyword, 256);
|
657
|
+
* ... do something interesting .....
|
658
|
+
* }
|
659
|
+
* uenum_close(keywordEnum);
|
660
|
+
* </code>
|
661
|
+
* @param keyword The keyword whose display string needs to be returned.
|
662
|
+
* @param displayLocale Specifies the locale to be used to display the name. In other words,
|
663
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
664
|
+
* inLocale would result in "Anglais", while passing Locale::getGerman()
|
665
|
+
* for inLocale would result in "Englisch". NULL may be used to specify the default.
|
666
|
+
* @param dest the buffer to which the displayable keyword should be written.
|
667
|
+
* @param destCapacity The size of the buffer (number of UChars). If it is 0, then
|
668
|
+
* dest may be NULL and the function will only return the length of the
|
669
|
+
* result without writing any of the result string (pre-flighting).
|
670
|
+
* @param status error information if retrieving the displayable string failed.
|
671
|
+
* Should not be NULL and should not indicate failure on entry.
|
672
|
+
* @return the actual buffer size needed for the displayable variant code.
|
673
|
+
* @see #uloc_openKeywords
|
674
|
+
* @stable ICU 2.8
|
675
|
+
*/
|
676
|
+
U_STABLE int32_t U_EXPORT2
|
677
|
+
uloc_getDisplayKeyword(const char* keyword,
|
678
|
+
const char* displayLocale,
|
679
|
+
UChar* dest,
|
680
|
+
int32_t destCapacity,
|
681
|
+
UErrorCode* status);
|
682
|
+
/**
|
683
|
+
* Gets the value of the keyword suitable for display for the specified locale.
|
684
|
+
* E.g: for the locale string de_DE\@collation=PHONEBOOK, this API gets the display
|
685
|
+
* string for PHONEBOOK, in the display locale, when "collation" is specified as the keyword.
|
686
|
+
*
|
687
|
+
* @param locale The locale to get the displayable variant code with. NULL may be used to specify the default.
|
688
|
+
* @param keyword The keyword for whose value should be used.
|
689
|
+
* @param displayLocale Specifies the locale to be used to display the name. In other words,
|
690
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
691
|
+
* inLocale would result in "Anglais", while passing Locale::getGerman()
|
692
|
+
* for inLocale would result in "Englisch". NULL may be used to specify the default.
|
693
|
+
* @param dest the buffer to which the displayable keyword should be written.
|
694
|
+
* @param destCapacity The size of the buffer (number of UChars). If it is 0, then
|
695
|
+
* dest may be NULL and the function will only return the length of the
|
696
|
+
* result without writing any of the result string (pre-flighting).
|
697
|
+
* @param status error information if retrieving the displayable string failed.
|
698
|
+
* Should not be NULL and must not indicate failure on entry.
|
699
|
+
* @return the actual buffer size needed for the displayable variant code.
|
700
|
+
* @stable ICU 2.8
|
701
|
+
*/
|
702
|
+
U_STABLE int32_t U_EXPORT2
|
703
|
+
uloc_getDisplayKeywordValue( const char* locale,
|
704
|
+
const char* keyword,
|
705
|
+
const char* displayLocale,
|
706
|
+
UChar* dest,
|
707
|
+
int32_t destCapacity,
|
708
|
+
UErrorCode* status);
|
709
|
+
/**
|
710
|
+
* Gets the full name suitable for display for the specified locale.
|
711
|
+
*
|
712
|
+
* @param localeID the locale to get the displayable name with. NULL may be used to specify the default.
|
713
|
+
* @param inLocaleID Specifies the locale to be used to display the name. In other words,
|
714
|
+
* if the locale's language code is "en", passing Locale::getFrench() for
|
715
|
+
* inLocale would result in "Anglais", while passing Locale::getGerman()
|
716
|
+
* for inLocale would result in "Englisch". NULL may be used to specify the default.
|
717
|
+
* @param result the displayable name for localeID
|
718
|
+
* @param maxResultSize the size of the name buffer to store the
|
719
|
+
* displayable full name with
|
720
|
+
* @param err error information if retrieving the displayable name failed
|
721
|
+
* @return the actual buffer size needed for the displayable name. If it's greater
|
722
|
+
* than maxResultSize, the returned displayable name will be truncated.
|
723
|
+
* @stable ICU 2.0
|
724
|
+
*/
|
725
|
+
U_STABLE int32_t U_EXPORT2
|
726
|
+
uloc_getDisplayName(const char* localeID,
|
727
|
+
const char* inLocaleID,
|
728
|
+
UChar* result,
|
729
|
+
int32_t maxResultSize,
|
730
|
+
UErrorCode* err);
|
731
|
+
|
732
|
+
|
733
|
+
/**
|
734
|
+
* Gets the specified locale from a list of all available locales.
|
735
|
+
* The return value is a pointer to an item of
|
736
|
+
* a locale name array. Both this array and the pointers
|
737
|
+
* it contains are owned by ICU and should not be deleted or written through
|
738
|
+
* by the caller. The locale name is terminated by a null pointer.
|
739
|
+
* @param n the specific locale name index of the available locale list
|
740
|
+
* @return a specified locale name of all available locales
|
741
|
+
* @stable ICU 2.0
|
742
|
+
*/
|
743
|
+
U_STABLE const char* U_EXPORT2
|
744
|
+
uloc_getAvailable(int32_t n);
|
745
|
+
|
746
|
+
/**
|
747
|
+
* Gets the size of the all available locale list.
|
748
|
+
*
|
749
|
+
* @return the size of the locale list
|
750
|
+
* @stable ICU 2.0
|
751
|
+
*/
|
752
|
+
U_STABLE int32_t U_EXPORT2 uloc_countAvailable(void);
|
753
|
+
|
754
|
+
/**
|
755
|
+
*
|
756
|
+
* Gets a list of all available 2-letter language codes defined in ISO 639,
|
757
|
+
* plus additional 3-letter codes determined to be useful for locale generation as
|
758
|
+
* defined by Unicode CLDR. This is a pointer
|
759
|
+
* to an array of pointers to arrays of char. All of these pointers are owned
|
760
|
+
* by ICU-- do not delete them, and do not write through them. The array is
|
761
|
+
* terminated with a null pointer.
|
762
|
+
* @return a list of all available language codes
|
763
|
+
* @stable ICU 2.0
|
764
|
+
*/
|
765
|
+
U_STABLE const char* const* U_EXPORT2
|
766
|
+
uloc_getISOLanguages(void);
|
767
|
+
|
768
|
+
/**
|
769
|
+
*
|
770
|
+
* Gets a list of all available 2-letter country codes defined in ISO 639. This is a
|
771
|
+
* pointer to an array of pointers to arrays of char. All of these pointers are
|
772
|
+
* owned by ICU-- do not delete them, and do not write through them. The array is
|
773
|
+
* terminated with a null pointer.
|
774
|
+
* @return a list of all available country codes
|
775
|
+
* @stable ICU 2.0
|
776
|
+
*/
|
777
|
+
U_STABLE const char* const* U_EXPORT2
|
778
|
+
uloc_getISOCountries(void);
|
779
|
+
|
780
|
+
/**
|
781
|
+
* Truncate the locale ID string to get the parent locale ID.
|
782
|
+
* Copies the part of the string before the last underscore.
|
783
|
+
* The parent locale ID will be an empty string if there is no
|
784
|
+
* underscore, or if there is only one underscore at localeID[0].
|
785
|
+
*
|
786
|
+
* @param localeID Input locale ID string.
|
787
|
+
* @param parent Output string buffer for the parent locale ID.
|
788
|
+
* @param parentCapacity Size of the output buffer.
|
789
|
+
* @param err A UErrorCode value.
|
790
|
+
* @return The length of the parent locale ID.
|
791
|
+
* @stable ICU 2.0
|
792
|
+
*/
|
793
|
+
U_STABLE int32_t U_EXPORT2
|
794
|
+
uloc_getParent(const char* localeID,
|
795
|
+
char* parent,
|
796
|
+
int32_t parentCapacity,
|
797
|
+
UErrorCode* err);
|
798
|
+
|
799
|
+
|
800
|
+
|
801
|
+
|
802
|
+
/**
|
803
|
+
* Gets the full name for the specified locale, like uloc_getName(),
|
804
|
+
* but without keywords.
|
805
|
+
*
|
806
|
+
* Note: This has the effect of 'canonicalizing' the string to
|
807
|
+
* a certain extent. Upper and lower case are set as needed,
|
808
|
+
* and if the components were in 'POSIX' format they are changed to
|
809
|
+
* ICU format. It does NOT map aliased names in any way.
|
810
|
+
* See the top of this header file.
|
811
|
+
*
|
812
|
+
* This API strips off the keyword part, so "de_DE\@collation=phonebook"
|
813
|
+
* will become "de_DE".
|
814
|
+
* This API supports preflighting.
|
815
|
+
*
|
816
|
+
* @param localeID the locale to get the full name with
|
817
|
+
* @param name fill in buffer for the name without keywords.
|
818
|
+
* @param nameCapacity capacity of the fill in buffer.
|
819
|
+
* @param err error information if retrieving the full name failed
|
820
|
+
* @return the actual buffer size needed for the full name. If it's greater
|
821
|
+
* than nameCapacity, the returned full name will be truncated.
|
822
|
+
* @stable ICU 2.8
|
823
|
+
*/
|
824
|
+
U_STABLE int32_t U_EXPORT2
|
825
|
+
uloc_getBaseName(const char* localeID,
|
826
|
+
char* name,
|
827
|
+
int32_t nameCapacity,
|
828
|
+
UErrorCode* err);
|
829
|
+
|
830
|
+
/**
|
831
|
+
* Gets an enumeration of keywords for the specified locale. Enumeration
|
832
|
+
* must get disposed of by the client using uenum_close function.
|
833
|
+
*
|
834
|
+
* @param localeID the locale to get the variant code with
|
835
|
+
* @param status error information if retrieving the keywords failed
|
836
|
+
* @return enumeration of keywords or NULL if there are no keywords.
|
837
|
+
* @stable ICU 2.8
|
838
|
+
*/
|
839
|
+
U_STABLE UEnumeration* U_EXPORT2
|
840
|
+
uloc_openKeywords(const char* localeID,
|
841
|
+
UErrorCode* status);
|
842
|
+
|
843
|
+
/**
|
844
|
+
* Get the value for a keyword. Locale name does not need to be normalized.
|
845
|
+
*
|
846
|
+
* @param localeID locale name containing the keyword ("de_DE@currency=EURO;collation=PHONEBOOK")
|
847
|
+
* @param keywordName name of the keyword for which we want the value. Case insensitive.
|
848
|
+
* @param buffer receiving buffer
|
849
|
+
* @param bufferCapacity capacity of receiving buffer
|
850
|
+
* @param status containing error code - buffer not big enough.
|
851
|
+
* @return the length of keyword value
|
852
|
+
* @stable ICU 2.8
|
853
|
+
*/
|
854
|
+
U_STABLE int32_t U_EXPORT2
|
855
|
+
uloc_getKeywordValue(const char* localeID,
|
856
|
+
const char* keywordName,
|
857
|
+
char* buffer, int32_t bufferCapacity,
|
858
|
+
UErrorCode* status);
|
859
|
+
|
860
|
+
|
861
|
+
/**
|
862
|
+
* Sets or removes the value of the specified keyword.
|
863
|
+
*
|
864
|
+
* For removing all keywords, use uloc_getBaseName().
|
865
|
+
*
|
866
|
+
* NOTE: Unlike almost every other ICU function which takes a
|
867
|
+
* buffer, this function will NOT truncate the output text. If a
|
868
|
+
* BUFFER_OVERFLOW_ERROR is received, it means that the original
|
869
|
+
* buffer is untouched. This is done to prevent incorrect or possibly
|
870
|
+
* even malformed locales from being generated and used.
|
871
|
+
*
|
872
|
+
* @param keywordName name of the keyword to be set. Case insensitive.
|
873
|
+
* @param keywordValue value of the keyword to be set. If 0-length or
|
874
|
+
* NULL, will result in the keyword being removed. No error is given if
|
875
|
+
* that keyword does not exist.
|
876
|
+
* @param buffer input buffer containing locale to be modified.
|
877
|
+
* @param bufferCapacity capacity of receiving buffer
|
878
|
+
* @param status containing error code - buffer not big enough.
|
879
|
+
* @return the length needed for the buffer
|
880
|
+
* @see uloc_getKeywordValue
|
881
|
+
* @stable ICU 3.2
|
882
|
+
*/
|
883
|
+
U_STABLE int32_t U_EXPORT2
|
884
|
+
uloc_setKeywordValue(const char* keywordName,
|
885
|
+
const char* keywordValue,
|
886
|
+
char* buffer, int32_t bufferCapacity,
|
887
|
+
UErrorCode* status);
|
888
|
+
|
889
|
+
#ifndef U_HIDE_DRAFT_API
|
890
|
+
/**
|
891
|
+
* Returns whether the locale's script is written right-to-left.
|
892
|
+
* If there is no script subtag, then the likely script is used, see uloc_addLikelySubtags().
|
893
|
+
* If no likely script is known, then FALSE is returned.
|
894
|
+
*
|
895
|
+
* A script is right-to-left according to the CLDR script metadata
|
896
|
+
* which corresponds to whether the script's letters have Bidi_Class=R or AL.
|
897
|
+
*
|
898
|
+
* Returns TRUE for "ar" and "en-Hebr", FALSE for "zh" and "fa-Cyrl".
|
899
|
+
*
|
900
|
+
* @param locale input locale ID
|
901
|
+
* @return TRUE if the locale's script is written right-to-left
|
902
|
+
* @draft ICU 54
|
903
|
+
*/
|
904
|
+
U_DRAFT UBool U_EXPORT2
|
905
|
+
uloc_isRightToLeft(const char *locale);
|
906
|
+
#endif /* U_HIDE_DRAFT_API */
|
907
|
+
|
908
|
+
/**
|
909
|
+
* enums for the return value for the character and line orientation
|
910
|
+
* functions.
|
911
|
+
* @stable ICU 4.0
|
912
|
+
*/
|
913
|
+
typedef enum {
|
914
|
+
ULOC_LAYOUT_LTR = 0, /* left-to-right. */
|
915
|
+
ULOC_LAYOUT_RTL = 1, /* right-to-left. */
|
916
|
+
ULOC_LAYOUT_TTB = 2, /* top-to-bottom. */
|
917
|
+
ULOC_LAYOUT_BTT = 3, /* bottom-to-top. */
|
918
|
+
ULOC_LAYOUT_UNKNOWN
|
919
|
+
} ULayoutType;
|
920
|
+
|
921
|
+
/**
|
922
|
+
* Get the layout character orientation for the specified locale.
|
923
|
+
*
|
924
|
+
* @param localeId locale name
|
925
|
+
* @param status Error status
|
926
|
+
* @return an enum indicating the layout orientation for characters.
|
927
|
+
* @stable ICU 4.0
|
928
|
+
*/
|
929
|
+
U_STABLE ULayoutType U_EXPORT2
|
930
|
+
uloc_getCharacterOrientation(const char* localeId,
|
931
|
+
UErrorCode *status);
|
932
|
+
|
933
|
+
/**
|
934
|
+
* Get the layout line orientation for the specified locale.
|
935
|
+
*
|
936
|
+
* @param localeId locale name
|
937
|
+
* @param status Error status
|
938
|
+
* @return an enum indicating the layout orientation for lines.
|
939
|
+
* @stable ICU 4.0
|
940
|
+
*/
|
941
|
+
U_STABLE ULayoutType U_EXPORT2
|
942
|
+
uloc_getLineOrientation(const char* localeId,
|
943
|
+
UErrorCode *status);
|
944
|
+
|
945
|
+
/**
|
946
|
+
* enums for the 'outResult' parameter return value
|
947
|
+
* @see uloc_acceptLanguageFromHTTP
|
948
|
+
* @see uloc_acceptLanguage
|
949
|
+
* @stable ICU 3.2
|
950
|
+
*/
|
951
|
+
typedef enum {
|
952
|
+
ULOC_ACCEPT_FAILED = 0, /* No exact match was found. */
|
953
|
+
ULOC_ACCEPT_VALID = 1, /* An exact match was found. */
|
954
|
+
ULOC_ACCEPT_FALLBACK = 2 /* A fallback was found, for example,
|
955
|
+
Accept list contained 'ja_JP'
|
956
|
+
which matched available locale 'ja'. */
|
957
|
+
} UAcceptResult;
|
958
|
+
|
959
|
+
|
960
|
+
/**
|
961
|
+
* Based on a HTTP header from a web browser and a list of available locales,
|
962
|
+
* determine an acceptable locale for the user.
|
963
|
+
* @param result - buffer to accept the result locale
|
964
|
+
* @param resultAvailable the size of the result buffer.
|
965
|
+
* @param outResult - An out parameter that contains the fallback status
|
966
|
+
* @param httpAcceptLanguage - "Accept-Language:" header as per HTTP.
|
967
|
+
* @param availableLocales - list of available locales to match
|
968
|
+
* @param status Error status, may be BUFFER_OVERFLOW_ERROR
|
969
|
+
* @return length needed for the locale.
|
970
|
+
* @stable ICU 3.2
|
971
|
+
*/
|
972
|
+
U_STABLE int32_t U_EXPORT2
|
973
|
+
uloc_acceptLanguageFromHTTP(char *result, int32_t resultAvailable,
|
974
|
+
UAcceptResult *outResult,
|
975
|
+
const char *httpAcceptLanguage,
|
976
|
+
UEnumeration* availableLocales,
|
977
|
+
UErrorCode *status);
|
978
|
+
|
979
|
+
/**
|
980
|
+
* Based on a list of available locales,
|
981
|
+
* determine an acceptable locale for the user.
|
982
|
+
* @param result - buffer to accept the result locale
|
983
|
+
* @param resultAvailable the size of the result buffer.
|
984
|
+
* @param outResult - An out parameter that contains the fallback status
|
985
|
+
* @param acceptList - list of acceptable languages
|
986
|
+
* @param acceptListCount - count of acceptList items
|
987
|
+
* @param availableLocales - list of available locales to match
|
988
|
+
* @param status Error status, may be BUFFER_OVERFLOW_ERROR
|
989
|
+
* @return length needed for the locale.
|
990
|
+
* @stable ICU 3.2
|
991
|
+
*/
|
992
|
+
U_STABLE int32_t U_EXPORT2
|
993
|
+
uloc_acceptLanguage(char *result, int32_t resultAvailable,
|
994
|
+
UAcceptResult *outResult, const char **acceptList,
|
995
|
+
int32_t acceptListCount,
|
996
|
+
UEnumeration* availableLocales,
|
997
|
+
UErrorCode *status);
|
998
|
+
|
999
|
+
|
1000
|
+
/**
|
1001
|
+
* Gets the ICU locale ID for the specified Win32 LCID value.
|
1002
|
+
*
|
1003
|
+
* @param hostID the Win32 LCID to translate
|
1004
|
+
* @param locale the output buffer for the ICU locale ID, which will be NUL-terminated
|
1005
|
+
* if there is room.
|
1006
|
+
* @param localeCapacity the size of the output buffer
|
1007
|
+
* @param status an error is returned if the LCID is unrecognized or the output buffer
|
1008
|
+
* is too small
|
1009
|
+
* @return actual the actual size of the locale ID, not including NUL-termination
|
1010
|
+
* @stable ICU 3.8
|
1011
|
+
*/
|
1012
|
+
U_STABLE int32_t U_EXPORT2
|
1013
|
+
uloc_getLocaleForLCID(uint32_t hostID, char *locale, int32_t localeCapacity,
|
1014
|
+
UErrorCode *status);
|
1015
|
+
|
1016
|
+
|
1017
|
+
/**
|
1018
|
+
* Add the likely subtags for a provided locale ID, per the algorithm described
|
1019
|
+
* in the following CLDR technical report:
|
1020
|
+
*
|
1021
|
+
* http://www.unicode.org/reports/tr35/#Likely_Subtags
|
1022
|
+
*
|
1023
|
+
* If localeID is already in the maximal form, or there is no data available
|
1024
|
+
* for maximization, it will be copied to the output buffer. For example,
|
1025
|
+
* "und-Zzzz" cannot be maximized, since there is no reasonable maximization.
|
1026
|
+
*
|
1027
|
+
* Examples:
|
1028
|
+
*
|
1029
|
+
* "en" maximizes to "en_Latn_US"
|
1030
|
+
*
|
1031
|
+
* "de" maximizes to "de_Latn_US"
|
1032
|
+
*
|
1033
|
+
* "sr" maximizes to "sr_Cyrl_RS"
|
1034
|
+
*
|
1035
|
+
* "sh" maximizes to "sr_Latn_RS" (Note this will not reverse.)
|
1036
|
+
*
|
1037
|
+
* "zh_Hani" maximizes to "zh_Hans_CN" (Note this will not reverse.)
|
1038
|
+
*
|
1039
|
+
* @param localeID The locale to maximize
|
1040
|
+
* @param maximizedLocaleID The maximized locale
|
1041
|
+
* @param maximizedLocaleIDCapacity The capacity of the maximizedLocaleID buffer
|
1042
|
+
* @param err Error information if maximizing the locale failed. If the length
|
1043
|
+
* of the localeID and the null-terminator is greater than the maximum allowed size,
|
1044
|
+
* or the localeId is not well-formed, the error code is U_ILLEGAL_ARGUMENT_ERROR.
|
1045
|
+
* @return The actual buffer size needed for the maximized locale. If it's
|
1046
|
+
* greater than maximizedLocaleIDCapacity, the returned ID will be truncated.
|
1047
|
+
* On error, the return value is -1.
|
1048
|
+
* @stable ICU 4.0
|
1049
|
+
*/
|
1050
|
+
U_STABLE int32_t U_EXPORT2
|
1051
|
+
uloc_addLikelySubtags(const char* localeID,
|
1052
|
+
char* maximizedLocaleID,
|
1053
|
+
int32_t maximizedLocaleIDCapacity,
|
1054
|
+
UErrorCode* err);
|
1055
|
+
|
1056
|
+
|
1057
|
+
/**
|
1058
|
+
* Minimize the subtags for a provided locale ID, per the algorithm described
|
1059
|
+
* in the following CLDR technical report:
|
1060
|
+
*
|
1061
|
+
* http://www.unicode.org/reports/tr35/#Likely_Subtags
|
1062
|
+
*
|
1063
|
+
* If localeID is already in the minimal form, or there is no data available
|
1064
|
+
* for minimization, it will be copied to the output buffer. Since the
|
1065
|
+
* minimization algorithm relies on proper maximization, see the comments
|
1066
|
+
* for uloc_addLikelySubtags for reasons why there might not be any data.
|
1067
|
+
*
|
1068
|
+
* Examples:
|
1069
|
+
*
|
1070
|
+
* "en_Latn_US" minimizes to "en"
|
1071
|
+
*
|
1072
|
+
* "de_Latn_US" minimizes to "de"
|
1073
|
+
*
|
1074
|
+
* "sr_Cyrl_RS" minimizes to "sr"
|
1075
|
+
*
|
1076
|
+
* "zh_Hant_TW" minimizes to "zh_TW" (The region is preferred to the
|
1077
|
+
* script, and minimizing to "zh" would imply "zh_Hans_CN".)
|
1078
|
+
*
|
1079
|
+
* @param localeID The locale to minimize
|
1080
|
+
* @param minimizedLocaleID The minimized locale
|
1081
|
+
* @param minimizedLocaleIDCapacity The capacity of the minimizedLocaleID buffer
|
1082
|
+
* @param err Error information if minimizing the locale failed. If the length
|
1083
|
+
* of the localeID and the null-terminator is greater than the maximum allowed size,
|
1084
|
+
* or the localeId is not well-formed, the error code is U_ILLEGAL_ARGUMENT_ERROR.
|
1085
|
+
* @return The actual buffer size needed for the minimized locale. If it's
|
1086
|
+
* greater than minimizedLocaleIDCapacity, the returned ID will be truncated.
|
1087
|
+
* On error, the return value is -1.
|
1088
|
+
* @stable ICU 4.0
|
1089
|
+
*/
|
1090
|
+
U_STABLE int32_t U_EXPORT2
|
1091
|
+
uloc_minimizeSubtags(const char* localeID,
|
1092
|
+
char* minimizedLocaleID,
|
1093
|
+
int32_t minimizedLocaleIDCapacity,
|
1094
|
+
UErrorCode* err);
|
1095
|
+
|
1096
|
+
/**
|
1097
|
+
* Returns a locale ID for the specified BCP47 language tag string.
|
1098
|
+
* If the specified language tag contains any ill-formed subtags,
|
1099
|
+
* the first such subtag and all following subtags are ignored.
|
1100
|
+
* <p>
|
1101
|
+
* This implements the 'Language-Tag' production of BCP47, and so
|
1102
|
+
* supports grandfathered (regular and irregular) as well as private
|
1103
|
+
* use language tags. Private use tags are represented as 'x-whatever',
|
1104
|
+
* and grandfathered tags are converted to their canonical replacements
|
1105
|
+
* where they exist. Note that a few grandfathered tags have no modern
|
1106
|
+
* replacement, these will be converted using the fallback described in
|
1107
|
+
* the first paragraph, so some information might be lost.
|
1108
|
+
* @param langtag the input BCP47 language tag.
|
1109
|
+
* @param localeID the output buffer receiving a locale ID for the
|
1110
|
+
* specified BCP47 language tag.
|
1111
|
+
* @param localeIDCapacity the size of the locale ID output buffer.
|
1112
|
+
* @param parsedLength if not NULL, successfully parsed length
|
1113
|
+
* for the input language tag is set.
|
1114
|
+
* @param err error information if receiving the locald ID
|
1115
|
+
* failed.
|
1116
|
+
* @return the length of the locale ID.
|
1117
|
+
* @stable ICU 4.2
|
1118
|
+
*/
|
1119
|
+
U_STABLE int32_t U_EXPORT2
|
1120
|
+
uloc_forLanguageTag(const char* langtag,
|
1121
|
+
char* localeID,
|
1122
|
+
int32_t localeIDCapacity,
|
1123
|
+
int32_t* parsedLength,
|
1124
|
+
UErrorCode* err);
|
1125
|
+
|
1126
|
+
/**
|
1127
|
+
* Returns a well-formed language tag for this locale ID.
|
1128
|
+
* <p>
|
1129
|
+
* <b>Note</b>: When <code>strict</code> is FALSE, any locale
|
1130
|
+
* fields which do not satisfy the BCP47 syntax requirement will
|
1131
|
+
* be omitted from the result. When <code>strict</code> is
|
1132
|
+
* TRUE, this function sets U_ILLEGAL_ARGUMENT_ERROR to the
|
1133
|
+
* <code>err</code> if any locale fields do not satisfy the
|
1134
|
+
* BCP47 syntax requirement.
|
1135
|
+
* @param localeID the input locale ID
|
1136
|
+
* @param langtag the output buffer receiving BCP47 language
|
1137
|
+
* tag for the locale ID.
|
1138
|
+
* @param langtagCapacity the size of the BCP47 language tag
|
1139
|
+
* output buffer.
|
1140
|
+
* @param strict boolean value indicating if the function returns
|
1141
|
+
* an error for an ill-formed input locale ID.
|
1142
|
+
* @param err error information if receiving the language
|
1143
|
+
* tag failed.
|
1144
|
+
* @return The length of the BCP47 language tag.
|
1145
|
+
* @stable ICU 4.2
|
1146
|
+
*/
|
1147
|
+
U_STABLE int32_t U_EXPORT2
|
1148
|
+
uloc_toLanguageTag(const char* localeID,
|
1149
|
+
char* langtag,
|
1150
|
+
int32_t langtagCapacity,
|
1151
|
+
UBool strict,
|
1152
|
+
UErrorCode* err);
|
1153
|
+
|
1154
|
+
#ifndef U_HIDE_DRAFT_API
|
1155
|
+
/**
|
1156
|
+
* Converts the specified keyword (legacy key, or BCP 47 Unicode locale
|
1157
|
+
* extension key) to the equivalent BCP 47 Unicode locale extension key.
|
1158
|
+
* For example, BCP 47 Unicode locale extension key "co" is returned for
|
1159
|
+
* the input keyword "collation".
|
1160
|
+
* <p>
|
1161
|
+
* When the specified keyword is unknown, but satisfies the BCP syntax,
|
1162
|
+
* then the pointer to the input keyword itself will be returned.
|
1163
|
+
* For example,
|
1164
|
+
* <code>uloc_toUnicodeLocaleKey("ZZ")</code> returns "ZZ".
|
1165
|
+
*
|
1166
|
+
* @param keyword the input locale keyword (either legacy key
|
1167
|
+
* such as "collation" or BCP 47 Unicode locale extension
|
1168
|
+
* key such as "co").
|
1169
|
+
* @return the well-formed BCP 47 Unicode locale extension key,
|
1170
|
+
* or NULL if the specified locale keyword cannot be
|
1171
|
+
* mapped to a well-formed BCP 47 Unicode locale extension
|
1172
|
+
* key.
|
1173
|
+
* @see uloc_toLegacyKey
|
1174
|
+
* @draft ICU 54
|
1175
|
+
*/
|
1176
|
+
U_DRAFT const char* U_EXPORT2
|
1177
|
+
uloc_toUnicodeLocaleKey(const char* keyword);
|
1178
|
+
|
1179
|
+
/**
|
1180
|
+
* Converts the specified keyword value (legacy type, or BCP 47
|
1181
|
+
* Unicode locale extension type) to the well-formed BCP 47 Unicode locale
|
1182
|
+
* extension type for the specified keyword (category). For example, BCP 47
|
1183
|
+
* Unicode locale extension type "phonebk" is returned for the input
|
1184
|
+
* keyword value "phonebook", with the keyword "collation" (or "co").
|
1185
|
+
* <p>
|
1186
|
+
* When the specified keyword is not recognized, but the specified value
|
1187
|
+
* satisfies the syntax of the BCP 47 Unicode locale extension type,
|
1188
|
+
* or when the specified keyword allows 'variable' type and the specified
|
1189
|
+
* value satisfies the syntax, then the pointer to the input type value itself
|
1190
|
+
* will be returned.
|
1191
|
+
* For example,
|
1192
|
+
* <code>uloc_toUnicodeLocaleType("Foo", "Bar")</code> returns "Bar",
|
1193
|
+
* <code>uloc_toUnicodeLocaleType("variableTop", "00A4")</code> returns "00A4".
|
1194
|
+
*
|
1195
|
+
* @param keyword the locale keyword (either legacy key such as
|
1196
|
+
* "collation" or BCP 47 Unicode locale extension
|
1197
|
+
* key such as "co").
|
1198
|
+
* @param value the locale keyword value (either legacy type
|
1199
|
+
* such as "phonebook" or BCP 47 Unicode locale extension
|
1200
|
+
* type such as "phonebk").
|
1201
|
+
* @return the well-formed BCP47 Unicode locale extension type,
|
1202
|
+
* or NULL if the locale keyword value cannot be mapped to
|
1203
|
+
* a well-formed BCP 47 Unicode locale extension type.
|
1204
|
+
* @see uloc_toLegacyType
|
1205
|
+
* @draft ICU 54
|
1206
|
+
*/
|
1207
|
+
U_DRAFT const char* U_EXPORT2
|
1208
|
+
uloc_toUnicodeLocaleType(const char* keyword, const char* value);
|
1209
|
+
|
1210
|
+
/**
|
1211
|
+
* Converts the specified keyword (BCP 47 Unicode locale extension key, or
|
1212
|
+
* legacy key) to the legacy key. For example, legacy key "collation" is
|
1213
|
+
* returned for the input BCP 47 Unicode locale extension key "co".
|
1214
|
+
*
|
1215
|
+
* @param keyword the input locale keyword (either BCP 47 Unicode locale
|
1216
|
+
* extension key or legacy key).
|
1217
|
+
* @return the well-formed legacy key, or NULL if the specified
|
1218
|
+
* keyword cannot be mapped to a well-formed legacy key.
|
1219
|
+
* @see toUnicodeLocaleKey
|
1220
|
+
* @draft ICU 54
|
1221
|
+
*/
|
1222
|
+
U_DRAFT const char* U_EXPORT2
|
1223
|
+
uloc_toLegacyKey(const char* keyword);
|
1224
|
+
|
1225
|
+
/**
|
1226
|
+
* Converts the specified keyword value (BCP 47 Unicode locale extension type,
|
1227
|
+
* or legacy type or type alias) to the canonical legacy type. For example,
|
1228
|
+
* the legacy type "phonebook" is returned for the input BCP 47 Unicode
|
1229
|
+
* locale extension type "phonebk" with the keyword "collation" (or "co").
|
1230
|
+
* <p>
|
1231
|
+
* When the specified keyword is not recognized, but the specified value
|
1232
|
+
* satisfies the syntax of legacy key, or when the specified keyword
|
1233
|
+
* allows 'variable' type and the specified value satisfies the syntax,
|
1234
|
+
* then the pointer to the input type value itself will be returned.
|
1235
|
+
* For example,
|
1236
|
+
* <code>uloc_toLegacyType("Foo", "Bar")</code> returns "Bar",
|
1237
|
+
* <code>uloc_toLegacyType("vt", "00A4")</code> returns "00A4".
|
1238
|
+
*
|
1239
|
+
* @param keyword the locale keyword (either legacy keyword such as
|
1240
|
+
* "collation" or BCP 47 Unicode locale extension
|
1241
|
+
* key such as "co").
|
1242
|
+
* @param value the locale keyword value (either BCP 47 Unicode locale
|
1243
|
+
* extension type such as "phonebk" or legacy keyword value
|
1244
|
+
* such as "phonebook").
|
1245
|
+
* @return the well-formed legacy type, or NULL if the specified
|
1246
|
+
* keyword value cannot be mapped to a well-formed legacy
|
1247
|
+
* type.
|
1248
|
+
* @see toUnicodeLocaleType
|
1249
|
+
* @draft ICU 54
|
1250
|
+
*/
|
1251
|
+
U_DRAFT const char* U_EXPORT2
|
1252
|
+
uloc_toLegacyType(const char* keyword, const char* value);
|
1253
|
+
|
1254
|
+
#endif /* U_HIDE_DRAFT_API */
|
1255
|
+
|
1256
|
+
#endif /*_ULOC*/
|