Lines Matching refs:result
135 $result = '';
139 self::beginCurrentSpan($result);
166 self::breakCurrentSpan($result);
168 $result .= $element;
186 $result .= $entity;
202 $result .= self::$waitingText . $directive;
344 $result .= self::$waitingText;
351 self::finishCurrentSpan($result);
354 self::beginCurrentSpan($result);
358 $result .= self::$waitingText;
376 $result .= self::UTF8_PDF;
382 self::finishCurrentSpan($result, true);
387 $result .= self::START_RTL;
388 $result .= self::$waitingText;
389 $result .= self::END_RTL;
391 $result .= self::START_LTR;
392 $result .= self::$waitingText;
393 $result .= self::END_LTR;
402 while (substr($result, 0, self::LENGTH_START + 3) === self::START_RTL . self::UTF8_LRE) {
403 $spanEnd = strpos($result, self::END_RTL . self::START_LTR);
407 …$textSpan = self::stripLrmRlm(substr($result, self::LENGTH_START + 3, $spanEnd - self::LENGTH_STAR…
411 …$result = self::START_LTR . substr($result, self::LENGTH_START, $spanEnd - self::LENGTH_START) . s…
417 …$result = str_replace(self::UTF8_PDF . '.' . self::END_RTL, self::UTF8_PDF . self::END_RTL . self:…
422 if (str_contains($result, ' <LTRbr>')) {
423 $result = str_replace(' <LTRbr>', '<LTRbr>', $result);
426 if (str_contains($result, ' <LTRbr>')) {
427 $result = str_replace(' <LTRbr>', '<LTRbr>', $result);
430 if (str_contains($result, ' <br>')) {
431 $result = str_replace(' <br>', '<br>', $result);
434 if (str_contains($result, ' <br>')) {
435 $result = str_replace(' <br>', '<br>', $result);
443 if (str_contains($result, ' <RTLbr>')) {
444 $result = str_replace(' <RTLbr>', '<RTLbr>', $result);
447 if (str_contains($result, ' <RTLbr>')) {
448 $result = str_replace(' <RTLbr>', '<RTLbr>', $result);
455 $result = str_replace([
461 ], $result);
464 …result . "\n", 0, self::LENGTH_START) !== self::START_LTR && substr($result . "\n", 0, self::LENGT…
467 if ($result === '') {
468 $result = $leadingText;
471 …if (substr($result . "\n", 0, self::LENGTH_START) !== self::START_LTR && substr($result . "\n", 0,…
472 $leadingText .= substr($result, 0, 1);
473 $result = substr($result, 1);
476 …$result = substr($result, 0, self::LENGTH_START) . $leadingText . substr($result, self::LENGTH_STA…
482 $result = str_replace([
488 ], $result);
496 $result = str_replace([
499 ], '', $result);
505 $result = str_replace([
515 ], $result);
517 return $result;
608 * @param string $result
612 private static function breakCurrentSpan(string &$result): void argument
615 $result .= self::$waitingText;
619 $result .= $breakString;
625 * @param string $result
629 private static function beginCurrentSpan(string &$result): void argument
632 $result .= self::START_LTR;
635 $result .= self::START_RTL;
638 self::$posSpanStart = strlen($result);
644 * @param string $result
649 private static function finishCurrentSpan(string &$result, bool $theEnd = false): void argument
651 $textSpan = substr($result, self::$posSpanStart);
652 $result = substr($result, 0, self::$posSpanStart);
655 $result = str_replace([
658 ], '', $result);
834 if (str_contains($result, self::START_RTL)) {
961 $result .= self::START_LTR . $leadingSeparator . self::END_LTR;
963 $result .= $textSpan . self::END_LTR;
965 $result .= self::START_LTR . $trailingSeparator . self::END_LTR;
968 $result .= self::START_LTR . $trailingID . self::END_LTR;
971 $result .= self::START_LTR . $trailingPunctuation . self::END_LTR;
974 $result .= self::START_LTR . $trailingBlanks . self::END_LTR;
1143 $result .= $textSpan . self::END_RTL;
1147 $result .= $textSpan;
1150 $result .= $trailingBreaks; // Get rid of any waiting <br>