[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: While editing a CMake file, how to turn off smart indentation?
From: |
Yaron Cohen-Tal |
Subject: |
Re: While editing a CMake file, how to turn off smart indentation? |
Date: |
Sun, 19 Jul 2015 20:35:13 +0300 |
That did the trick, thanx!
On Sat, Jul 18, 2015 at 10:18 PM, John Mastro <john.b.mastro@gmail.com>
wrote:
> > The shortcuts to (un)indent 4 spaces work perfectly. What I still don't
> > manage is to make "RET" simply start a new line with indentation
> identical
> > to the previous line. In C++ mode I arranged it so behave this way. I
> tried
> > changing the code in "cmake-mode.el" from:
>
> Try this (in your init file; no need to modify cmake-mode.el):
>
> (defun my-set-relative-indent ()
> (setq-local indent-line-function #'indent-relative))
>
> (add-hook 'cmake-mode-hook #'my-set-relative-indent)
>
> --
> john
>
- Re: While editing a CMake file, how to turn off smart indentation?, (continued)
- Re: While editing a CMake file, how to turn off smart indentation?, Vaidheeswaran C, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, Ian Zimmerman, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, Yaron Cohen-Tal, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, Vaidheeswaran C, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, Emanuel Berg, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, John Mastro, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, Emanuel Berg, 2015/07/17
- Re: While editing a CMake file, how to turn off smart indentation?, Yaron Cohen-Tal, 2015/07/18
- Re: While editing a CMake file, how to turn off smart indentation?, John Mastro, 2015/07/18
- Re: While editing a CMake file, how to turn off smart indentation?,
Yaron Cohen-Tal <=