[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/annotate fd2cd2d94d 139/372: - made text snippet in summar
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/annotate fd2cd2d94d 139/372: - made text snippet in summary window, for info files, less messy. |
Date: |
Fri, 4 Feb 2022 16:58:35 -0500 (EST) |
branch: elpa/annotate
commit fd2cd2d94d9444a803995a326ceef89235616949
Author: cage <cage-invalid@invalid>
Commit: cage <cage-invalid@invalid>
- made text snippet in summary window, for info files, less messy.
---
annotate.el | 38 ++++++++++++++++++++++++++++----------
1 file changed, 28 insertions(+), 10 deletions(-)
diff --git a/annotate.el b/annotate.el
index 8185e0fcf0..d384aa68a9 100644
--- a/annotate.el
+++ b/annotate.el
@@ -1301,18 +1301,36 @@ sophisticated way than plain text"
'action
'annotate-summary-button-pressed
'type
'annotate-summary-button)
(insert "\n\n"))
+ (clean-snippet (snippet)
+ (save-match-data
+ (replace-regexp-in-string "[\r\n]"
+ " "
+ snippet)))
+ (build-snippet-info (filename annotation-begin annotation-end)
+ (with-temp-buffer
+ (info-setup filename (current-buffer))
+ (buffer-substring-no-properties
annotation-begin
+
annotation-end)))
(build-snippet (filename annotation-begin annotation-end)
(if (file-exists-p filename)
- (with-temp-buffer
- (insert-file-contents filename
- nil
- (1- annotation-begin)
- (1- annotation-end))
- (save-match-data
- (replace-regexp-in-string "[\r\n]"
- " "
-
(buffer-string))))
- annotate-error-summary-win-filename-invalid))
+ (cond
+ ((eq (annotate-guess-file-format filename)
+ :info)
+ (clean-snippet (build-snippet-info filename
+
annotation-begin
+
annotation-end)))
+ (t
+ (with-temp-buffer
+ (insert-file-contents filename
+ nil
+ (1-
annotation-begin)
+ (1- annotation-end))
+ (clean-snippet (buffer-string)))))
+ (if (annotate-info-root-dir-p filename)
+ (clean-snippet (build-snippet-info filename
+
annotation-begin
+
annotation-end))
+ annotate-error-summary-win-filename-invalid)))
(db-empty-p (dump)
(cl-every (lambda (a)
(cl-every 'null
- [nongnu] elpa/annotate d6a4fcc18e 035/372: add next-annotation and previous-annotation keys, (continued)
- [nongnu] elpa/annotate d6a4fcc18e 035/372: add next-annotation and previous-annotation keys, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate f5711b4f27 067/372: - prevent crash and error when a frame's width is less than value of, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 1a43bfbb1e 061/372: fixes bug with annotations ending on beginning-of-line, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 9ffdc1f762 060/372: fix for annotations with wide characters, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 19acc501d8 086/372: - added/fixed more docstrings., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 774e643af4 081/372: - fixed retrocompatibility with old annotation file format., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 4d78e3f6d6 073/372: - restored spaces to comply with markdown syntax;, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 95da172588 056/372: readme improvement, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 54aefdec8d 114/372: Merge pull request #46 from cage2/master, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 201b4587dc 136/372: - made recongnizable code that refers to info file annotation (1/3), ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate fd2cd2d94d 139/372: - made text snippet in summary window, for info files, less messy.,
ELPA Syncer <=
- [nongnu] elpa/annotate 75d291a69f 141/372: - using 'annotate-with-inhibit-modification-hooks'., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 5b69043454 152/372: - added variable 'annotate-annotation-position-policy', ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 5b0bb094c9 166/372: - added known bug;, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 4972c555c6 171/372: - fixed version number., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 004aea92ea 179/372: - updated documentation;, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 490a935b18 186/372: Merge branch 'master' into org-mode-fix, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 947e93a067 204/372: Merge branch 'master' into org-mode-fix, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate df704cc033 205/372: Merge branch 'master' into rethink-multiline-annotations, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 9a9227f154 208/372: - changed function names:, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 6cc6ac8872 210/372: Merge pull request #61 from cage2/org-mode-fix, ELPA Syncer, 2022/02/04