emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

scratch/emacs-editorconfig 98a370e8896 127/364: Massive reformatting of


From: Stefan Monnier
Subject: scratch/emacs-editorconfig 98a370e8896 127/364: Massive reformatting of docstrings.
Date: Tue, 18 Jun 2024 01:40:46 -0400 (EDT)

branch: scratch/emacs-editorconfig
commit 98a370e88960298cfbdb527d40fed3747e41da8a
Author: Hong Xu <hong@topbug.net>
Commit: Stefan Monnier <monnier@iro.umontreal.ca>

    Massive reformatting of docstrings.
---
 editorconfig.el | 60 +++++++++++++++++++++++++++++++++------------------------
 1 file changed, 35 insertions(+), 25 deletions(-)

diff --git a/editorconfig.el b/editorconfig.el
index 4b336daab68..2e328284358 100644
--- a/editorconfig.el
+++ b/editorconfig.el
@@ -48,8 +48,8 @@
 (defgroup editorconfig nil
   "EditorConfig Emacs Plugin.
 
-EditorConfig Helps developers define and maintain consistent coding styles
-between different editors and IDEs"
+EditorConfig helps developers define and maintain consistent
+coding styles between different editors and IDEs."
   :tag "EditorConfig"
   :prefix "editorconfig-"
   :group 'tools)
@@ -68,11 +68,12 @@ This executable is invoked by 
`editorconfig-call-editorconfig-exec'."
 
 (defcustom editorconfig-get-properties-function
   'editorconfig-get-properties
-  "Function to get EditorConofig properties for current buffer.
-This function will be called with no argument and should return a hash object
-containing properties, or nil if any core program is not available.
-The hash object should have symbols of property names as keys and strings of
-property values as values."
+  "A function which gets EditorConofig properties for current buffer.
+
+This function will be called with no argument and should return a
+hash object containing properties, or nil if any core program is
+not available.  The hash object should have symbols of property
+names as keys and strings of property values as values."
   :type 'function
   :group 'editorconfig)
 (define-obsolete-variable-alias
@@ -83,13 +84,14 @@ property values as values."
 (defcustom editorconfig-custom-hooks ()
   "A list of custom hooks after loading common EditorConfig settings.
 
-Each element in this list is a hook function.  This hook function takes one
-parameter, which is a property hash table.  The value of properties can be
-obtained through gethash function.
+Each element in this list is a hook function.  This hook function
+takes one parameter, which is a property hash table.  The value
+of properties can be obtained through gethash function.
 
-The hook does not have to be coding style related; you can add whatever
-functionality you want.  For example, the following is an example to add a new
-property emacs_linum to decide whether to show line numbers on the left
+The hook does not have to be coding style related; you can add
+whatever functionality you want.  For example, the following is
+an example to add a new property emacs_linum to decide whether to
+show line numbers on the left:
 
   (add-hook 'editorconfig-custom-hooks
     '(lambda (props)
@@ -142,14 +144,15 @@ property emacs_linum to decide whether to show line 
numbers on the left
 (defcustom editorconfig-exclude-regexps
   (list (eval-when-compile
           (rx string-start (or "http" "https" "ftp" "sftp" "rsync") ":")))
-  "List of buffer filename prefix regexp patterns not to apply properties."
+  "List of buffer filename prefix regexp patterns not to apply
+properties."
   :type '(repeat string)
   :group 'editorconfig)
 
 (defvar editorconfig-properties-hash nil
   "Hash object of EditorConfig properties for current buffer.
-Set by `editorconfig-apply' and nil if that is not invoked in current buffer
-yet.")
+Set by `editorconfig-apply' and nil if that is not invoked in
+current buffer yet.")
 (make-variable-buffer-local 'editorconfig-properties-hash)
 
 
@@ -196,7 +199,7 @@ yet.")
 
 
 (defun editorconfig-set-line-length (length)
-  "Set the max line length (fill-column) to LENGTH."
+  "Set the max line length (`fill-column') to LENGTH."
   (when (and (editorconfig-string-integer-p length)
              (> (string-to-number length) 0))
     (set-fill-column (string-to-number length))))
@@ -208,7 +211,8 @@ yet.")
   )
 
 (defun editorconfig-get-properties-from-exec ()
-  "Get EditorConfig properties of current buffer by calling 
`editorconfig-exec-path'."
+  "Get EditorConfig properties of current buffer by calling
+`editorconfig-exec-path'."
   (if (executable-find editorconfig-exec-path)
       (editorconfig-parse-properties (editorconfig-call-editorconfig-exec))
     (error "Unable to find editorconfig executable")))
@@ -245,8 +249,8 @@ It calls `editorconfig-get-properties-from-exec' if
 ;;;###autoload
 (defun editorconfig-apply ()
   "Apply EditorConfig properties for current buffer.
-This function ignores `editorconfig-exclude-modes' and always applies available
-properties."
+This function ignores `editorconfig-exclude-modes' and always
+applies available properties."
   (interactive)
   (when buffer-file-name
     (condition-case err
@@ -269,8 +273,8 @@ properties."
 
 (defun editorconfig-mode-apply ()
   "Apply EditorConfig properties for current buffer.
-This function do the job only when the major mode is not listed in
-`editorconfig-exclude-modes'."
+This function does the job only when the major mode is not listed
+in `editorconfig-exclude-modes'."
   (when (and major-mode
              (not (memq major-mode
                         editorconfig-exclude-modes))
@@ -284,9 +288,9 @@ This function do the job only when the major mode is not 
listed in
 ;;;###autoload
 (define-minor-mode editorconfig-mode
   "Toggle EditorConfig feature.
-When enabled EditorConfig properties will be applied to buffers when first
-visiting files or changing major modes if the major mode is not listed in
-`editorconfig-exclude-modes'."
+When enabled EditorConfig properties will be applied to buffers
+when first visiting files or changing major modes if the major
+mode is not listed in `editorconfig-exclude-modes'."
   :global t
   :lighter " EditorConfig"
   (dolist (hook '(after-change-major-mode-hook))
@@ -295,3 +299,9 @@ visiting files or changing major modes if the major mode is 
not listed in
       (remove-hook hook 'editorconfig-mode-apply))))
 
 (provide 'editorconfig)
+
+;;; editorconfig.el ends here
+
+;; Local Variables:
+;; sentence-end-double-space: t
+;; End:



reply via email to

[Prev in Thread] Current Thread [Next in Thread]