From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Stefan Newsgroups: gmane.emacs.devel Subject: Re: Man-fontify-manpage does not handle man, version 1.5o1, ANSI escape sequences Date: Tue, 30 Nov 2004 08:16:36 -0500 Message-ID: References: <16812.12775.164457.262301@zot.electricrain.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1101820633 5216 80.91.229.6 (30 Nov 2004 13:17:13 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 30 Nov 2004 13:17:13 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Nov 30 14:17:09 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CZ7sS-0006K4-00 for ; Tue, 30 Nov 2004 14:17:09 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CZ81u-0003wJ-La for ged-emacs-devel@m.gmane.org; Tue, 30 Nov 2004 08:26:54 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CZ81Z-0003vB-Bw for emacs-devel@gnu.org; Tue, 30 Nov 2004 08:26:33 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CZ81X-0003uT-Mw for emacs-devel@gnu.org; Tue, 30 Nov 2004 08:26:32 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CZ81X-0003uM-8E for emacs-devel@gnu.org; Tue, 30 Nov 2004 08:26:31 -0500 Original-Received: from [206.47.199.166] (helo=simmts8-srv.bellnexxia.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CZ7rx-0005J0-ME for emacs-devel@gnu.org; Tue, 30 Nov 2004 08:16:38 -0500 Original-Received: from empanada.home ([67.71.25.117]) by simmts8-srv.bellnexxia.net (InterMail vM.5.01.06.10 201-253-122-130-110-20040306) with ESMTP id <20041130131637.HASP1623.simmts8-srv.bellnexxia.net@empanada.home>; Tue, 30 Nov 2004 08:16:37 -0500 Original-Received: by empanada.home (Postfix, from userid 502) id 13C9038A090; Tue, 30 Nov 2004 08:16:36 -0500 (EST) Original-To: "Brian D. Carlstrom" In-Reply-To: <16812.12775.164457.262301@zot.electricrain.com> (Brian D. Carlstrom's message of "Tue, 30 Nov 2004 00:40:07 -0800") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/21.3.50 (darwin) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:30534 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:30534 > This patch did not work as is. Here is a list of issues and > fixes/workarounds. I append my new working version at the end. Thanks, I actually reread the code this morning and was about to send a "sorry, I must have been stoned or something". > 2. The numeric (I'm not sure its safe to assume ASCII) character values > need to be changed to the corresponding number. So I changed these expressions > (char-after (match-beginning 2)) > (char-after (match-beginning 1)) > to > (- (char-after (match-beginning 2)) ?0) > (- (char-after (match-beginning 1)) ?0) > I not at all confident in the mutli-byte character set portability of this. There's no multibyte char in sight, so don't worry. Instead of (- ?0) I'd use ?1 ?4 ?7 in the case branches. > (t (error "Unexpeced case")))) This should say "Unexpected internal error" or somesuch, to make it clear that the problem is not that we saw an unexpected sequence (which should not trigger an error but should just be ignored) but that we bumped into a bug in our own code. >> BTW, is it right that bold is turned on with \e[1m and turned off with >> \e[22m? It seems odd that it isn't \e[21m to turn it off or \e[2m to turn >> it on, seeing how the other fit the \e[Nm and \e[2Nm rule. > Yeah I noticed that "almost" rule. Here is the reference I used: Thank you, Stefan