From ee69dc2b3c2a6ca6fdf0c61c17f455ab13572503 Mon Sep 17 00:00:00 2001 From: Chris Mann Date: Thu, 10 Jan 2008 13:24:28 +1030 Subject: [PATCH] * wesnoth-mode.el: Improved doc-strings of indentation styles. --- wesnoth-mode.el | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/wesnoth-mode.el b/wesnoth-mode.el index d3472a5..6447187 100644 --- a/wesnoth-mode.el +++ b/wesnoth-mode.el @@ -399,8 +399,11 @@ Otherwise return nil." (defun wesnoth-indent (savefile preproc-bol) "Indent the current line as WML. -If savefile-style is non-nil, use savefile-style indentation, -otherwise use default style indentation." +If SAVEFILE is non-nil, use savefile-style indentation, +otherwise use default style indentation. +If PREPROC-BOL is non-nil, indent preprocessor statements +to the first column, otherwise indent them inline with any +surrounding tags." (beginning-of-line) (if (or (not (wesnoth-wml-start-pos)) (<= (point) (wesnoth-wml-start-pos)) @@ -442,20 +445,24 @@ otherwise use default style indentation." (beginning-of-line) (search-forward-regexp "[\t ]*")) -(defun wesnoth-indent-savefile () - "Indent the current line as WML code using savefile-style indentation." - (wesnoth-indent t nil)) - (defun wesnoth-indent-default () - "Indent the current line as WML code using default-style indentation." + "Indent the current line using default-style indentation. +Preprocessor statements will be indented as tags." (wesnoth-indent nil nil)) +(defun wesnoth-indent-savefile () + "Indent the current line using savefile-style indentation. +Preprocessor statements will be indented as tags." + (wesnoth-indent t nil)) + (defun wesnoth-indent-default-preproc () - "Indent the current line as WML code using default-style indentation." + "Indent the current line using default-style indentation. +Preprocessor statements will be indented to the first column." (wesnoth-indent nil t)) (defun wesnoth-indent-savefile-preproc () - "Indent the current line as WML code using default-style indentation." + "Indent the current line using savefile-style indentation. +Preprocessor statements will be indented to the first column." (wesnoth-indent t t)) -- 2.11.4.GIT