Home | History | Annotate | Download | only in cintltst

Lines Matching full:scripts

14 static void scriptsToString(const UScriptCode scripts[], int32_t length, char s[]) {
17 strcpy(s, "(no scripts)");
25 strcat(s, uscript_getShortName(scripts[i]));
155 UScriptCode scripts[5];
161 num = uscript_getCode("tg", scripts, UPRV_LENGTHOF(scripts), &err);
162 assertEqualScripts("tg script: Cyrl", CYRILLIC, 1, scripts, num, err); // Tajik
164 num = uscript_getCode("xsr", scripts, UPRV_LENGTHOF(scripts), &err);
165 assertEqualScripts("xsr script: Deva", DEVANAGARI, 1, scripts, num, err); // Sherpa
169 num = uscript_getCode("ja", scripts, UPRV_LENGTHOF(scripts), &err);
170 assertEqualScripts("ja scripts: Kana Hira Hani",
171 JAPANESE, UPRV_LENGTHOF(JAPANESE), scripts, num, err);
173 num = uscript_getCode("ko", scripts, UPRV_LENGTHOF(scripts), &err);
174 assertEqualScripts("ko scripts: Hang Hani",
175 KOREAN, UPRV_LENGTHOF(KOREAN), scripts, num, err);
177 num = uscript_getCode("zh", scripts, UPRV_LENGTHOF(scripts), &err);
178 assertEqualScripts("zh script: Hani", HAN, 1, scripts, num, err);
180 num = uscript_getCode("zh-Hant", scripts, UPRV_LENGTHOF(scripts), &err);
181 assertEqualScripts("zh-Hant scripts: Hani Bopo", HAN_BOPO, 2, scripts, num, err);
183 num = uscript_getCode("zh-TW", scripts, UPRV_LENGTHOF(scripts), &err);
184 assertEqualScripts("zh-TW scripts: Hani Bopo", HAN_BOPO, 2, scripts, num, err);
188 num = uscript_getCode("ro-RO", scripts, UPRV_LENGTHOF(scripts), &err);
189 assertEqualScripts("ro-RO script: Latn", LATIN, 1, scripts, num, err);
378 * Unicode 5 and later encode some of these scripts and give them long names.
531 static UBool scriptsContain(int32_t scripts[], int32_t length, int32_t script) {
535 int32_t s=scripts[i];
545 UScriptCode scripts[20];
551 length=uscript_getScriptExtensions(0x0640, scripts, UPRV_LENGTHOF(scripts), &errorCode);
557 length=uscript_getScriptExtensions(0x0640, NULL, UPRV_LENGTHOF(scripts), &errorCode);
563 length=uscript_getScriptExtensions(0x0640, scripts, -1, &errorCode);
569 length=uscript_getScriptExtensions(0x0640, scripts, 0, &errorCode);
575 length=uscript_getScriptExtensions(0x0640, scripts, 1, &errorCode);
582 length=uscript_getScriptExtensions(0x063f, scripts, 0, &errorCode);
590 length=uscript_getScriptExtensions(-1, scripts, UPRV_LENGTHOF(scripts), &errorCode);
591 if(U_FAILURE(errorCode) || length!=1 || scripts[0]!=USCRIPT_UNKNOWN) {
596 length=uscript_getScriptExtensions(0x110000, scripts, UPRV_LENGTHOF(scripts), &errorCode);
597 if(U_FAILURE(errorCode) || length!=1 || scripts[0]!=USCRIPT_UNKNOWN) {
604 length=uscript_getScriptExtensions(0x063f, scripts, 1, &errorCode);
605 if(U_FAILURE(errorCode) || length!=1 || scripts[0]!=USCRIPT_ARABIC) {
610 length=uscript_getScriptExtensions(0x0640, scripts, UPRV_LENGTHOF(scripts), &errorCode);
612 !scriptsContain(scripts, length, USCRIPT_ARABIC) ||
613 !scriptsContain(scripts, length, USCRIPT_SYRIAC) ||
614 !scriptsContain(scripts, length, USCRIPT_MANDAIC)) {
619 length=uscript_getScriptExtensions(0xfdf2, scripts, UPRV_LENGTHOF(scripts), &errorCode);
620 if(U_FAILURE(errorCode) || length!=2 || scripts[0]!=USCRIPT_ARABIC || scripts[1]!=USCRIPT_THAANA) {
625 length=uscript_getScriptExtensions(0xff65, scripts, UPRV_LENGTHOF(scripts), &errorCode);
626 if(U_FAILURE(errorCode) || length!=6 || scripts[0]!=USCRIPT_BOPOMOFO || scripts[5]!=USCRIPT_YI) {