如何在PHP模式下将缩进更改为Emacs中的2个空格?

时间:2013-09-24 07:58:58

标签: emacs indentation php-mode

我尝试将缩进从4个空格更改为2个空格(我需要用这种样式编写代码)。

我尝试使用php代码在缓冲区中对此进行评估:

(setq tab-width 2)

(setq-default tab-width 2)

但它不起作用,当我键入TAB时,我有4个空格。

1 个答案:

答案 0 :(得分:3)

好的发现了:

(setq c-basic-offset 2)
相关问题