From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: dired-man can't deal with compressed pages Date: 22 Feb 2004 08:31:02 +0200 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: <87r7wolz6u.fsf@mail.jurta.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: deer.gmane.org X-Trace: sea.gmane.org 1077431867 23630 80.91.224.253 (22 Feb 2004 06:37:47 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 22 Feb 2004 06:37:47 +0000 (UTC) Cc: jidanni@jidanni.org, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Sun Feb 22 07:37:40 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AunFE-0006cW-00 for ; Sun, 22 Feb 2004 07:37:40 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AunFB-0006m7-00 for ; Sun, 22 Feb 2004 07:37:39 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.30) id 1Aun9R-0005Bq-WC for emacs-devel@quimby.gnus.org; Sun, 22 Feb 2004 01:31:42 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.30) id 1Aun99-0005BZ-DJ for emacs-devel@gnu.org; Sun, 22 Feb 2004 01:31:23 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.30) id 1Aun8d-00058G-PJ for emacs-devel@gnu.org; Sun, 22 Feb 2004 01:31:22 -0500 Original-Received: from [207.232.27.5] (helo=WST0054) by monty-python.gnu.org with asmtp (Exim 4.30) id 1Aun7J-000502-3m; Sun, 22 Feb 2004 01:29:29 -0500 Original-To: Juri Linkov In-reply-to: <87r7wolz6u.fsf@mail.jurta.org> (message from Juri Linkov on Sun, 22 Feb 2004 02:45:13 +0200) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:20107 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:20107 > From: Juri Linkov > Date: Sun, 22 Feb 2004 02:45:13 +0200 > > > From: Dan Jacobson > > To: bug-gnu-emacs@gnu.org > > Date: Sat, 13 Sep 2003 06:45:22 +0800 > > > > dired-man can't deal with resolvconf.8.gz etc. compressed man pages. > > I think this problem can be fixed by invoking man with the -l option > and letting it to handle man files properly instead of calling the > current "nroff -man -h", i.e. to decompress the manual page files, > to format the nroff source more correctly: preprocess it thought tbl, > use correct switches, etc. all what man program does. I'm not sure this is the right way of solving the problem. For starters, the "-l" switch is not portable: most versions of `man' don't support it. And after thinking for a while, I don't see any way of forcing those versions of `man' who don't have "-l" to format a specific file. I presume this is the reason why dired-x runs nroff directly. If the only problem with the current code is that it doesn't support compressed man pages, perhaps we could detect compressed files and decompress them on the fly. As for preprocessors, I don't know. If this is important, we could blindly run the file through all of them, for example, or have a user option to do that. Yet another possible solution is to use functions from woman.el, which IIRC has a special command to format a single file. However, I don't remember how well it supports various preprocessors.