Skip to content

Commit 137262f

Browse files
committed
Add indent_method property for nontrivial indentation methods
This PR aims to solve the requirement of editorconfig/editorconfig#323 to add support for `smart_tabs`. I propose to add a generic `indent_method` property to be able to 1. add support for non-trivial indentation methods 2. allow a backward compatible definition of indentation methods. Therefore the `indent_method` may override indent size and style if required. I added two common (?) methods for the beginning: `smart_tabs` and `elastic_tabs`, the list may grow in the future. I would prefer to also explain what `smart_tabs` and `elastic_tabs` refer to, for this it would be necessary to write a small explanation to avoid the risk any referenced website goes down. What do you think?
1 parent e02645d commit 137262f

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

index.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,10 @@ and the supported values associated with them:
214214
equals ``tab``, the ``indent_size`` shall be set to the tab size, which
215215
should be ``tab_width`` (if specified); else, the tab size set by the
216216
editor. The values are case insensitive.
217+
* - ``indent_method``
218+
- Set to ``smart_tabs`` or ``elastic_tabs`` to use a smart tabs respectively elastic
219+
tabstops (when supported). The given tabstop method may override the ``indent_style``
220+
or ``indent_size`` settings as required.
217221
* - ``tab_width``
218222
- Set to a whole number defining the number of columns used to represent
219223
a tab character. This defaults to the value of ``indent_size`` and should

0 commit comments

Comments
 (0)