[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 43cbc15 21/40: Fixed checkdoc issues
From: |
Alexey Veretennikov |
Subject: |
[elpa] master 43cbc15 21/40: Fixed checkdoc issues |
Date: |
Fri, 29 Jan 2016 23:29:40 +0000 |
branch: master
commit 43cbc153eb1037d5575c0eb5c24666abb59efafb
Author: Alexey Veretennikov <address@hidden>
Commit: Alexey Veretennikov <address@hidden>
Fixed checkdoc issues
---
loccur.el | 34 +++++++++++++++++++++-------------
1 files changed, 21 insertions(+), 13 deletions(-)
diff --git a/loccur.el b/loccur.el
index 863bee3..56c92d7 100644
--- a/loccur.el
+++ b/loccur.el
@@ -75,13 +75,12 @@
;; !SECTION! Possible highlighting of the matching regex
(defvar loccur-highlight-matching-regexp t
- "If set to a non-nil value, the part of the line matching the
-regex is highlighted. Use loccur-toggle-highlight to modify its
-value interactively.")
+ "Determines if the part of the line matching the regex is highlighted.
+If set to a non-nil value, highlight. Use `loccur-toggle-highlight' to
+modify its value interactively.")
(defcustom loccur-jump-beginning-of-line nil
- "Determines if cursor shall be at the beginning of the line
-when the loccur function is called.")
+ "Set cursor to the beginning of the line when the loccur function is
called.")
(defun loccur-toggle-highlight()
"Toggles the highlighting of the part of the line matching the
@@ -103,6 +102,7 @@ regex given in the loccur buffer."
(,(kbd "RET") . loccur-current)))
(defun loccur-toggle-mode (regex)
+ "Toggle the function `loccur-mode' for REGEX."
(if (or loccur-mode
(null regex)
(zerop (length regex)))
@@ -120,11 +120,11 @@ regex given in the loccur buffer."
;; !SUBSECTION! History
(defvar loccur-history nil
- "History of previously searched expressions for the prompt")
+ "History of previously searched expressions for the prompt.")
(make-variable-buffer-local 'loccur-history)
(defvar loccur-last-match nil
- "Last match found")
+ "Last match found.")
(make-variable-buffer-local 'loccur-last-match)
@@ -141,7 +141,8 @@ regex given in the loccur buffer."
"A list of currently active overlays.")
(make-variable-buffer-local 'loccur-overlay-list)
-(defun loccur-create-highlighted-overlays(buffer-matches)
+(defun loccur-create-highlighted-overlays (buffer-matches)
+ "Create the list of overlays for BUFFER-MATCHES."
(let ((overlays
(mapcar (lambda (match)
(make-overlay
@@ -158,6 +159,7 @@ regex given in the loccur buffer."
(defun loccur-create-invisible-overlays (ovl-bounds)
+ "Create a list of invisible overlays by given OVL-BOUNDS."
(let ((overlays
(mapcar (lambda (bnd)
(make-overlay
@@ -175,11 +177,13 @@ regex given in the loccur buffer."
(defun loccur-remove-overlays ()
+ "Remove all overlays."
(remove-overlays (point-min) (point-max) loccur-overlay-property-name t)
(setq loccur-overlay-list nil))
(defun loccur-create-overlay-bounds-btw-lines (buffer-matches)
+ "Create a list of overlays between matched lines BUFFER-MATCHES."
(let ((prev-end (point-min))
(overlays (list)))
(when buffer-matches
@@ -198,11 +202,10 @@ regex given in the loccur buffer."
;; !SECTION! Main functions, those actually performing the loccur
(defun loccur (regex)
- "Perform a simple grep in current buffer for the regular
-expression REGEX
+ "Perform a simple grep in current buffer.
This command hides all lines from the current buffer except those
-containing the regular expression REGEX. A second call of the function
+containing the regular expression REGEX. A second call of the function
unhides lines again"
(interactive
(if loccur-mode
@@ -222,7 +225,7 @@ unhides lines again"
(loccur (current-word)))
(defun loccur-prompt ()
- "Returns the default value of the prompt.
+ "Return the default value of the prompt.
Default value for prompt is a current word or active region(selection),
if its size is 1 line"
@@ -241,6 +244,9 @@ if its size is 1 line"
(defun loccur-1 (regex)
+ "Implementation of the `loccur' functionality.
+
+REGEX is an argument to `loccur'."
(let* ((buffer-matches (loccur-find-matches regex))
(ovl-bounds (loccur-create-overlay-bounds-btw-lines buffer-matches)))
(setq loccur-overlay-list
@@ -253,7 +259,9 @@ if its size is 1 line"
(defun loccur-find-matches (regex)
- "Returns a list of 4-number tuples, specifying begnning of the line,
+ "Find all occurences in the current buffer for given REGEX.
+
+Returns a list of 4-number tuples, specifying begnning of the line,
1st match begin of a line, 1st match end of a line, end of a line
containing match"
(save-excursion
- [elpa] master 9b5d16c 13/40: Added detailed info on the README file., (continued)
- [elpa] master 9b5d16c 13/40: Added detailed info on the README file., Alexey Veretennikov, 2016/01/29
- [elpa] master e9d4714 15/40: Fixed displaying problems on github caused by the README file., Alexey Veretennikov, 2016/01/29
- [elpa] master 409b322 11/40: Rewrote the minor-mode using the define-minor-mode macro and added RET, Alexey Veretennikov, 2016/01/29
- [elpa] master d279b6a 16/40: Added internal link to the "quick navigation" in the README file., Alexey Veretennikov, 2016/01/29
- [elpa] master b1b1d91 18/40: Updated version, Alexey Veretennikov, 2016/01/29
- [elpa] master 8aef9f0 19/40: Added customizable option to jump to the beginnig of the line in loccur mode: loccur-jump-beginning-of-line, Alexey Veretennikov, 2016/01/29
- [elpa] master ab4804a 20/40: Removed some cl dependencies; version changed to 1.2.1, Alexey Veretennikov, 2016/01/29
- [elpa] master cb7f8ac 17/40: Merge pull request #1 from picarresursix/master, Alexey Veretennikov, 2016/01/29
- [elpa] master 7d19c16 22/40: Preparation to move to GNU ELPA., Alexey Veretennikov, 2016/01/29
- [elpa] master 8ffd028 23/40: Preparation to move to GNU ELPA., Alexey Veretennikov, 2016/01/29
- [elpa] master 43cbc15 21/40: Fixed checkdoc issues,
Alexey Veretennikov <=
- [elpa] master b6655e3 24/40: Preparation to move to GNU ELPA., Alexey Veretennikov, 2016/01/29
- [elpa] master 900eb51 26/40: Preparation to move to GNU ELPA., Alexey Veretennikov, 2016/01/29
- [elpa] master f95c8d6 28/40: Preparation to move to GNU ELPA., Alexey Veretennikov, 2016/01/29
- [elpa] master 359fae1 25/40: Preparation to move to GNU ELPA., Alexey Veretennikov, 2016/01/29
- [elpa] master 194dd68 30/40: Reimplemented loccur-no-highlight and fixed checkdoc, Alexey Veretennikov, 2016/01/29
- [elpa] master 66a9810 32/40: Merge pull request #3 from syohex/group, Alexey Veretennikov, 2016/01/29
- [elpa] master e5d1061 31/40: Define group for customize and fixing byte-compile warnings, Alexey Veretennikov, 2016/01/29
- [elpa] master 2680df7 34/40: Fixed bug when loccur called with empty argument., Alexey Veretennikov, 2016/01/29
- [elpa] master 59b8dd1 29/40: Implemented removed features and added face loccur-face, Alexey Veretennikov, 2016/01/29
- [elpa] master 2cacc68 33/40: Added types to custom, Alexey Veretennikov, 2016/01/29