Super and Subscripts

Eric Miller (
Sun, 15 Jan 95 17:25:46 EST

OCLC has just completed WWW access to American Institute of
Physic's APLO Journal (12083 SGML to HTML) via our Z39.50-http server.
(sample at <>).
Regarding scholarly publishing in HTML, by far the most significant
contribution for the least amount of development is the implementation of
super and subscripts. Super and subscripts have been targeted
as a HTML 2.1 spec addition. I'd like to open the discussion here
to the addition and implementation of these tags.

The 12083 SGML DTD defines super (sup=superior) and
subscripts (inf=inferior) as follows. (note: I left out
12083 embellishments for 9 position capabilities
(i.e. top, middle, bottom) in order to keep this DTD addition
relative small... point of discussion?)

<! ATTLIST sup location (pre | post) post -->
arrange (compact | stagger)
compact >
<! ATTLIST inf location (pre | post) post -->
arrange (compact | stagger)
compact >

Ideally, I would like to see a generalized implementation of these
element-name-value combinations... however, while fairly easy on the
spec side (just insert DTD :), this is not so easy to implement.
In light of this fact I'd like to offer a possible prioritized list.

1) Basic super and subscripts... vertical adjustment based on baseline
ex: X<sup>2</sup>, Y<sub>2</sup>

2) Composite super and subscripts... both super and subscript on the same
character target. Super and subscripts are aligned vertically, adjacent to
the target character.
ex: X<sup>2</sup><sub>n</sub>

3) Composite super and subscripts with entities or images... same as
above with images.
ex: X<sup><img src = "alpha.gif"></sup><sub><img src = "beta.gif"></sub>

4) Super and subscript with location attribute
ex: C<sup location=pre>13</sup>
(note: this is the letter 'C' with the number 13 superscripted
before the character)

5) Super and subscript with the arrange attribute
... don't see this as a major focus... comments?

Now... a point outside of the HTML specification but rather on client side
implementation (this bit me on the X-window "on-the-fly" SGML formatter
I wrote for the CORE project...) There is an implied non-breaking space
for super and subscripts. Given the capabilities of window width and
point resizing the unpleasant possibility arises with line breaks along
these tags... as an example:

"... and given the equation X<sup>n</> + Y<sup>n</> = Z
<sup>n</> we will show..."

In the electronic display of information there are areas where you do not
use &nbsp; and yet non-breaking space is implied... this would be one of them.

eric miller OCLC, Online Computer Library Center, Inc. Dept. of Geography, The Ohio State University