summaryrefslogtreecommitdiff
path: root/chess-pgn.el
diff options
context:
space:
mode:
Diffstat (limited to 'chess-pgn.el')
-rw-r--r--chess-pgn.el7
1 files changed, 7 insertions, 0 deletions
diff --git a/chess-pgn.el b/chess-pgn.el
index a7433e0..10e71e0 100644
--- a/chess-pgn.el
+++ b/chess-pgn.el
@@ -198,6 +198,13 @@ If INDENTED is non-nil, indent the move texts."
;;;###autoload
(add-to-list 'auto-mode-alist '("\\.pgn\\'" . chess-pgn-mode))
+(eval-after-load "mm-decode"
+ '(unless (fboundp 'mm-display-pgn-inline)
+ (defun mm-display-pgn-inline (handle)
+ (mm-display-inline-fontify handle 'chess-pgn-mode))
+ (push ("application/x-chess-pgn" mm-display-pgn-inline identity)
+ mm-inline-media-tests)))
+
(defun chess-pgn-move ()
"Make a move from a PGN buffer."
(interactive)