next up previous
Next: Correcting Equation Parsing Errors Up: A Pen Based Formula Previous: Modify Characters

Parsing and Preview

When the user selects the menu option to parse the formula, the system pops up a window that shows the workings of the parser as it attempts to process the formula. The parsing can be cancelled by the user at any point.


  
Figure 4.8: A formula being processed.
\includegraphics[width=0.95\linewidth]{figures/processing.eps}

Figure 4.8 is a screenshot of the system part-way through processing a formula. This is the same formula as shown in Figure 4.2. In the screenshot you can see the graph rewriting formula processor displaying its current graph. As the parsing proceeds this graph is updated. This graph was primarily intended as a debugging aid and is of little use to most users of the system. However, someone who understands how the system works can use it to diagnose why their formula may be taking a long time to parse, causing erroneous parsing, or causing the parser to be unable to parse the formula at all.

Once the formula has been parsed and a LATEX string generated for it, external tools are used to generate a preview image which is then displayed. While the parsing at times can be quick, less than a second for small formulae, the preview generation is currently slow: taking eight to ten seconds per formula.


  
Figure 4.9: The LATEX preview window.
\includegraphics[scale=0.5]{figures/latex_preview_window.eps}

Figure 4.9 shows the window that appears after the preview is generated. The LATEX command string at the top of the window is in a text entry area and can be copied and pasted into the user's LATEX document. The user is also able to edit this command string and press the redo preview button. This regenerates the preview for the new, edited, command string. However, editing in this field does not change the formula entered in the main pen-based formula editor. This facility is provided for the user if they wish to make small changes and quickly check their effects.

Should the parser be unable to process the formula successfully, it indicates to the user what the best parse found was. This is described in Section 4.3.8.


next up previous
Next: Correcting Equation Parsing Errors Up: A Pen Based Formula Previous: Modify Characters
Steve Smithies
1999-11-13