<!-- \nul;
\nul;
\nul;
 -->
<!DOCTYPE article SYSTEM "gellmu.dtd"><article stem="mui">
<baseloc>http:<sol/><sol/>www.albany.edu<sol/><tld/>hammond<sol/>gellmu<sol/>mui<sol/></baseloc>
<date>October 22, 1999<brk0>
     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/><hyp/>30bp<rbr/></latexcommand>
<latexcommand><bsl/>setlength<lbr/><bsl/>textheight<rbr/><lbr/>696bp<rbr/></latexcommand>
<nobanner> <cs0/>
<nobaseprint> <cs0/>
<cw0/>

<body>

<section>The Value of a <latex/><hyp/>Like Markup User Interface
         for <abbr>XML</abbr></section>
<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>
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>
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>
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>
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>
Please allow me to say a bit more about what I have in mind for
<abbr>GELLMU</abbr><eos/>

<section>The Basic <abbr>GELLMU</abbr> Processing Design</section>
<parb>
The things that I have on hand, aside from <latex/> are:

<enumerate>

<item>  <abbr>GNU</abbr> Emacs, version 20<eos/>  (I believe that version 19 is OK.)

<item>  James Clark's <quostr>nsgmls</quostr>, a part of his <quostr>SP</quostr><eos/>

</enumerate>
<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.)

<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>
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>
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>
The validating parse traps errors in language use<eos/>

<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/>

<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>
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>
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>
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.)

</defnlist>

<section>About this document</section>
<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:<sol/><sol/>www.albany.edu<sol/><tld/>hammond<sol/>gellmu<sol/>mui<sol/></urlanch></display>
along with a full list of anchored versions as follows:
<menu>
<item> <abbr>GELLMU</abbr> source: <urlanch>mui.glm</urlanch><eos/>
<item> <abbr>SGML</abbr>, <quophrase>article</quophrase> document type: <urlanch>mui.sgml</urlanch><eos/>
<item> <abbr>XML</abbr>, <quophrase>article</quophrase> document type: <urlanch>mui.xml</urlanch><eos/>
<item> formatting in <latex/>: <urlanch>mui.ltx</urlanch><eos/>
<item> <abbr>DVI</abbr> made from <latex/>: <urlanch>mui.dvi</urlanch><eos/>
<item> <abbr>PDF</abbr> made from <latex/>: <urlanch>mui.pdf</urlanch><eos/>
<item> formatting in <abbr>HTML</abbr>: <urlanch>mui.html</urlanch><eos/>
</menu>

</body>
</article><!-- GELLMU version 0.7.4.2 (05-Jan-2006) -->
