Helix text editor controlling indents in C++

20 views Asked by At

Hi I am using the Helix text editor and my indents in C++ are just 2 spaces and I want them to be 4. I can't figure out how to make it work

I have been adding the indent to the languages.toml file as the docs tell me to:

[[language]]
name = "cpp"
auto-format = true
formatter = {command = 'clang-format', args= ["--style=Google"]}
indent = { tab-width = 4, unit = "    " }

I was on version 20.05 at first and I also tried on latest master but I alway just get 2 spaces in auto indent and when I press tab

I know the languages.toml file is getting picked up because if I change the style for the formatter that does take effect as expected. So just the indent key is not working as expected for me

0

There are 0 answers