Closed nuynait closed 7 years ago
There's a key hint in the documentation above:
NOTE: This controls the display width of a TAB character, and not the size of an indentation step.
You should instead set
swift-mode:basic-offset is a variable defined in ‘swift-mode-indent.el’.
Its value is 4
This variable is safe as a file local variable if its value
satisfies the predicate ‘integerp’.
Documentation:
Amount of indentation for block contents.
You can customize this variable.
[back]
OH, it works. Thanks a lot.
I don't know if it is a emacs config problem, but I have set the tab width to 2
Now when I write a function in swift
It is still taking 4 space of indentation.
I did research and seems that tab-width is everything we need to set to change indentation to 2 chars.
Am I miss anything here? Please any help is appreciated. Thanks.