Datapage Professional Typesetting and Prepress Services


 
     
Athena - Specifications
     
     
Athena Platform
   
   
 
Athena PlatformVersion 3 of Athena is a Windows-based application that seamlessly integrates with Microsoft Word. It is compatible with Windows versions 95/98/NT/2000/ME and Word versions 95/98/2000. It requires version 4 of Design Science's equation editor MathType.
   
   
Athena Input/Output
   
   
  Athena Input-Output
   
 

Athena takes as input any format that Word accepts, including: RTF, Word documents, Wordperfect, HTML and plain ASCII. An Athena add-on 'DataTex' translates documents in TeX/LaTeX format into RTF; equations are converted to MathType MTEF data which are translated to MathType equation objects when the resulting RTF document is imported into Athena.

Athena produces a tagged Word document and one or more XML files. If changes are necessary they are made to the tagged Word document and the XML file(s) regenerated.

   
   
Athena comprises eight main components
   
   
  Athena components
   
1 Three Word templates
The four 'Auto' macros in Word's normal.dot are slightly modified; the 'AutoExec' macro is the entry point into Athena. It generates a dialog box giving the user the option to use Word as normal or to load the Athena environment. If the user chooses the latter option Athena's main macros module (2) is loaded. 'AutoOpen' is invoked every time a document is opened in Athena. It presents the user with the main Document Information dialog. Information in this dialog is loaded from a text file 'Publisher.ini'; the user must select the publisher of the current document, after which Athena will configure the environment in accordance with the publisher's DTD using various configuration files. If this dialog is cancelled the document is treated as a normal Word document; otherwise, Athena's primary Word template XML.dot is attached to the document. XML.dot contains custom toolbars, keyboard shortcuts, Word styles and some trivial macros that interface with Athena's main macros module (2). The third template used by Athena is provided by MathType ("MathType Commands for Word XX.dot"); Athena calls the MathType equation conversion macro to translate the equation objects in a document to XML using the MathType translator description file 'Athena.tdl'.
   
2 Main Macros Module
Athena's main macros module is loaded from Word's AutoExec macro. This is a Word add-in library which uses the Word Application Interface (WAPI) to communicate with Word; it is written in the C language. Word automatically calls the 'wdAutoOpen' procedure in this module and this is used to initialise the Word environment: macro functions are registered with Word, short-cut key assignments are established, Toolbars, menus, editing and viewing options are configured according to Athena's preferences. Athena's Dialog boxes module (3) and a module consisting of supplementary macros (4) are loaded at this point.
   
3 Dialog Boxes Module
Almost all of Athena's dialog boxes are contained in one module. This is written in C++ and uses MFC. These dialog boxes give the user access to Athena's macros (the more common of which can be directly accessed with short-cut keys).
   
4 Supplementary Macros Module
Since the WAPI interface is largely tied to Word 7, features specific to later versions of Word are accessed in this module using OLE/ActiveX. This module is written in C++ and uses MFC.
   
5 Document Validation Module
When it comes to validating a tagged Athena document a module dealing with this is loaded for the duration of the validation process; it is written in C. A macro in the main macros module (2) performs some preliminary checks before creating a text file from the tagged document. This text file is passed to this module. A DTD configuration file containing the rules governing the permitted structure of the tagged document is loaded and used to validate the document. This configuration file contains rules that are fairly loosely based on the DTD in use; Athena tries to keep these rules as similar as possible from one DTD to another in order to simplify the tagging process in a multi-DTD environment and shield the user from some of the complexities of XML. If validation against the DTD configuration file is successful this module performs various checks between target objects (Figures/Tables/Bibliography entries) and their cross-references.
   
6 Generic XML Conversion Module
If document validation is successful Athena will generate an XML file. The first step in this process is to generate XML based on Athena's generic tagging system (for example, tables, equations, bibliograpies are all essentially tagged in the same way, regardless of the target DTD): this provides consistent input into Athena's DTD engine. This module is written in C. A macro in the main macros module (2) peforms some preliminary procedures (conversion of footnotes, equations, tables, lists, formatting, etc.) before creating a text file from the tagged Athena document; this text file is then input into this module. The output from this module is then input into Athena's DTD engine (7).
   
7 DTD Engine Module
This module accepts as input the output produced by Athena's Generic XML conversion module (6). This module is written in C and C++; it loads various configuration and translation text files to translate the input into an intermediate output file. A tree structure is then built from this intermediate file and XLISP procedures act on the nodes of the tree to produce the final XML output file. At the start of the conversion process the user can specify a parser/quality tool to be run on the output in order to ensure that the output produced fully conforms to the target DTD. As an alternative to the XLisp approach there is also a perl interface included in Athena which can be used to apply standard XSL stylesheet transformations. Any other XML-related features available in Perl can also be used.
   
8 DTD Engine Interface
Athena comes with a separate stand-alone interface into Athena's DTD engine which can be used to bypass Word and input into the engine the XML output produced by Athena's Generic conversion module (6). This interface can also be used to test configuration files and XLISP procedures, or experiment with the XLISP language itself. This module was written is C++ and uses MFC. With the addition of the Perl interface to Athena's DTD Engine, XSL stylesheet transformations can be tested here before going to production.
 

 

   
 
Call us for typesetting services
Email us for typesetting services
Get a typesetting service quote



The Datapage team consistently provide work of the highest standard. Their prices are competitive and our schedules are never compromised.

Tim Fenton
Agricultural Institute of Canada