@param array $arguments
@param \Closure $renderChildrenClosure
@param RenderingContextInterface $renderingContext

@return string the formatted amount
321484
public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext)
    {
        preg_match_all(
            '!([A-Z][A-Z0-9]*(?=$|[A-Z][a-z0-9])|[A-Za-z][a-z0-9]+)!',
            $renderChildrenClosure(),
            $matches
        );
        $ret = $matches[0];
        foreach ($ret as &$match) {
            $match = $match === strtoupper($match) ? strtolower($match) : lcfirst($match);
        }
        return implode('-', $ret);
    }
525031
function renderInsideMarginField( $args ) {
		unset( $args['label_for'], $args['class'] );
		$this->renderField(
			[
				'id' => 'pdf_page_margin_inside',
				'name' => 'pressbooks_theme_options_' . $this->getSlug(),
				'option' => 'pdf_page_margin_inside',
				'value' => getset( $this->options, 'pdf_page_margin_inside' ),
				'description' => $args[0],
				'type' => 'text',
				'class' => 'small-text',
			]
		);
	}
411054
public function render(Content $content, $parameters)
    {
        if(!array_key_exists($content->getType(), $this->filters))
        {
            throw new RenderException(
                'Content filter [' . $content->getType() . '] not found. Available filters: ' .
                implode(', ', array_keys($this->filters)) . '.'
            );
        }

        $renderedContent = $this->filters[$content->getType()]->render($content, $parameters);

        if(preg_match_all('/\{\{\s*(include)\s+([a-z0-9\_\-\.\/]+)\s*\}\}/i', $renderedContent, $matches))
        {
            $matchesCount = count($matches[0]);
            for($i = 0; $i < $matchesCount; $i++)
            {
                $includedContent = $this->renderIncludeForContent($content, $matches[2][$i], $parameters);
                $renderedContent = str_replace($matches[0][$i], $includedContent, $renderedContent);
            }
        }

        return $renderedContent;
    }
447867
public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext): string
    {
        $key = $arguments['key'];
        $value = $arguments['value'];

        array_push($GLOBALS['TSFE']->registerStack, $GLOBALS['TSFE']->register);
        $GLOBALS['TSFE']->register[$key] = $value;

        $content = $renderChildrenClosure();

        if ($content) {
            // Restore register when content was rendered
            $GLOBALS['TSFE']->register = array_pop($GLOBALS['TSFE']->registerStack);

            return $content;
        }

        return '';
    }
1135238
public function render(array $arguments = [], $renderer = null) {
        if(empty($this->itemsToDisplay)) {
            return $this->button->render($arguments);
        }

        return $this->baseRender($arguments, $renderer);
    }
190437
public function render(array $arguments, $value = null)
    {
        return self::renderStatic(array('arguments' => $arguments, 'value' => $value), $this->buildRenderChildrenClosure(), $this->renderingContext);
    }
103387
protected function callBuiltinDisplayer($abstract, $arguments)
    {
        if ($abstract instanceof Closure) {
            return $this->display(function ($value) use ($abstract, $arguments) {
                return $abstract->call($this, ...array_merge([$value], $arguments));
            });
        }

        if (class_exists($abstract) && is_subclass_of($abstract, AbstractDisplayer::class)) {
            $grid = $this->grid;
            $column = $this;

            return $this->display(function ($value) use ($abstract, $grid, $column, $arguments) {
                $displayer = new $abstract($value, $grid, $column, $this);

                return call_user_func_array([$displayer, 'display'], $arguments);
            });
        }

        return $this;
    }
303371
private function getArgumentString(ArgumentInterface $argument, $collapse = false)
    {
        if ($collapse) {
            return '...';
        }

        if ($argument instanceof PyStringNode) {
            $text = '"""' . "\n" . $argument . "\n" . '"""';

            return $text;
        }

        return (string) $argument;
    }
822568
public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext) {
    $uid         = intval($arguments['uid']);
    $languageUid = isset($arguments['languageUid']) ? intval($arguments['languageUid']) : self::getLanguageService()->getLanguageUid();

    return self::getPageService()->getPageByUid($uid, $languageUid);
  }
893819
public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext): string {
    $input     = $arguments['input'];
    $separator = $arguments['separator'];
    $output    = '';

    if ($input) {
      $output = self::createSlug($input, $separator);
    }

    return $output;
  }
656230
public function renderCall($method, array $arguments = [], $semicolon = false, $newLine = false)
    {
        return $this->renderCode(
            $method.$this->renderArguments($arguments),
            $semicolon,
            $newLine
        );
    }
1185750
function render($context = null, $vars = array())
    {
        $directives = $this->getDirectives();

        foreach ($directives as $directive) {
            list($i, $name, $argv) = $directive;
            $this->executeDirective($name, $context, $argv);
        }

        return $this->getProcessedSource();
    }
614504
public static function renderStatic(
        array $arguments,
        \Closure $renderChildrenClosure,
        RenderingContextInterface $renderingContext
    ) {
        if (0 === $arguments['resultsPerPage']) {
            $arguments['resultsPerPage'] = self::DEFAULT_RESULTS_PER_PAGE;
        }

        $pageNumber = (int) ceil($arguments['resultNumber'] / $arguments['resultsPerPage']);

        return $pageNumber;
    }
1206802
protected static function highlightSingleField($fieldString, $highlightInfo, $arguments)
    {
        $result = null;

        foreach ($highlightInfo as $highlightItem) {
            $highlightItemStripped = str_replace(['\ueeee', '\ueeef'], ['', ''], $highlightItem);
            if (null !== strpos($fieldString, $highlightItemStripped)) {
                // HTML escape the text here if not explicitly configured to not do so.
                // Use f:format.raw in the template to avoid double escaping the HTML tags.
                if (!$arguments['raw']) {
                    $highlightItem = htmlspecialchars($highlightItem);
                }

                $highlightItemMarkedUp = str_replace(
                    ['\ueeee', '\ueeef'],
                    [$arguments['highlightTagOpen'], $arguments['highlightTagClose']],
                    $highlightItem);
                $result = str_replace($highlightItemStripped, $highlightItemMarkedUp, $fieldString);
                break;
            }
        }

        // If no highlighted string is present, use the original one.
        if (null === $result) {
            if ($arguments['raw']) {
                $result = $fieldString;
            } else {
                $result = htmlspecialchars($fieldString);
            }
        }

        return $result;
    }
920249
function RenderContext() {
		this._aBuffer = [];
		var that = this;
		this.add = function() {
			that._aBuffer.push.apply(that._aBuffer, arguments);
		};
		this.addWithParam = function(s, o) {
			for (var n in o) {
				var reg = new RegExp("\{" + n + "\}","g");
				s = s.replace(reg,o[n]);
			}
			that.add(s);
		};
		this.toString = function() {
			return that._aBuffer.join("");
		};
	}
1270721
protected function renderParameters(array $parameters, $recursion=false)
    {

        $isOperatorFormat = $this->toStringFormat == 'operator';

        $separator = $isOperatorFormat ? ', ' : ',';

        $rendered = [];

        foreach ($parameters as $parameter) {

            if ($parameter === null) {
                $rendered[] = 'null';
                continue;
            }

            if (is_resource($parameter)) {
                $rendered[] = $this->toStringFormat == 'operator' ? 'resource of type ' . get_resource_type($parameter) : get_resource_type($parameter);
                continue;
            }

            if (is_object($parameter)) {
                $rendered[] = get_class($parameter);
                continue;
            }

            if (!is_array($parameter)) {
                $rendered[] = "$parameter";
                continue;
            }

            if (count($parameter) > 80  || $recursion  || !$this->containsOnlyScalars($parameter)) {
                $rendered[] = '[' . $this->renderParameters($parameter) . ']';
                continue;
            }

            if ($isOperatorFormat) {
                $rendered[] = '(' . $this->renderParameters($parameter, true) . ')';
                continue;
            }

            $rendered[] = $this->renderParameters($parameter, true);

        }

        return implode($separator, $rendered);
    }
171699
public function render(array $arguments = [], $renderer = null) {
        if(!$this->getMeta()->editable) {
            throw new Exception('Field "' . $this->getMeta()->name . '" is not editable');
        }

        $type = $this->getMeta()->type;
        if($renderer === null) {
            if(!isset(static::$renderers[$type])) {
                if(static::$fallbackRenderer === null) {
                    throw new Exception('No Default Renderer Exists for Class "' . get_class() . '"');
                }
                $renderer = static::$fallbackRenderer;
            } else {
                if(is_callable(static::$renderers[$type])) {
                    $callable = static::$renderers[$type];
                    static::$renderers[$type] = $callable();
                }
                $renderer = static::$renderers[$type];
            }
        } else {
            if(is_callable($renderer)) {
                $renderer = $renderer();
            }
        }

        return $renderer->render($this, $arguments);
    }