[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.2 Message mode

It is impossible to display a file to the Message buffer if its data type is not supported by Emacs. Install an external program which converts the data to text and you can display the file to the Message buffer.

If you install "w3m" and "emacs-w3m", Text/Html can be displayed in Message mode. (Please note that multilingualized "w3m", not pure "w3m", is necessary for "wvHtml", "xlhtml", and "ppthtml" described below.) When you install both of them, add the following to "~/.mew.el'.

 
(condition-case nil
    (require 'mew-w3m)
  (file-error nil))

With this, Text/Html can be displayed in Message mode as if it were Text/Plain. Even in this situation, ‘C-cC-e’ described below is a valid operation.

If you install "wvHtml", "xlhtml", and "ppthtml", you can display text parts of WORD, Excel, and PowerPoint file in Message, respectively. Since these commands uses HTML, the configuration of Text/Html above is required. Also, you need to install Mule-UCS for Emacs 21.4 or earlier because UTF-8 (Unicode) is required. With this, a WORD file, for example, can be displayed in Message mode as if it were text.

You can display the file with an external application itself instead of displaying it in the Message buffer. For this, type ‘C-cC-e’.

You can visualize an image file into the Message buffer. Also, you can display it with an external application by typing ‘C-cC-e’, of course.

You can display an HTML file to a browser with ‘C-cC-e’. A default browser is used on Windows and Mac. On Unix, "mozilla" is set to a default browser as follows:

 
(defvar mew-prog-text/html-ext '("mozilla" ("-remote" "openFile(%s)") t))

If you want to set it to "firefox", for example, configure like this:

 
(setq mew-prog-text/html-ext
      '("firefox" ("-a" "firefox" "-remote" "openFile(%s)") t))

You can visualize an Office-family file to each application by typing ‘C-cC-e’. On Windows and Mac, an Office-family application is executed. On Unix, "ooffice" is set to the default application as follows:

 
(defvar mew-prog-msword-ext "ooffice")
(defvar mew-prog-msexcel-ext "ooffice")
(defvar mew-prog-mspowerpoint-ext "ooffice")

If you want to set it to "soffice", for instace, do like this:

 
(setq mew-prog-msword-ext "soffice")
(setq mew-prog-msexcel-ext "soffice")
(setq mew-prog-mspowerpoint-ext "soffice")

If you want to not visualize an Office-family file into the Message buffer, but want to display it with "wvHtml", configure as follows:

 
(setq mew-prog-msword  '(nil mew-mime-application/msword))
(setq mew-prog-msexcel '(nil mew-mime-application/msexcel))
(setq mew-prog-mspowerpoint '(nil mew-mime-application/mspowerpoint))

If you want to specify an application instead of the pre-defined application, type ‘C-uC-cC-e’.

Recently there are many message whose have Multipart/Alternative, which consists of Text/Plain and Text/Html. By default, Mew selects Text/Plain. When you install "emacs-w3m", you may want to choose Text/Html. In this case, add the following to "~/.mew.el". (Now, it's good idea to get back to See section Displaying MIME to review how to use ‘:’.)

 
(setq mew-mime-multipart-alternative-list
      '("Text/Html" "Text/Plain" ".*"))

[ < ] [ > ]   [ << ] [ Up ] [ >> ]

This document was generated by U-X61T\saito on October, 15 2008 using texi2html 1.78.