groff
[Top][All Lists]
Advanced

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

RE: [Groff] Groff editor.


From: Meg McRoberts
Subject: RE: [Groff] Groff editor.
Date: Mon, 20 Aug 2007 11:03:00 -0700 (PDT)

What sort of document is this?  Is it mostly text or are there
a lot of tables, graphics, and such?

I can think of a few ways that one might get the content into
some sort of WYSIWYG editor, but the fancier the formatting,
the less satisfactory these will be:

- Run the text into formatted ASCII then import the formatted text
  into Word or some other editor.  A command similar to the following
  might work:

  groff -mandoc -stC -Tascii <filename>| col -b > <filename>.txt

  This is for man page source -- replace -mandoc with the appropriate
  string if the document is using a different set of macros.

  You will loose all bold/italic and lots of other stuff but it will
  get you text that does not show the formatting characters.

- Run the text into PDF and then try a PDF editor.  I know that Broderbund
  is selling such an editor but I haven't used it.  The following commands
  will create PDF from a groff file (these are the commands I use -- perhaps
  someone will have a more elegant method) -- note that you have to create
  a PostScript file and then convert the ps file to PDF:

  groff -mandoc -st <filename> > <filename>.ps
  ps2pdf <filename>.ps <filename>.pdf

- Convert the groff code to Docbook/XML; editors like you want are available
  for XML.  Here is some information about a tool that does this:

  http://www.xmlhack.com/read.php?item=1749

These are not perfect solutions but would allow you to capture the text
into a format that can be maintained without learning groff.  

meg






reply via email to

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