FrameMaker as a Global Hypertext Tool | cern archive | HTTP only
home archive home about
I have just completed the first steps in integrating FrameMaker and the World Wide Web. You can now create, read, modify, and write web documents using FrameMaker. Soon, you should be able to use FrameMaker as a global hypertext browser. FrameMaker supports an and an integrated conversion facility. See p. D-16 of for full documentation. Basically, whenever you open or save a file (in MIF format), if the filename matches a suffix list, Frame invokes a shell script that can convert the file on the fly. I modified the supplied to convert MIF files saved with the .html extension to HTML. The xlisp program does the whole conversion. FrameMaker supports hypertext references using markers with MType=8 (Hypertext in the dialog box.) The active text is everyting from the marker to the next font change before and after the marker. which are translated to anchor start tags of the form: The syntax of newlink is which I translated to The syntax of message is which, if clientname is www, I translated to The catch is that you have to put the hypertext marker at the beginning of the anchor text. If you put it in the middle, Frame will recoginze the whole anchor, but these tools will only recognize the text between the marker and the next font change. to The result is that target anchors are generally lost on input. This should be fixed shortly. The www_and_frame.tar.Z file will be available via anonymous ftp shortly from info.cern.ch in the pub/WWW/src directory. should properly install the package in a directory called .fminit2.0. Grab export.lcs.mit.edu:/contrib/winterp/xlisp/xlisp-2.1.almy.tar.Z via anonymous FTP. Then apply the patches in diffs_from_almy21. These patches prevent xlisp from writing diagnostics to stdout where they will be mixed in with conversion output. Grab ifi.uio.no:/pub/SGML/SGMLS/sgmls-0.8.tar or ftp.uu.net:/pub/text-processing/sgml/sgmls-0.8.tar.Z Be sure you have the following requirements met first: Then start FrameMaker, chose open from the File menu and select test.html. FrameMaker will consult the suffixes file, and upon finding the html entry, it will run MifRead. MifRead will invoke fix-html.pl to bring test.html into SGML conformance. Then it will invoke sgmls to parse the file, and html2mml.l to convert the parsed SGML to Maker Markup Language. Finally, mmltomif is invoked to build an importable file. When you want to save the file, be sure these requirements are met: Then just chose Save As... and be sure the extension is .html. Click the Maker Interchange Format option, and click OK. Frame will invoke MifWrite, which will invoke the mif2html.l lisp program. For the functionality that I implemented, no changes to the WWW code are necessary. HTML files and programs that generate HTML do require changes. The documentation for FrameMaker includes Integrating Applications with FrameMaker, which desciribes a mechanism where arbitrary RPC clients can be invoked from hypertext commands. could make an RCP call to a WWW client that would retrieve the indicated document and instruct FrameMaker to display that file.

WWW Meets FrameMaker

Daniel W. Connolly <connolly@convex.com>

Theory of Operation

interchange formatFrameMaker Reference

Reading HTML

I modified the supplied script to recognize HTML. Files ending with .html are filtered them through , which brings conventional HTML files into SGML conformance. Then sgmls parses the file using . (sgmls does a pretty good job of tolerating errors in SGML instances.)

MifReadfix-html.plhtml.dtd

Then and the xlisp interpreter convert the sgmls output to Maker Markup Language. Finally, MifRead calls FrameUs mmltomif to generate the MIF file that FrameMaker will read.

html2mml.l

Writing HTML

MifWritemif2html.l

Hypertext Constructs in Frame and WWW

Associated with the marker is a text string. FrameMaker defines a set of hypertext commands. See p. 3-8 of for details.

FrameMaker Reference

Three of the commands are supported by the www_and_frame package: gotolink, newlink, and message.

The syntax of gotolink is

gotolink filename:linkspec

  gotolink linkspec
  

  gotolink filename:firstpage
  

  


  
  

  
  

  
  

newlink linkspec

  


  
  

message clientname string

  


  
  

The inverse translations arenUt as fully functional. They currently map


  
  

message www h

  

Installation

The www_and_frame package

The command

zcat www_and_frame.tar.Z | tar xvf -

  

The LISP interpreter: xlisp by David Betz

Then build it using the included directions. You may have to tweak it a little for your system.

IUd like to make this package a little more ANSI/POSIX conformant if I get time. But for now, youUll have to do the typical Makefile editing.

The SGML parser: sgmls by James Clark

This package is extremely high quality. It includes a configure shell script, and it is largely ANSI/POSIX compliant. It builds without modification on all the systems IUve tried.

Try It Out!

Load the test file into FrameMaker

  1. The .fminit2.0 directory from the www_and_frame package is in the current directory or in your home directory.
  2. The suffixes file in that directory has an entry for html.
  3. The MifRead shell script in the fminit directory checks for html processing.
  4. The fix-html.pl perl script is executable and in your $PATH.
  5. The sgmls parser is executable and in your $PATH.
  6. The html.dtd file is in the current directory or accessible via the SGML_PATH envariable. (See the sgmls man page for details.)
  7. The html2mml.l lisp program is in the current directory.
  8. You should be able to edit the file normally. Use only the paragraph tags in the catalog. You can, however, change any attributes of those tags.

    You can add hypertext links by adding FrameMaker hypertext markers. For the marker text, the "gotolink foo:bar" and "newlink bar" syntaxes are supported. Plus, use "message www scheme://host/path#anchor" for full WWW addresses.

    You will have to lock the file to use the hypertext links interactively. (use ESC-F-l-k to lock/unlock the file.)

    Save the test file in HTML format

    1. The MifWrite shell script is in the .fminit directory and checks for html processing.
    2. The xlisp interpreter is executable and in your $PATH.
    3. The mif2html.l lisp program is in the .fminit2.0 directory.
    4. The resulting file should be acceptable to the www browsers.

      Updates to the HTML DTD

      The FrameMaker integration is based on the premise that WWW will become an SGML compliant application. I am using with some modifications to closely parallel HTML.c from the distributed code. I also consulted .

      the DTD that I proposed recentlythe proposed HTML2 definition

      The script should bring most existing HTML files into compliance.

      fix-html.pl

      Future Directions

      That is, the incantation

      message www http://info.cern.ch/hypertext/WWW/MarkUp/HTML2.html
      
        

      This would turn FrameMaker into a global hypertext browser.

      To Do

      • Sometimes FrameMaker hides the paragraph tag in with the paragraph formatting in the MIF file. mif2html.l fails to recognize this situation. Hence the bogus </NIL> tag at the beginning of documents.
      • Names of anchors are lost on conversion to MIF. This is just laziness.
      • I didnUt convert FrameUs extended ASCII character set to anything sensible. Quotes will look funny.
      • Traditionally, SGML systems verify documents on input and assume validity on input. This system does the reverse. I should verify output documents.
      • I once had a keyboard macro rigged up for saving as MIF. ItUs kind of a pain to make about five clicks every time you want to save.
      • Bibliography

        MIF
        MIF ReferenceFrame Technology Corporation1010 Rincon CircleSan Jose, California 95131Part Number 41-01037-00April 1991
        FrameMaker Reference
        FrameMaker ReferenceFrame Technology Corporation1010 Rincon CircleSan Jose, California 95131Part Number 41-00524-00Septermber 1990