Sets the current indentation style to a new one.

The value needs to be one of the `Lexer::INDENT_*` constants, but you can also just
pass either a single space or a single tab for the respective style.

@param $indentStyle

@return $this
177683
public function setIndentStyle($indentStyle)
    {
        if (!in_array($indentStyle, [null, Lexer::INDENT_TAB, Lexer::INDENT_SPACE])) {
            throw new \InvalidArgumentException(
                'indentStyle needs to be null or one of the INDENT_* constants of the lexer'
            );
        }

        $this->indentStyle = $indentStyle;

        return $this;
    }
616952
function(indentation)
	{
		this.moveToNextLine();
		var newIndent = null;
		var indent = null;

		if ( !this.isDefined(indentation) )
		{
			newIndent = this.getCurrentLineIndentation();
			
			var unindentedEmbedBlock = this.isStringUnIndentedCollectionItem(this.currentLine);

			if ( !this.isCurrentLineEmpty() && 0 == newIndent && !unindentedEmbedBlock )
			{
				throw new YamlParseException('Indentation problem A', this.getRealCurrentLineNb() + 1, this.currentLine);
			}
		}
		else
		{
			newIndent = indentation;
		}

		var data = [this.currentLine.substr(newIndent)];

		var isUnindentedCollection = this.isStringUnIndentedCollectionItem(this.currentLine);

		var continuationIndent = -1;
		if (isUnindentedCollection === true) {
			continuationIndent = 1 + /^\-((\s+)(.+?))?\s*$/.exec(this.currentLine)[2].length;
		}

		while ( this.moveToNextLine() )
		{

			if (isUnindentedCollection && !this.isStringUnIndentedCollectionItem(this.currentLine) && this.getCurrentLineIndentation() != continuationIndent) {
				this.moveToPreviousLine();
				break;
			}

			if ( this.isCurrentLineEmpty() )
			{
				if ( this.isCurrentLineBlank() )
				{
					data.push(this.currentLine.substr(newIndent));
				}

				continue;
			}

			indent = this.getCurrentLineIndentation();
			var matches;
			if ( matches = /^( *)$/.exec(this.currentLine) )
			{
				// empty line
				data.push(matches[1]);
			}
			else if ( indent >= newIndent )
			{
				data.push(this.currentLine.substr(newIndent));
			}
			else if ( 0 == indent )
			{
				this.moveToPreviousLine();

				break;
			}
			else
			{
				throw new YamlParseException('Indentation problem B', this.getRealCurrentLineNb() + 1, this.currentLine);
			}
		}

		return data.join("\n");
	}
1341725
public function setStyle($cssStyle) {
		if (!JString::startsWith($cssStyle, "panel"))
			$cssStyle="panel".$cssStyle;
		return $this->addToPropertyCtrl("class", $cssStyle, CssRef::Styles("panel"));
	}
437839
public function indent($indent = null)
    {
        if ($indent === null) {
            return $this->_indent;
        }
        return $this->_indent = $indent;
    }
699513
public function addCSSDeclaration($style){
		if(!isset($this->controller)){
			return false;
			}
		$this->controller->style[]=$style;
		return true;
		}
858279
public static function fromSizeAndStyle(int $size, string $style): self
    {
        $minimumSize = 1;

        if ($minimumSize > $size) {
            throw Exception\InvalidIndentSizeException::fromSizeAndMinimumSize(
                $size,
                $minimumSize
            );
        }

        $characters = [
            'space' => ' ',
            'tab' => "\t",
        ];

        if (!\array_key_exists($style, $characters)) {
            throw Exception\InvalidIndentStyleException::fromStyleAndAllowedStyles(
                $style,
                ...\array_keys($characters)
            );
        }

        $value = \str_repeat(
            $characters[$style],
            $size
        );

        return new self($value);
    }
821736
public function addIndentationLevel($value)
    {
        $this->indentationLevel = max(0, $this->indentationLevel + (int)$value);

        return $this;
    }
1034534
protected function setStyle( $styleType, $styles )
    {
        // Get the cell style
        $style = $this->getCellStyle();

        // Apply style from array
        $style->applyFromArray( [
            $styleType => $styles,
        ] );

        return $this;
    }
645803
public function setOutlineStyle(string $style): Bootstrap4Button
    {
        if (in_array($style, $this->supported_bg_styles) === true &&
            $style !== 'link'
        ) {

            $this->outline_style = $style;
        } else {
            $this->outline_style = 'primary';
        }

        return $this;
    }
600735
public function setStyle(\Jstewmc\Rtf\Style $style = null)
	{
		$this->style = $style;
		
		return $this;
	}
1131134
public function increaseBlockIndent()
    {
        if ($this->increaseBlockIndent) {
            ++$this->indentLvl;
            $this->increaseBlockIndent = false;
            \array_unshift($this->indentTypes, 'block');
        }

        return $this;
    }
334575
public static function indentLines($lines, $indent = '  ')
    {
        $lineSeparator = "\n";
        $buffer        = '';
        $line          = strtok($lines, $lineSeparator);
        while ($line) {
            $buffer .= $indent . $line . $lineSeparator;
            $line = strtok($lineSeparator);
        }
        strtok(null, null);

        return $buffer;
    }
566114
public function setStyle($style)
    {
        if (!is_string($style)) {
            $style = json_encode($style);
        }
        $this->entity->setStyle($style);

        return $this;
    }
1296501
public function current() : interfaces\Style
    {
        return !empty($this->styles) ? end($this->styles) : $this->default;
    }
141732
public function setIndent(int $indent = 2): self
    {
        if (!Number::Range($indent, 2, 8)) {
            throw new CompilerException(sprintf('"%d" is an invalid indent value', $indent));
        }

        return $this;
    }
237683
public function addStyles(array $styles) {
		foreach ($styles as $param => $value) {
			$this->addStyle($param, $value);
		}
		
		return $this;
	}
488946
public function addTextStyle(string $style)
    {
        if (!isset(self::$supportedTextStyles[$style])) {
            throw new InvalidArgumentException("Invalid text style \"$style\"");
        }

        // Don't double-add a style
        if (!in_array($style, $this->textStyles)) {
            $this->textStyles[] = $style;
        }
    }