From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Werner LEMBERG Newsgroups: gmane.emacs.devel Subject: Re: file variables and man pages with preprocessors Date: Fri, 09 Nov 2007 08:27:38 +0100 (CET) Message-ID: <20071109.082738.184452170.wl@gnu.org> References: <20071108.015442.17599094.wl@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1194593269 15779 80.91.229.12 (9 Nov 2007 07:27:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 9 Nov 2007 07:27:49 +0000 (UTC) Cc: rgm@gnu.org, emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 09 08:27:53 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1IqOHP-0004ES-9x for ged-emacs-devel@m.gmane.org; Fri, 09 Nov 2007 08:27:51 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IqOHD-0006F5-Th for ged-emacs-devel@m.gmane.org; Fri, 09 Nov 2007 02:27:39 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IqOH9-0006Dh-6D for emacs-devel@gnu.org; Fri, 09 Nov 2007 02:27:35 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IqOH4-0006Be-Jn for emacs-devel@gnu.org; Fri, 09 Nov 2007 02:27:34 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IqOH4-0006Bb-GV for emacs-devel@gnu.org; Fri, 09 Nov 2007 02:27:30 -0500 Original-Received: from moutng.kundenserver.de ([212.227.126.186]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IqOGx-0004NB-Kx; Fri, 09 Nov 2007 02:27:23 -0500 Original-Received: from localhost (p54AFBE32.dip0.t-ipconnect.de [84.175.190.50]) by mrelayeu.kundenserver.de (node=mrelayeu8) with ESMTP (Nemesis) id 0ML31I-1IqOGv0duk-0003ph; Fri, 09 Nov 2007 08:27:22 +0100 In-Reply-To: X-Mailer: Mew version 5.2.50 on Emacs 22.0.97.1 / Mule 5.0 (SAKAKI) X-Provags-ID: V01U2FsdGVkX18s0jjT6VNU7JQaTEdQbscJ+1QoeSTE8e0rakN 5IZeq/+6XAtcY++zni6E7yRU8d/yXHehWu2NFBGCJaDhx0r7Yc Ng6QH8lHe3YGmwDI2KbMA== X-detected-kernel: by monty-python.gnu.org: Linux 2.6? (barebone, rare!) 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: news.gmane.org gmane.emacs.devel:82847 Archived-At: > Well, preconv acts as a filter -- as do (almost) all components > in groff -- thus reading something from the `end of a file' (a) > needs a temporary buffer since the input data stream is `stdin' > in most cases and (b) isn't implemented in preconv due to (a). > > I don't understand this. What is preconv, and what does it have to > do with visiting these files in Emacs? `preconv' is a new preprocessor (currently in the CVS of groff only) which converts man pages in any input encoding to something groff can digest. It supports the GNU Emacs convention for coding tags at the beginning of a file but not at the end of a file for the reasons given above. Consider this example of troff.man (omitting some lines for brevity): '\" t .ig troff.man Copyright (C) ... .. . .TH TROFF 1 "2000-10-20" "Groff Version 1.2.3" .SH NAME troff \- the troff processor of the groff text formatting system Here, the first line indicates that the `tbl' preprocessor is needed; and the `man' program will call it due to this line. Now assume that I want to have this man page in, say, German. It how has to start with '\" t .\" -*- coding: latin-1 -*- .ig troff.man Copyright (C) ... .. . .TH TROFF 1 "2000-10-20" "Groff Version 1.2.3" .SH NAME troff \- Der troff-Prozessor des groff-Textformatierungssystems to use latin-1 (or another suitable encoding like utf-8). Opening such a file currently in Emacs doesn't select the proper file encoding. Werner