April 02, 2020 Turning off syntactic indentation in emacs d-mode | ||||
---|---|---|---|---|
| ||||
Hi, So d-mode on emacs seems to have strange indentation issues, some of which seems to be documented here https://github.com/Emacs-D-Mode-Maintainers/Emacs-D-Mode/issues/19 This is almost a non-issue if you turn off syntactic-indentation in the D menu bar. How can I set this to be off by default? At the moment I have to keep turning it off for every frame/buffer it seems. Cheers, Farhan |
May 02, 2020 Re: Turning off syntactic indentation in emacs d-mode | ||||
---|---|---|---|---|
| ||||
Posted in reply to Farhan Wali | On Thursday, 2 April 2020 at 19:48:48 UTC, Farhan Wali wrote:
> Hi,
>
> So d-mode on emacs seems to have strange indentation issues, some of which seems to be documented here https://github.com/Emacs-D-Mode-Maintainers/Emacs-D-Mode/issues/19
>
> This is almost a non-issue if you turn off syntactic-indentation in the D menu bar. How can I set this to be off by default? At the moment I have to keep turning it off for every frame/buffer it seems.
>
> Cheers,
> Farhan
If you still have this issue, you could try adding the following hook to your Emacs init file:
(add-hook 'd-mode-hook
(function (lambda ()
(setq c-syntactic-indentation nil))))
This seems to do the trick for me (although, obviously, some automatic indentation features no longer work, such as indentation of the first line after an '{' and de-indentation of '}').
|
Copyright © 1999-2021 by the D Language Foundation