From 80409e0fd830ccbc95890007613b7609ba284232 Mon Sep 17 00:00:00 2001 From: Marcel Kapfer Date: Fri, 23 Feb 2018 09:58:22 +0100 Subject: [PATCH] Emacs: add TeX-insert-comment-line function --- emacs/emacs.el | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/emacs/emacs.el b/emacs/emacs.el index cca11b4..fd338af 100644 --- a/emacs/emacs.el +++ b/emacs/emacs.el @@ -1032,6 +1032,15 @@ :config ;; No language-specific hyphens please (setq LaTeX-babel-hyphen nil) + + ;; helper for a new (La)TeX style guide concept. + ;; inserts a line break, a empty comment line and another line break + (defun TeX-insert-comment-line () + "Insert a linebreak followed by a '%' and another line break" + (interactive) + (newline-and-indent) + (insert "%") + (newline-and-indent)) ;; Easy math input (add-hook 'TeX-mode-hook #'LaTeX-math-mode) ;; Start flyspell