<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/css"
   href="/~hammond/gellmu/gellmuart.css"?>
<!DOCTYPE article
  PUBLIC "-//GNU GPL: William F. Hammond//DTD GELLMU XML 0.7.5//EN"
  "http://www.albany.edu/~hammond/gellmu/xml/xgellmu.dtd" [
<!ENTITY TableOfContentsFile SYSTEM "mui.xcn">
<!ENTITY % ComputedEntitiesFile SYSTEM "mui.xet">
%ComputedEntitiesFile;
]>
<article stem="mui"
><preamble
><baseloc
>http://www.albany.edu/<tld
/>hammond/gellmu/mui/</baseloc><date
>October 22, 1999<brk
/> Last re<hyp
/>processing <today
/></date><author
>William F. Hammond</author><title
>The Idea of a Markup Interface for <abbr
>XML</abbr></title><surtitle
>Univ at Albany: W. F. Hammond: The <abbr
>GELLMU</abbr> Archive</surtitle><nul
/><latexcommand
><bsl
/>setlength<lbr
/><bsl
/>topmargin<rbr
/><lbr
/>-30bp<rbr
/></latexcommand><latexcommand
><bsl
/>setlength<lbr
/><bsl
/>textheight<rbr
/><lbr
/>696bp<rbr
/></latexcommand><nobanner
/><cs0
/><nobaseprint
/><cs0
/><cw0
/></preamble><body
><Section depth="1" seq = "1" sid="1"
><sunit>&SecRef-1;</sunit
><shead
><label lseq="1">SU-1</label
>The Value of a <latex
/><hyp
/>Like Markup User Interface
         for <abbr
>XML</abbr></shead><parb
>A markup user interface (<abbr
>MUI</abbr>) for an <abbr
>XML</abbr> language
(formally <quophrase
><abbr
>XML</abbr> application</quophrase>) is a markup language
that admits a well<hyp
/>defined translation to the <abbr
>XML</abbr> language<eos
/></parb><parb
>Recent discussions in <urlanch
>news:comp.text.tex</urlanch> show that at least
two of us are thinking about <abbr
>MUI</abbr>s for <latex
/><hyp
/>like <abbr
>XML</abbr>
languages<eos
/>  Jonathan Fine has been working on a <emph
>roff</emph><hyp
/>like
<abbr
>MUI</abbr> that he calls <quophrase
>Active TeX</quophrase>, and I have been
working on a <latex
/><hyp
/>like <abbr
>MUI</abbr> that I call <abbr
>GELLMU</abbr><eos
/></parb><parb
>As I use the acronym <abbr
>MUI</abbr>, I do intend it to be reminiscent of
the acronym <abbr
>GUI</abbr> for <quophrase
>graphical user interface</quophrase><eos
/>  Both
<abbr
>GUI</abbr>s and <abbr
>MUI</abbr>s have the intention of making life easier,
or perhaps at least more familiar, for some authors<eos
/>  An <abbr
>MUI</abbr>,
unlike typical <abbr
>GUI</abbr>s, has the possibility of giving the author
full and rigorous control over content<eos
/></parb><parb
>Furthermore, an <abbr
>MUI</abbr> in the style of a pre<hyp
/>existing
non<hyp
/><abbr
>XML</abbr> markup offers a convenient avenue for prototyping a new
<abbr
>XML</abbr> language to model the markup practice in the pre<hyp
/>existing
markup<eos
/></parb><parb
>Beyond that, it offers a route for conversion of legacy archives in
the pre<hyp
/>existing markup to <abbr
>XML</abbr> languages with minimal human
intervention<eos
/></parb><parb
>Please allow me to say a bit more about what I have in mind for
<abbr
>GELLMU</abbr><eos
/>
</parb></Section
><Section depth="1" seq = "2" sid="2"
><sunit>&SecRef-2;</sunit
><shead
><label lseq="2">SU-2</label
>The Basic <abbr
>GELLMU</abbr> Processing Design</shead><parb
>The things that I have on hand, aside from <latex
/> are:

<enumerate
><item
><itembody
><abbr
>GNU</abbr> Emacs, version 20<eos
/>  (I believe that version 19 is OK.)
</itembody></item><item
><itembody
>James Clark's <quostr
>nsgmls</quostr>, a part of his <quostr
>SP</quostr><eos
/>
</itembody></item></enumerate></parb><parb
>My processing set<hyp
/>up is the following:

<defnlist
><term
>Syntactic translation from <latex
/><hyp
/>like markup to <abbr
>SGML</abbr></term><desc
> My Elisp processor, which can
be run interactively in <abbr
>GNU</abbr> Emacs or in batch mode, performs
syntactic translation to convert <latex
/><hyp
/>like markup to an <abbr
>SGML</abbr>
language (formally, application)<eos
/>  The syntactic translator is largely
ignorant of command names<eos
/>  Whatever command names are used become the
names of <abbr
>SGML</abbr> elements<eos
/>  There is a standard way to convert
multiple argument<sol
/>option sequences<eos
/>
<parb
>This processing stage traps syntax errors<eos
/>  (It will fail to detect an
even number of missing <quochar
><dol
/></quochar> characters; but this error will
show in the next stage.)
</parb></desc><term
>Validating parse of the <abbr
>SGML</abbr> language</term><desc
> At the
validation stage the difference between <abbr
>SGML</abbr> and <abbr
>XML</abbr> is
significant if one wants to have <quophrase
>math mode</quophrase> be a global
toggle since that may be modeled robustly only using <abbr
>SGML</abbr>
exclusions<eos
/>
<parb
>A validating parse is made using <quostr
>nsgmls</quostr><eos
/>
Of course, the language definition, i.e., <abbr
>SGML</abbr> application
definition, is crucial<eos
/>  It is contained in an <abbr
>SGML</abbr> declaration
and in an <abbr
>SGML</abbr> document type definition (<abbr
>DTD</abbr>)<eos
/></parb><parb
>The language definition that I am using is the heart of my personal
production system<eos
/>  But I regard it only as didactic in the larger
scheme of things<eos
/>  Others will certainly want things that I do not
want<eos
/></parb><parb
>As far as it goes, it models <latex
/> rather closely in some ways and
rather loosely in other ways<eos
/>  Where it departs from close modeling,
the reason is usually related to having a document structure that is
not print<hyp
/>centric<eos
/></parb><parb
>The validating parse traps errors in language use<eos
/>
</parb></desc><term
>Down<hyp
/>translation to XML</term><desc
> This is done with the program
called <quostr
>sx</quostr> in the family of <quostr
>SP</quostr> processors<eos
/>
<parb
>While it is possible to recover an equivalent <abbr
>SGML</abbr> document
from the down<hyp
/>translated <abbr
>XML</abbr>, it is not possible under the
<abbr
>XML</abbr> umbrella to have as precise a language definition as
under the wider <abbr
>SGML</abbr> umbrella<eos
/>  That said, either form may
be run through a processor that serves to enforce a tighter language
definition<eos
/>
</parb></desc><term
><abbr
>SGML</abbr> processing</term><desc
> This can go anywhere that is sane for the language definition<eos
/>
One can use any programming language, but it helps to have a basic
<abbr
>SGML</abbr> library on hand<eos
/>  I am using David Megginson's
<quostr
>SGMLS.pm</quostr>, a Perl 5 library, and its interface
<quostr
>sgmlspl</quostr><eos
/>
<parb
>In my personal production system I routinely format <abbr
>GELLMU</abbr>
<quophrase
>articles</quophrase> for both <latex
/> and <abbr
>HTML</abbr><eos
/>  Invalid
<abbr
>HTML</abbr> and error messages from <latex
/> represent bugs in my
processors, which I always repair as soon as possible<eos
/>  There may be
box size complaints from <tex
/>; they represent authoring content
errors<eos
/>  These two formatters work either on the <abbr
>SGML</abbr> or the
<abbr
>XML</abbr> version of an article<eos
/></parb><parb
>At present my personal production language definition is not fully
up<hyp
/>to<hyp
/>speed for journal articles nor for translation to
XHTML<hyp
/>with<hyp
/>MathML, but it is serving me well for my classes<eos
/>  It gives
me a sane way to have course handouts and web offerings in a
bullet<hyp
/>proof way from a single source<eos
/>  At this time I simply cannot
assume that more than about a third of my students have easy access to
<abbr
>PDF</abbr> readers<eos
/>  So I feel constrained to give them simple
<abbr
>HTML</abbr> with very limited pseudo<hyp
/>TeX for math<eos
/></parb><parb
>Other formattings for <abbr
>GELLMU</abbr> article that should be possible
include translations to (1) DocBook, (2) TEI, and (3) Texinfo, though
suboptimally so long as math is not available<eos
/>  These are not small
jobs, and I may never undertake any of them<eos
/>  (Any project that
undertakes to format an <abbr
>XML</abbr> language in Texinfo should give
serious consideration first to modeling Texinfo as an <abbr
>XML</abbr><eos
/>
It would also be desirable to minimize Info<sol
/><tex
/> bifurcation in
XTexinfo and to provide math for XTexinfo.)</parb><parb
>If a time arrives when I can assume that three<hyp
/>fourths of my students
have out<hyp
/>of<hyp
/>the<hyp
/>box browsers for XHTML<hyp
/>with<hyp
/>MathML, then I should be
able to format the original <abbr
>GELLMU</abbr> source directly for that <pdash
/>
if by that time I am not able to squeeze it out of carefully<hyp
/>set
LaTeX<hyp
/>4<eos
/>  (I exaggerate somewhat<eos
/>  In principle, I need to provide
some math symbol declarations in the sources, and math symbol
declaration handling is not yet present in my set<hyp
/>up.)
</parb></desc></defnlist>
</parb></Section
><Section depth="1" seq = "3" sid="3"
><sunit>&SecRef-3;</sunit
><shead
><label lseq="3">SU-3</label
>About this document</shead><parb
>This document was prepared as a <abbr
>GELLMU</abbr> <quophrase
>article</quophrase><eos
/>
A copy of the <abbr
>HTML</abbr> version of this document is available
on the web at
<display
><urlanch
>http://www.albany.edu/<tld
/>hammond/gellmu/mui/</urlanch></display>
along with a full list of anchored versions as follows:
<menu
><item
><itembody
><abbr
>GELLMU</abbr> source: <urlanch
>mui.glm</urlanch><eos
/></itembody></item><item
><itembody
><abbr
>SGML</abbr>, <quophrase
>article</quophrase> document type: <urlanch
>mui.sgml</urlanch><eos
/></itembody></item><item
><itembody
><abbr
>XML</abbr>, <quophrase
>article</quophrase> document type: <urlanch
>mui.xml</urlanch><eos
/></itembody></item><item
><itembody
>formatting in <latex
/>: <urlanch
>mui.ltx</urlanch><eos
/></itembody></item><item
><itembody
><abbr
>DVI</abbr> made from <latex
/>: <urlanch
>mui.dvi</urlanch><eos
/></itembody></item><item
><itembody
><abbr
>PDF</abbr> made from <latex
/>: <urlanch
>mui.pdf</urlanch><eos
/></itembody></item><item
><itembody
>formatting in <abbr
>HTML</abbr>: <urlanch
>mui.html</urlanch><eos
/></itembody></item></menu>
</parb></Section
></body
></article>
