[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/xkcd 7b1a312239 37/82: Add an help-echo text property to d
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/xkcd 7b1a312239 37/82: Add an help-echo text property to display the alt-text |
Date: |
Mon, 12 Dec 2022 21:59:52 -0500 (EST) |
branch: elpa/xkcd
commit 7b1a312239c0c9175948aa853185bf2c62dac39a
Author: Raphaël Cauderlier <cauderlier@crans.org>
Commit: Raphaël Cauderlier <cauderlier@crans.org>
Add an help-echo text property to display the alt-text
---
xkcd.el | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/xkcd.el b/xkcd.el
index 940ac9185d..8002c8fa8b 100644
--- a/xkcd.el
+++ b/xkcd.el
@@ -139,11 +139,14 @@ be located in xkcd-cache-dir"
(setq title (format "%d: %s" (cdr (assoc 'num (json-read-from-string out)))
(cdr (assoc 'safe_title (json-read-from-string out)))))
(insert (concat title "\n"))
- (insert-image (create-image
- (concat xkcd-cache-dir
- (number-to-string
- (cdr
- (assoc 'num (json-read-from-string out)))) ".png")
'png))
+ (let ((start (point)))
+ (insert-image (create-image
+ (concat xkcd-cache-dir
+ (number-to-string
+ (cdr
+ (assoc 'num (json-read-from-string out))))
".png") 'png))
+ (add-text-properties start (point) '(help-echo xkcd-alt))
+ )
(if (eq xkcd-cur 0)
(setq xkcd-cur (cdr (assoc 'num (json-read-from-string out)))))
(xkcd-cache-json num out)
- [nongnu] elpa/xkcd ca3eed5603 80/82: Prefer HTTPS to HTTP, (continued)
- [nongnu] elpa/xkcd ca3eed5603 80/82: Prefer HTTPS to HTTP, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 5c10f6a679 21/82: Merge pull request #4 from purcell/patch-1, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 25594f98c7 31/82: Add info about Melpa in README., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 52c0d270de 36/82: Use one-letter keybindings, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 20e0b48044 42/82: Correct flycheck warnings, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd f5942003bf 45/82: Fix xkcd-get-json, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 3c13ae29c4 49/82: Docstrings, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd e2daa08012 25/82: Add a better screenshot., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd df47be622f 28/82: The package isn't that hackish now., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd d1bc89dee2 34/82: Add variable xkcd-latest: Stores the latest cached xkcd number., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 7b1a312239 37/82: Add an help-echo text property to display the alt-text,
ELPA Syncer <=
- [nongnu] elpa/xkcd e61b7e6ed6 51/82: xkcd-get-json: Get substring between (point) and (point-max), instead of, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 5693718f71 52/82: Add support for browse-url., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 0db98c2ca2 72/82: Add instructions for el-get., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 046ad2c582 67/82: Add README.org, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 7987d64a7e 71/82: * README.md: Remove. Replaced with README.org., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd b637a2aa84 13/82: Update README.md, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd b9095c5aae 16/82: Make xkcd-get-latest work., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd 2da77a12e2 29/82: Provide xkcd instead of emacs-xkcd, ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd e8bb80c4a0 30/82: Make comments work with Melpa., ELPA Syncer, 2022/12/12
- [nongnu] elpa/xkcd b303669b33 39/82: Merge pull request #7 from rafoo/master, ELPA Syncer, 2022/12/12