Variable: php-ts-mode-indent-style

php-ts-mode-indent-style is a customizable variable defined in php-ts-mode.el.gz.

Value

psr2

Documentation

Style used for indentation.

The selected style could be one of: PSR-2/PSR-12 - use PSR standards (PSR-2, PSR-12), this is the default. PEAR - use coding styles preferred for PEAR code and modules. Drupal - use coding styles preferred for working with Drupal projects. WordPress - use coding styles preferred for working with WordPress projects. Symfony - use coding styles preferred for working with Symfony projects. Zend - use coding styles preferred for working with Zend projects.

If one of the supplied styles doesn't suffice, a function could be set instead. This function is expected return a list that follows the form of treesit-simple-indent-rules.

This variable was added, or its default value changed, in Emacs 30.1.

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/php-ts-mode.el.gz
(defcustom php-ts-mode-indent-style 'psr2
  "Style used for indentation.
The selected style could be one of:
`PSR-2/PSR-12' - use PSR standards (PSR-2, PSR-12), this is the default.
`PEAR' - use coding styles preferred for PEAR code and modules.
`Drupal' - use coding styles preferred for working with Drupal projects.
`WordPress' - use coding styles preferred for working with WordPress projects.
`Symfony' - use coding styles preferred for working with Symfony projects.
`Zend' - use coding styles preferred for working with Zend projects.

If one of the supplied styles doesn't suffice, a function could be
set instead.  This function is expected return a list that
follows the form of `treesit-simple-indent-rules'."
  :tag "PHP indent style"
  :version "30.1"
  :type '(choice (const :tag "PSR-2/PSR-12" psr2)
		 (const :tag "PEAR" pear)
		 (const :tag "Drupal" drupal)
		 (const :tag "WordPress" wordpress)
		 (const :tag "Symfony" symfony)
		 (const :tag "Zend" zend)
		 (function :tag "A function for user customized style" ignore))
  :set #'php-ts-mode--indent-style-setter
  :safe #'php-ts-indent-style-safep)