/third_party/icu/icu4j/main/tests/core/src/com/ibm/icu/dev/test/bidi/ |
D | TestCompatibility.java | 10 package com.ibm.icu.dev.test.bidi; 28 void compareBidi(Bidi bidi, java.text.Bidi jbidi) in compareBidi() argument 30 byte paraLevel = bidi.getParaLevel(); in compareBidi() 31 if (bidi.baseIsLeftToRight() != jbidi.baseIsLeftToRight()) { in compareBidi() 34 u16ToPseudo(bidi.getTextAsString()) + in compareBidi() 35 "\n bidi: " + bidi.baseIsLeftToRight() + in compareBidi() 38 if (bidi.getBaseLevel() != jbidi.getBaseLevel()) { in compareBidi() 41 u16ToPseudo(bidi.getTextAsString()) + in compareBidi() 42 "\n bidi: " + bidi.getBaseLevel() + in compareBidi() 45 if (bidi.getLength() != jbidi.getLength()) { in compareBidi() [all …]
|
D | TestBidi.java | 10 package com.ibm.icu.dev.test.bidi; 32 Bidi bidi; in testBidi() local 36 bidi = new Bidi(MAXLEN, 0); in testBidi() 39 doTests(bidi, bidiLine, false); in testBidi() 40 doTests(bidi, bidiLine, true); in testBidi() 45 private void doTests(Bidi bidi, Bidi bidiLine, boolean countRunsFirst) { in doTests() argument 57 bidi.setPara(string, paraLevel, null); in doTests() 59 + bidi.getDirection() + " paraLevel " in doTests() 63 + bidi.getDirection() + " paraLevel " in doTests() 68 doTest(bidi, testNumber, test, 0, countRunsFirst); in doTests() [all …]
|
D | TestReorderingMode.java | 10 package com.ibm.icu.dev.test.bidi; 206 Bidi bidi = new Bidi(); in testReorderingMode() local 225 bidi.setReorderingMode(modeValue); in testReorderingMode() 226 modeBack = bidi.getReorderingMode(); in testReorderingMode() 234 bidi.setReorderingOptions(optionValue); in testReorderingMode() 235 optionBack = bidi.getReorderingOptions(); in testReorderingMode() 244 bidi.setPara(pseudoToU16(src), paraLevels[level], null); in testReorderingMode() 246 dest = bidi.writeReordered(Bidi.DO_MIRRORING); in testReorderingMode() 250 checkWhatYouCan(bidi, src, dest); in testReorderingMode() 277 if (!checkResultLength(bidi, src, dest, modeDesc, optDesc, in testReorderingMode() [all …]
|
D | TestInverse.java | 10 package com.ibm.icu.dev.test.bidi; 40 Bidi bidi; in testInverse() local 44 bidi = new Bidi(); in testInverse() 49 _testInverseBidi(bidi, testCases[i], Bidi.DIRECTION_LEFT_TO_RIGHT); in testInverse() 56 _testInverseBidi(bidi, testCases[i], Bidi.DIRECTION_RIGHT_TO_LEFT); in testInverse() 59 _testManyInverseBidi(bidi, Bidi.DIRECTION_LEFT_TO_RIGHT); in testInverse() 60 _testManyInverseBidi(bidi, Bidi.DIRECTION_RIGHT_TO_LEFT); in testInverse() 84 private void _testManyInverseBidi(Bidi bidi, int direction) { in _testManyInverseBidi() argument 103 _testInverseBidi(bidi, new String(text), direction); in _testManyInverseBidi() 109 private void _testInverseBidi(Bidi bidi, String src, int direction) { in _testInverseBidi() argument [all …]
|
D | TestMultipleParagraphs.java | 10 package com.ibm.icu.dev.test.bidi; 87 Bidi bidi = new Bidi(); in testMultipleParagraphs() local 94 bidi.setPara(text, Bidi.LTR, null); in testMultipleParagraphs() 100 if (paraCount != (count = bidi.countParagraphs())) { in testMultipleParagraphs() 106 run = bidi.getParagraphByIndex(i); in testMultipleParagraphs() 122 bidi.setPara(src, Bidi.LTR, null); in testMultipleParagraphs() 126 if (paraCount != (count = bidi.countParagraphs())) { in testMultipleParagraphs() 131 run = bidi.getParagraphByIndex(i); in testMultipleParagraphs() 144 bidi.setPara(src, paraLevels[k], null); in testMultipleParagraphs() 149 paraIndex = bidi.getParagraphIndex(paraBounds[i]); in testMultipleParagraphs() [all …]
|
D | TestFailureRecovery.java | 10 package com.ibm.icu.dev.test.bidi; 28 Bidi bidi = new Bidi(); in testFailureRecovery() local 39 bidi.setPara("abc", (byte)(-1), null); in testFailureRecovery() 52 bidi = new Bidi(); in testFailureRecovery() 54 bidi.setLine(0, 1); in testFailureRecovery() 61 bidi.getDirection(); in testFailureRecovery() 67 bidi.setPara("abc", Bidi.LTR, null); in testFailureRecovery() 69 bidi.getLevelAt(3); in testFailureRecovery() 76 bidi = new Bidi(-1, 0); in testFailureRecovery() 82 bidi = new Bidi(2, 1); in testFailureRecovery() [all …]
|
D | TestReorderRunsOnly.java | 10 package com.ibm.icu.dev.test.bidi; 117 Bidi bidi = new Bidi(); in testReorderRunsOnly() local 125 bidi.setReorderingMode(Bidi.REORDER_RUNS_ONLY); in testReorderRunsOnly() 129 bidi.setReorderingOptions(option == 0 ? Bidi.OPTION_REMOVE_CONTROLS in testReorderRunsOnly() 138 bidi.setPara(srcU16, level, null); in testReorderRunsOnly() 139 destU16 = bidi.writeReordered(Bidi.DO_MIRRORING); in testReorderRunsOnly() 141 checkWhatYouCan(bidi, src, dest); in testReorderRunsOnly() 168 bidi.setPara((String)null, Bidi.LTR, null); in testReorderRunsOnly() 169 paras = bidi.countParagraphs(); in testReorderRunsOnly() 171 bidi.setPara((char[])null, Bidi.LTR, null); in testReorderRunsOnly() [all …]
|
D | BidiFmwk.java | 10 package com.ibm.icu.dev.test.bidi; 335 void printCaseInfo(Bidi bidi, String src, String dst) 337 int length = bidi.getProcessedLength(); 338 byte[] levels = bidi.getLevels(); 341 int runCount = bidi.countRuns(); 357 errcontln("Direction: " + bidi.getDirection()); 358 errcontln("paraLevel: " + Byte.toString(bidi.getParaLevel())); 359 errcontln("reorderingMode: " + modeToString(bidi.getReorderingMode())); 360 errcontln("reorderingOptions: " + spOptionsToString(bidi.getReorderingOptions())); 364 run = bidi.getVisualRun(i); [all …]
|
D | TestReorder.java | 10 package com.ibm.icu.dev.test.bidi; 117 Bidi bidi = new Bidi(); in testReorder() local 129 bidi.setPara(srcU16, Bidi.LEVEL_DEFAULT_LTR, null); in testReorder() 135 dest = u16ToPseudo(bidi.writeReordered(Bidi.DO_MIRRORING)); in testReorder() 145 checkWhatYouCan(bidi, src, dest); in testReorder() 153 bidi.setPara(srcU16, Bidi.LEVEL_DEFAULT_LTR, null); in testReorder() 159 dest = u16ToPseudo(bidi.writeReordered(Bidi.DO_MIRRORING + in testReorder() 176 bidi.setInverse(true); in testReorder() 178 bidi.setPara(srcU16, Bidi.LEVEL_DEFAULT_LTR, null); in testReorder() 184 dest = u16ToPseudo(bidi.writeReordered(Bidi.OUTPUT_REVERSE | in testReorder() [all …]
|
/third_party/icu/ohos_icu4j/src/main/tests/ohos/global/icu/dev/test/bidi/ |
D | TestCompatibility.java | 11 package ohos.global.icu.dev.test.bidi; 31 void compareBidi(Bidi bidi, java.text.Bidi jbidi) in compareBidi() argument 33 byte paraLevel = bidi.getParaLevel(); in compareBidi() 34 if (bidi.baseIsLeftToRight() != jbidi.baseIsLeftToRight()) { in compareBidi() 37 u16ToPseudo(bidi.getTextAsString()) + in compareBidi() 38 "\n bidi: " + bidi.baseIsLeftToRight() + in compareBidi() 41 if (bidi.getBaseLevel() != jbidi.getBaseLevel()) { in compareBidi() 44 u16ToPseudo(bidi.getTextAsString()) + in compareBidi() 45 "\n bidi: " + bidi.getBaseLevel() + in compareBidi() 48 if (bidi.getLength() != jbidi.getLength()) { in compareBidi() [all …]
|
D | TestBidi.java | 11 package ohos.global.icu.dev.test.bidi; 35 Bidi bidi; in testBidi() local 39 bidi = new Bidi(MAXLEN, 0); in testBidi() 42 doTests(bidi, bidiLine, false); in testBidi() 43 doTests(bidi, bidiLine, true); in testBidi() 48 private void doTests(Bidi bidi, Bidi bidiLine, boolean countRunsFirst) { in doTests() argument 60 bidi.setPara(string, paraLevel, null); in doTests() 62 + bidi.getDirection() + " paraLevel " in doTests() 66 + bidi.getDirection() + " paraLevel " in doTests() 71 doTest(bidi, testNumber, test, 0, countRunsFirst); in doTests() [all …]
|
D | TestReorderingMode.java | 11 package ohos.global.icu.dev.test.bidi; 209 Bidi bidi = new Bidi(); in testReorderingMode() local 228 bidi.setReorderingMode(modeValue); in testReorderingMode() 229 modeBack = bidi.getReorderingMode(); in testReorderingMode() 237 bidi.setReorderingOptions(optionValue); in testReorderingMode() 238 optionBack = bidi.getReorderingOptions(); in testReorderingMode() 247 bidi.setPara(pseudoToU16(src), paraLevels[level], null); in testReorderingMode() 249 dest = bidi.writeReordered(Bidi.DO_MIRRORING); in testReorderingMode() 253 checkWhatYouCan(bidi, src, dest); in testReorderingMode() 280 if (!checkResultLength(bidi, src, dest, modeDesc, optDesc, in testReorderingMode() [all …]
|
D | TestInverse.java | 11 package ohos.global.icu.dev.test.bidi; 43 Bidi bidi; in testInverse() local 47 bidi = new Bidi(); in testInverse() 52 _testInverseBidi(bidi, testCases[i], Bidi.DIRECTION_LEFT_TO_RIGHT); in testInverse() 59 _testInverseBidi(bidi, testCases[i], Bidi.DIRECTION_RIGHT_TO_LEFT); in testInverse() 62 _testManyInverseBidi(bidi, Bidi.DIRECTION_LEFT_TO_RIGHT); in testInverse() 63 _testManyInverseBidi(bidi, Bidi.DIRECTION_RIGHT_TO_LEFT); in testInverse() 87 private void _testManyInverseBidi(Bidi bidi, int direction) { in _testManyInverseBidi() argument 106 _testInverseBidi(bidi, new String(text), direction); in _testManyInverseBidi() 112 private void _testInverseBidi(Bidi bidi, String src, int direction) { in _testInverseBidi() argument [all …]
|
D | TestMultipleParagraphs.java | 11 package ohos.global.icu.dev.test.bidi; 90 Bidi bidi = new Bidi(); in testMultipleParagraphs() local 97 bidi.setPara(text, Bidi.LTR, null); in testMultipleParagraphs() 103 if (paraCount != (count = bidi.countParagraphs())) { in testMultipleParagraphs() 109 run = bidi.getParagraphByIndex(i); in testMultipleParagraphs() 125 bidi.setPara(src, Bidi.LTR, null); in testMultipleParagraphs() 129 if (paraCount != (count = bidi.countParagraphs())) { in testMultipleParagraphs() 134 run = bidi.getParagraphByIndex(i); in testMultipleParagraphs() 147 bidi.setPara(src, paraLevels[k], null); in testMultipleParagraphs() 152 paraIndex = bidi.getParagraphIndex(paraBounds[i]); in testMultipleParagraphs() [all …]
|
D | TestFailureRecovery.java | 11 package ohos.global.icu.dev.test.bidi; 31 Bidi bidi = new Bidi(); in testFailureRecovery() local 42 bidi.setPara("abc", (byte)(-1), null); in testFailureRecovery() 55 bidi = new Bidi(); in testFailureRecovery() 57 bidi.setLine(0, 1); in testFailureRecovery() 64 bidi.getDirection(); in testFailureRecovery() 70 bidi.setPara("abc", Bidi.LTR, null); in testFailureRecovery() 72 bidi.getLevelAt(3); in testFailureRecovery() 79 bidi = new Bidi(-1, 0); in testFailureRecovery() 85 bidi = new Bidi(2, 1); in testFailureRecovery() [all …]
|
D | TestReorderRunsOnly.java | 11 package ohos.global.icu.dev.test.bidi; 120 Bidi bidi = new Bidi(); in testReorderRunsOnly() local 128 bidi.setReorderingMode(Bidi.REORDER_RUNS_ONLY); in testReorderRunsOnly() 132 bidi.setReorderingOptions(option == 0 ? Bidi.OPTION_REMOVE_CONTROLS in testReorderRunsOnly() 141 bidi.setPara(srcU16, level, null); in testReorderRunsOnly() 142 destU16 = bidi.writeReordered(Bidi.DO_MIRRORING); in testReorderRunsOnly() 144 checkWhatYouCan(bidi, src, dest); in testReorderRunsOnly() 171 bidi.setPara((String)null, Bidi.LTR, null); in testReorderRunsOnly() 172 paras = bidi.countParagraphs(); in testReorderRunsOnly() 174 bidi.setPara((char[])null, Bidi.LTR, null); in testReorderRunsOnly() [all …]
|
D | BidiFmwk.java | 11 package ohos.global.icu.dev.test.bidi; 336 void printCaseInfo(Bidi bidi, String src, String dst) 338 int length = bidi.getProcessedLength(); 339 byte[] levels = bidi.getLevels(); 342 int runCount = bidi.countRuns(); 358 errcontln("Direction: " + bidi.getDirection()); 359 errcontln("paraLevel: " + Byte.toString(bidi.getParaLevel())); 360 errcontln("reorderingMode: " + modeToString(bidi.getReorderingMode())); 361 errcontln("reorderingOptions: " + spOptionsToString(bidi.getReorderingOptions())); 365 run = bidi.getVisualRun(i); [all …]
|
D | TestReorder.java | 11 package ohos.global.icu.dev.test.bidi; 120 Bidi bidi = new Bidi(); in testReorder() local 132 bidi.setPara(srcU16, Bidi.LEVEL_DEFAULT_LTR, null); in testReorder() 138 dest = u16ToPseudo(bidi.writeReordered(Bidi.DO_MIRRORING)); in testReorder() 148 checkWhatYouCan(bidi, src, dest); in testReorder() 156 bidi.setPara(srcU16, Bidi.LEVEL_DEFAULT_LTR, null); in testReorder() 162 dest = u16ToPseudo(bidi.writeReordered(Bidi.DO_MIRRORING + in testReorder() 179 bidi.setInverse(true); in testReorder() 181 bidi.setPara(srcU16, Bidi.LEVEL_DEFAULT_LTR, null); in testReorder() 187 dest = u16ToPseudo(bidi.writeReordered(Bidi.OUTPUT_REVERSE | in testReorder() [all …]
|
/third_party/icu/icu4j/main/classes/core/src/com/ibm/icu/text/ |
D | BidiLine.java | 85 static void setTrailingWSStart(Bidi bidi) in setTrailingWSStart() argument 87 byte[] dirProps = bidi.dirProps; in setTrailingWSStart() 88 byte[] levels = bidi.levels; in setTrailingWSStart() 89 int start = bidi.length; in setTrailingWSStart() 90 byte paraLevel = bidi.paraLevel; in setTrailingWSStart() 99 bidi.trailingWSStart = start; /* currently == bidi.length */ in setTrailingWSStart() 113 bidi.trailingWSStart=start; in setTrailingWSStart() 239 static byte getLevelAt(Bidi bidi, int charIndex) in getLevelAt() argument 242 if (bidi.direction != Bidi.MIXED || charIndex >= bidi.trailingWSStart) { in getLevelAt() 243 return bidi.GetParaLevelAt(charIndex); in getLevelAt() [all …]
|
D | BidiWriter.java | 238 static String writeReordered(Bidi bidi, int options) in writeReordered() argument 242 char[] text = bidi.text; in writeReordered() 243 runCount = bidi.countRuns(); in writeReordered() 249 if ((bidi.reorderingOptions & Bidi.OPTION_INSERT_MARKS) != 0) { in writeReordered() 257 if ((bidi.reorderingOptions & Bidi.OPTION_REMOVE_CONTROLS) != 0) { in writeReordered() 265 if ((bidi.reorderingMode != Bidi.REORDER_INVERSE_NUMBERS_AS_L) && in writeReordered() 266 (bidi.reorderingMode != Bidi.REORDER_INVERSE_LIKE_DIRECT) && in writeReordered() 267 (bidi.reorderingMode != Bidi.REORDER_INVERSE_FOR_NUMBERS_SPECIAL) && in writeReordered() 268 (bidi.reorderingMode != Bidi.REORDER_RUNS_ONLY)) { in writeReordered() 272 bidi.length * 2 : bidi.length); in writeReordered() [all …]
|
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/text/ |
D | BidiLine.java | 86 static void setTrailingWSStart(Bidi bidi) in setTrailingWSStart() argument 88 byte[] dirProps = bidi.dirProps; in setTrailingWSStart() 89 byte[] levels = bidi.levels; in setTrailingWSStart() 90 int start = bidi.length; in setTrailingWSStart() 91 byte paraLevel = bidi.paraLevel; in setTrailingWSStart() 100 bidi.trailingWSStart = start; /* currently == bidi.length */ in setTrailingWSStart() 114 bidi.trailingWSStart=start; in setTrailingWSStart() 240 static byte getLevelAt(Bidi bidi, int charIndex) in getLevelAt() argument 243 if (bidi.direction != Bidi.MIXED || charIndex >= bidi.trailingWSStart) { in getLevelAt() 244 return bidi.GetParaLevelAt(charIndex); in getLevelAt() [all …]
|
D | BidiWriter.java | 239 static String writeReordered(Bidi bidi, int options) in writeReordered() argument 243 char[] text = bidi.text; in writeReordered() 244 runCount = bidi.countRuns(); in writeReordered() 250 if ((bidi.reorderingOptions & Bidi.OPTION_INSERT_MARKS) != 0) { in writeReordered() 258 if ((bidi.reorderingOptions & Bidi.OPTION_REMOVE_CONTROLS) != 0) { in writeReordered() 266 if ((bidi.reorderingMode != Bidi.REORDER_INVERSE_NUMBERS_AS_L) && in writeReordered() 267 (bidi.reorderingMode != Bidi.REORDER_INVERSE_LIKE_DIRECT) && in writeReordered() 268 (bidi.reorderingMode != Bidi.REORDER_INVERSE_FOR_NUMBERS_SPECIAL) && in writeReordered() 269 (bidi.reorderingMode != Bidi.REORDER_RUNS_ONLY)) { in writeReordered() 273 bidi.length * 2 : bidi.length); in writeReordered() [all …]
|
/third_party/pcre2/pcre2/maint/ucptestdata/ |
D | testinput2 | 7 find bidi PDF 8 find bidi CS 9 find bidi CS type Sm 10 find bidi B 11 find bidi FSI 12 find bidi PDI 13 find bidi RLI 14 find bidi RLO 15 find bidi S 16 find bidi WS
|
/third_party/skia/modules/skunicode/src/ |
D | SkUnicode_icu_bidi.cpp | 25 SkBidiIterator_icu(SkUnicodeBidi bidi) : fBidi(std::move(bidi)) {} in SkBidiIterator_icu() argument 40 SkUnicodeBidi bidi(SkUnicode_IcuBidi::bidi_openSized(utf16Units, 0, &status)); in makeBidiIterator() local 45 SkASSERT(bidi); in makeBidiIterator() 49 …SkUnicode_IcuBidi::bidi_setPara(bidi.get(), (const UChar*)utf16, utf16Units, bidiLevel, nullptr, &… in makeBidiIterator() 54 return std::unique_ptr<SkBidiIterator>(new SkBidiIterator_icu(std::move(bidi))); in makeBidiIterator() 94 SkUnicodeBidi bidi(SkUnicode_IcuBidi::bidi_openSized(utf16.size(), 0, &status)); in extractBidi() local 99 SkASSERT(bidi); in extractBidi() 103 …SkUnicode_IcuBidi::bidi_setPara(bidi.get(), (const UChar*)utf16.c_str(), utf16.size(), bidiLevel, … in extractBidi() 117 Position end16 = SkUnicode_IcuBidi::bidi_getLength(bidi.get()); in extractBidi() 122 if (SkUnicode_IcuBidi::bidi_getDirection(bidi.get()) != UBIDI_MIXED) { in extractBidi() [all …]
|
/third_party/icu/icu4c/source/test/cintltst/ |
D | cbiditst.c | 401 static char * formatLevels(UBiDi *bidi, char *buffer) { in formatLevels() argument 403 const UBiDiLevel* gotLevels = ubidi_getLevels(bidi, &ec); in formatLevels() 404 int32_t len = ubidi_getLength(bidi); in formatLevels() 446 static void printCaseInfo(UBiDi *bidi, const char *src, const char *dst) in printCaseInfo() argument 454 int32_t i, length = ubidi_getProcessedLength(bidi); in printCaseInfo() 461 levels = ubidi_getLevels(bidi, &errorCode); in printCaseInfo() 479 log_err("Direction: %d", ubidi_getDirection(bidi)); fputs("\n", stderr); in printCaseInfo() 480 log_err("paraLevel: %d", ubidi_getParaLevel(bidi)); fputs("\n", stderr); in printCaseInfo() 481 i = ubidi_getReorderingMode(bidi); in printCaseInfo() 484 i = ubidi_getReorderingOptions(bidi); in printCaseInfo() [all …]
|