Lines Matching refs:runs

64      * The implementation of the access to same-level-runs and of the reordering
70 * same-level-runs is created. Reordering then is done on this vector.
75 * This is inefficient if there are many very short runs. If the average run
157 lineBidi.runs = new BidiRun[0];
304 int start = bidiBase.runs[runIndex].start;
306 byte level = bidiBase.runs[runIndex].level;
310 bidiBase.runs[runIndex].limit -
311 bidiBase.runs[runIndex - 1].limit;
313 limit = start + bidiBase.runs[0].limit;
321 bidiBase.runs = bidiBase.simpleRuns;
325 bidiBase.runs[0] = new BidiRun(0, bidiBase.length, level);
328 /* reorder the runs array (L2) ---------------------------------------------- */
331 * Reorder the same-level runs in the runs array.
339 * each sequence of same-level runs consists of only one run each, we
345 * in the last reordering the sequence of the runs at this level or higher
346 * will be all runs, and we don't need the elaborate loop to search for them.
358 * this run and can --runCount. If it is later part of the all-runs
368 BidiRun[] runs;
380 runs = bidiBase.runs;
392 /* loop for all sequences of runs */
394 /* look for a sequence of runs that are all at >=maxLevel */
396 while (firstRun < runCount && levels[runs[firstRun].start] < maxLevel) {
400 break; /* no more such runs */
405 levels[runs[limitRun].start]>=maxLevel; ) {}
407 /* Swap the entire sequence of runs from firstRun to limitRun-1. */
410 tempRun = runs[firstRun];
411 runs[firstRun] = runs[endRun];
412 runs[endRun] = tempRun;
418 break; /* no more such runs */
434 /* Swap the entire sequence of all runs. (endRun==runCount) */
436 tempRun = runs[firstRun];
437 runs[firstRun] = runs[runCount];
438 runs[runCount] = tempRun;
445 /* compute the runs array --------------------------------------------------- */
448 BidiRun[] runs = bidiBase.runs;
452 length = runs[i].limit - visualStart;
453 logicalStart = runs[i].start;
464 * Compute the runs array from the levels array.
466 * and the runs are reordered.
467 * Odd-level runs have visualStart on their visual right edge and
476 * This method returns immediately if the runs are already set. This
504 /* count the runs, there is at least one non-WS run, and limit>0 */
522 /* allocate and set the runs */
523 BidiRun[] runs;
535 runs = bidiBase.runsMemory;
537 /* set the runs */
562 runs[runIndex] = new BidiRun(start, i - start, level);
568 runs[runIndex] = new BidiRun(limit, length - limit, bidiBase.paraLevel);
577 bidiBase.runs = runs;
586 runs[i].level = levels[runs[i].start];
587 limit = (runs[i].limit += limit);
596 runs[trailingRun].level = bidiBase.paraLevel;
608 bidiBase.runs[runIndex].insertRemove |= point.flag;
620 bidiBase.runs[runIndex].insertRemove--;
698 break; /* no more such runs */
733 /* fill a visual-to-logical index map using the runs[] */
734 BidiRun[] runs = bidiBase.runs;
743 logicalStart = runs[j].start;
744 visualLimit = runs[j].limit;
745 if (runs[j].isEvenRun()) {
761 runs = bidiBase.runs;
764 insertRemove = runs[i].insertRemove;
775 insertRemove = runs[i].insertRemove;
780 visualStart = i > 0 ? runs[i-1].limit : 0;
781 for (j = runs[i].limit - 1; j >= visualStart && markFound > 0; j--) {
795 runs = bidiBase.runs;
800 length = runs[i].limit - visualStart;
801 insertRemove = runs[i].insertRemove;
809 visualLimit = runs[i].limit;
815 logicalStart = runs[i].start;
816 evenRun = runs[i].isEvenRun();