groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] tbl for html?


From: Gaius Mulley
Subject: Re: [Groff] tbl for html?
Date: 02 Mar 2007 18:21:19 +0000
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4

Bill Ward <address@hidden> writes:

> Hello,
> 
> The html feature of groff does a great job for me with respect to turning
> equations and tables into images for display on web pages.  Unfortunately,
> my webmaster has pointed out to me that the "Americans with Disabilities
> Act" suggests (mandates) that web pages be text where possible so that
> various text to voice programs can translate web pages for blind users.
> Tables formatted as images defeat these programs.
> 
> Three questions:
> 
> 1. Does anyone have a satisfactory version of tbl that will work with groff
> and produce html tables?

Hi Bill,

not yet.  It has been on my todo list for sometime but the Act above
has just propelled it right to the top of my coding list.


> 2. Failing 1, if I wrote my own (limited in scope) tool to do this, how can
> I convince groff to call my tool when -Thtml is specified instead of regular
> tbl, preferably without explicitly writing out the entire tool pipeline
> myself (yuck).  

the quickest way is to write a `tbl' replacement, put it in a local
directory, alter your path and run groff -t -Thtml etc etc.

> 3. More generally, is there a way for me to create my own troff preprocessor
> program and specify some option to groff so that groff will call my filter
> program?

aside from the obvious pipeline solution, afraid not..

   soelim filename.ms | mypreproc | groff etc etc

I suspect it should be possible to modify groff to handle this.  It
becomes slightly more complex with -Thtml as the pipeline is run twice
and it could depend on whether you want the preprocessor to run after
the initial soelim (as above) or only on, say, the -Thtml component of
the pipeline (rather than the -Tps component).

regards,
Gaius




reply via email to

[Prev in Thread] Current Thread [Next in Thread]