emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[nongnu] elpa/annotate d46d5afd34 122/372: - made two arguments of annot


From: ELPA Syncer
Subject: [nongnu] elpa/annotate d46d5afd34 122/372: - made two arguments of annotate-create-annotation non optional;
Date: Fri, 4 Feb 2022 16:58:29 -0500 (EST)

branch: elpa/annotate
commit d46d5afd34e06bd020ca045e7a33eb540934e9c3
Author: cage <cage-invalid@invalid>
Commit: cage <cage-invalid@invalid>

    - made two arguments of annotate-create-annotation non optional;
    - cosmetic changes to a single docstring.
---
 annotate.el | 37 +++++++++++++++++++------------------
 1 file changed, 19 insertions(+), 18 deletions(-)

diff --git a/annotate.el b/annotate.el
index 9c19ba1a20..5b5a76d761 100644
--- a/annotate.el
+++ b/annotate.el
@@ -279,7 +279,7 @@ modified (for example a newline is inserted)."
       (font-lock-fontify-buffer nil))
      (t
       (cl-destructuring-bind (start end) (annotate-bounds)
-        (annotate-create-annotation start end)
+        (annotate-create-annotation start end nil nil)
         (font-lock-fontify-block 1))))
     (set-buffer-modified-p t)))
 
@@ -982,25 +982,26 @@ essentially what you get from:
   (or (null a)
       (string= "" a)))
 
-(defun annotate-create-annotation (start end &optional annotation-text 
annotated-text)
+(defun annotate-create-annotation (start end annotation-text annotated-text)
   "Create a new annotation for selected region.
 
-  Here the argument 'annotation-text' is the string that appears in the margin 
of the window
-  and 'annotated-text' is the string that is underlined.
-
-  If this function is called from procedure
-  'annotate-load-annotations' the argument 'annotated-text'
-  should be not null. In this case we know that an annotation
-  existed in a text interval defined in the database
-  metadata (the database located in the file specified by the
-  variable 'annotate-file') and should just be
-  restored. Sometimes the annotated text (see above) can not be
-  found in said interval because the annotated file's content
-  changed and annotate-mode could not track the
-  changes (e.g. save the file when annotate-mode was not
-  active/loaded) in this case the matching
-  text ('annotated-text') is searched in a region surrounding the
-  interval and, if found, the buffer is annotated right there."
+Here the argument 'annotation-text' is the string that appears
+in the margin of the window and 'annotated-text' is the string
+that is underlined.
+
+If this function is called from procedure
+'annotate-load-annotations' the argument 'annotated-text'
+should be not null. In this case we know that an annotation
+existed in a text interval defined in the database
+metadata (the database located in the file specified by the
+variable 'annotate-file') and should just be
+restored. Sometimes the annotated text (see above) can not be
+found in said interval because the annotated file's content
+changed and annotate-mode could not track the
+changes (e.g. save the file when annotate-mode was not
+active/loaded) in this case the matching
+text ('annotated-text') is searched in a region surrounding the
+interval and, if found, the buffer is annotated right there."
   (cl-labels ((create-annotation     (start end annotation-text)
                                      (let ((highlight (make-overlay start 
end)))
                                        (overlay-put highlight 'face 
'annotate-highlight)



reply via email to

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