[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-font
From: |
Alex Bochannek |
Subject: |
bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles |
Date: |
Sat, 04 Sep 2021 18:18:25 -0700 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) |
Alex Bochannek <alex@bochannek.com> writes:
> Hello!
>
> A while back I turned off `shr-use-fonts' for my HTML email but found
> that occasionally proportional fonts are useful when reading my
> messages.
>
> I am proposing the below `gnus-article-toggle-fonts' function with a
> keybinding of `W D F'.
The patch did not keep the fonts toggled when selecting the next message
or reloading the current one. I am proposing the below change. I am not
sure how you feel about buffer-local Gnus variables in `mm-decode.el',
so please let me know if an alternative approach would be better.
Thanks!
diff --git a/lisp/gnus/mm-decode.el b/lisp/gnus/mm-decode.el
index 82d1de25f3..5c5896446e 100644
--- a/lisp/gnus/mm-decode.el
+++ b/lisp/gnus/mm-decode.el
@@ -1843,6 +1843,9 @@ mm-shr
(buffer-string))))))
(shr-inhibit-images mm-html-inhibit-images)
(shr-blocked-images mm-html-blocked-images)
+ (shr-use-fonts (if (local-variable-p 'gnus-article-shr-use-fonts)
+ gnus-article-shr-use-fonts
+ shr-use-fonts))
charset coding char document)
(mm-with-part (or handle (setq handle (mm-dissect-buffer t)))
(setq case-fold-search t)
--
Alex.
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Alex Bochannek, 2021/09/04
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles,
Alex Bochannek <=
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Lars Ingebrigtsen, 2021/09/05
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Alex Bochannek, 2021/09/06
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Lars Ingebrigtsen, 2021/09/06
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Alex Bochannek, 2021/09/06
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Lars Ingebrigtsen, 2021/09/07
- bug#50383: 28.0.50; [PATCH] Feature suggestion, gnus-article-toggle-fonts to toggle fonts for HTML articles, Alex Bochannek, 2021/09/07