From murdoch at stats.uwo.ca  Sun Sep  9 18:26:42 2007
From: murdoch at stats.uwo.ca (Duncan Murdoch)
Date: Sun, 09 Sep 2007 12:26:42 -0400
Subject: [Rd] format text help pages Windows
In-Reply-To: <46E416EF.6030600@telenet.be>
References: <46E416EF.6030600@telenet.be>
Message-ID: <46E41EC2.8030802@stats.uwo.ca>

On 09/09/2007 11:53 AM, Tobias Verbeke wrote:
> Dear list,
> 
> Could someone enlighten me a bit on the
> exact format used for text help pages
> as I see them on Windows in the help/
> folders of (compiled) package roots.
> 
> When opening an example of these files
> in a text editor (?Bessel in GNU emacs),
> the file is displayed as follows:
> 
> 
> _^HB_^He_^Hs_^Hs_^He_^Hl_^H _^HF_^Hu_^Hn_^Hc_^Ht_^Hi_^Ho_^Hn_^Hs
> 
> Bessel                 package:base                 R Documentation
> 
> _^HB_^He_^Hs_^Hs_^He_^Hl_^H _^HF_^Hu_^Hn_^Hc_^Ht_^Hi_^Ho_^Hn_^Hs
> 
> 
> _^HD_^He_^Hs_^Hc_^Hr_^Hi_^Hp_^Ht_^Hi_^Ho_^Hn:
> 
> 
>       Bessel Functions of integer and fractional order, of first and
>       second kind, J(nu) and Y(nu), and Modified Bessel functions (of
>       first and third kind), I(nu) and K(nu).
> 
> [....]
> 
> How should other applications handle these files ? Running Rterm as
> a console within eclipse, e.g., now displays ^H as small rectangles
> and leaves the underscores while R itself (Rgui to be precise) and
> ESS nicely display help pages with some formatting (color code for
> Rgui and underlining in an ESS help buffer).

^H is the backspace character, so what you're seeing would be displayed 
as underlined text on a teletype.

I'd suggest that other applications should try not to work with these 
files at all.  You're better off working with the .html files in the 
html folder, because they have cross references, etc.  Only work with 
the contents of the help folder if you are limited in what you can display.

Duncan Murdoch



[Rd] format text help pages Windows
Duncan Murdoch