From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/38017 Path: main.gmane.org!not-for-mail From: pinard@iro.umontreal.ca (=?iso-8859-1?q?Fran=E7ois?= Pinard) Newsgroups: gmane.emacs.gnus.general Subject: Re: w3-mode, gnus & emacs21. Date: 19 Aug 2001 10:58:46 -0400 Sender: pinard@carouge.sram.qc.ca Message-ID: References: NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: main.gmane.org 1035173666 18563 80.91.224.250 (21 Oct 2002 04:14:26 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 21 Oct 2002 04:14:26 +0000 (UTC) Cc: ding@gnus.org Return-Path: Return-Path: Original-Received: (qmail 16943 invoked from network); 19 Aug 2001 14:53:49 -0000 Original-Received: from lin2.sram.qc.ca (HELO carouge.sram.qc.ca) (postfix@207.35.30.105) by gnus.org with SMTP; 19 Aug 2001 14:53:49 -0000 Original-Received: by carouge.sram.qc.ca (Postfix, from userid 405) id 462EB2E4A8; Sun, 19 Aug 2001 10:58:46 -0400 (EDT) Original-To: Mattias Ahnberg X-Face: "b_m|CE6#'Q8fliQrwHl9K,]PA_o'*S~Dva{~b1n*)K*A(BIwQW.:LY?t4~xhYka_.LV?Qq `}X|71X0ea&H]9Dsk!`kxBXlG;q$mLfv_vtaHK_rHFKu]4'<*LWCyUe@ZcI6"*wB5M@[m User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.0.104 Original-Lines: 60 Xref: main.gmane.org gmane.emacs.gnus.general:38017 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:38017 [Mattias Ahnberg] > I think I read something about someone playing with emacs21 and > w3-mode together with gnus. I've just started trying to use > emacs21 actively, and so far things work really nice. The only > thing that I can't get to work is w3-mode. > Someone had any tips/pointers on that one? I really miss the > functionality it adds to gnus. I started to use `w3m', which is an external C formatter, small, fast and capable, and linked it to Gnus rather satisfactorily, for my needs at least. Let me see... Hmph! Not very elegant, but here is what I got to add to my ".gnus" file so it works. I wish Gnus offered some kind of hooks for this... (setq fp-lynx-path (executable-find "lynx") fp-w3m-path (executable-find "w3m")) (when (or fp-lynx-path fp-w3m-path) (eval-after-load "gnus-art" '(defun article-wash-html () "Format an html article." (interactive) (save-excursion (let ((buffer-read-only nil) charset) (if (gnus-buffer-live-p gnus-original-article-buffer) (with-current-buffer gnus-original-article-buffer (let* ((ct (gnus-fetch-field "content-type")) (ctl (and ct (ignore-errors (mail-header-parse-content-type ct))))) (setq charset (and ctl (mail-content-type-get ctl 'charset))) (if (stringp charset) (setq charset (intern (downcase charset))))))) (unless charset (setq charset gnus-newsgroup-charset)) (article-goto-body) (save-window-excursion (shell-command-on-region (point) (point-max) (cond (fp-w3m-path (concat fp-w3m-path " -T text/html")) (fp-lynx-path (concat fp-lynx-path " -dump /dev/fd/0"))) t t))))))) About `w3m', I have the following references: Akinori Ito http://ei5nazha.yz.yamagata-u.ac.jp/~aito/w3m/eng/ I also found it bundled on the SuSE CD-roms, in case you have them, but do not know for other Linux distributions. -- François Pinard http://www.iro.umontreal.ca/~pinard