diff --git a/autoload/clang_format.vim b/autoload/clang_format.vim index ac9c49a..54483be 100644 --- a/autoload/clang_format.vim +++ b/autoload/clang_format.vim @@ -75,9 +75,10 @@ endfunction function! s:make_style_options() abort let extra_options = s:build_extra_options() - return printf("{BasedOnStyle: %s, IndentWidth: %d, UseTab: %s%s}", + return printf("{BasedOnStyle: %s, IndentWidth: %d, TabWidth: %d, UseTab: %s%s}", \ g:clang_format#code_style, \ (exists('*shiftwidth') ? shiftwidth() : &l:shiftwidth), + \ (exists('*tabstop') ? tabstop() : &l:tabstop), \ &l:expandtab==1 ? 'false' : 'true', \ extra_options) endfunction