* font-lock doesn't work on MIME parts
@ 2005-09-02 11:04 Katsumi Yamaoka
2005-09-06 5:22 ` Katsumi Yamaoka
0 siblings, 1 reply; 2+ messages in thread
From: Katsumi Yamaoka @ 2005-09-02 11:04 UTC (permalink / raw)
[-- Attachment #1: Type: text/plain, Size: 264 bytes --]
Hi,
I'm using the latest Emacs CVS, `font-lock-support-mode' is set
to `jit-lock-mode' (it is the default).
Recently I noticed MIME parts displayed inline in the Gnus
article buffer aren't font-lock'ed. For instance:
(The following line should be fontified.)
[-- Attachment #2: Type: application/emacs-lisp, Size: 21 bytes --]
[-- Attachment #3: Type: text/plain, Size: 187 bytes --]
I was unable to find the cause so far, but font-lock seems to
work only when the buffer is visible. So, I made a patch for a
makeshift.
(The following part should also be fontified.)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: Type: text/x-patch, Size: 605 bytes --]
--- mm-view.el~ 2005-08-28 21:51:06 +0000
+++ mm-view.el 2005-09-02 11:03:24 +0000
@@ -497,7 +497,11 @@
(funcall mode))
(let ((font-lock-verbose nil))
;; I find font-lock a bit too verbose.
- (font-lock-fontify-buffer))
+ ;; FIXME: font-lock seems to work only when the buffer is visible.
+ (save-window-excursion
+ (set-window-buffer (selected-window) (current-buffer))
+ (sit-for 0)
+ (font-lock-fontify-buffer)))
;; By default, XEmacs font-lock uses non-duplicable text
;; properties. This code forces all the text properties
;; to be copied along with the text.
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: font-lock doesn't work on MIME parts
2005-09-02 11:04 font-lock doesn't work on MIME parts Katsumi Yamaoka
@ 2005-09-06 5:22 ` Katsumi Yamaoka
0 siblings, 0 replies; 2+ messages in thread
From: Katsumi Yamaoka @ 2005-09-06 5:22 UTC (permalink / raw)
>>>>> In <b4mslwn91d9.fsf@jpl.org> Katsumi Yamaoka wrote:
> I'm using the latest Emacs CVS, `font-lock-support-mode' is set
> to `jit-lock-mode' (it is the default).
> Recently I noticed MIME parts displayed inline in the Gnus
> article buffer aren't font-lock'ed. For instance:
Solved.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-09-06 5:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-09-02 11:04 font-lock doesn't work on MIME parts Katsumi Yamaoka
2005-09-06 5:22 ` Katsumi Yamaoka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).