[whatwg] Mathematics in HTML5
Michel Fortin
michel.fortin at michelf.com
Wed Jun 7 11:16:32 PDT 2006
Le 7 juin 2006 à 12:46, Anne van Kesteren a écrit :
> Quoting Michel Fortin <michel.fortin at michelf.com>:
>> I would also use <f> instead of <formula> (as Juan used in one of his
>> example), because it's shorter and fits well with many other wildly
>> used container elements: <p>, <h1>-<h6>, <ol>, <ul>, <li>, <dl>,
>> <dt>,
>> and <dd>.
>
> This would only work if it would in fact be wildly used. And since
> math doesn't seem to be that wildly used and probably won't ever be
> wildly used I guess a more descriptive name is better to avoid
> potential confusion, imho.
I think you're right on that Anne.
The reason I was suggesting <f> is because, from what I understood of
White's syntax, <formula> would be mandatory around all mathematic
content (hence the mathematical content model). In that case a
<formula> tag would be needed for including things such as a simple
square root in the content: <formula><radical>2</radical></formula>.
As I already stated[1], my preference for including mathematical
content directly in the prose (no required formula tags, no special
content model), I was seeking a lightweight markup compromise, hence
<f>.
[1]: http://listserver.dreamhost.com/pipermail/whatwg-whatwg.org/
2006-June/006514.html
But I also understand White's point of view which I think is that
requiring every variable to be put within its own <var> element would
be worse, that no one would do that anyway, hence the idea of a
special formula "mode" which could understand variables. I still
prefer the <var> approach as it isn't modal, it allows words to be
used as variables (I've seen that in the wild), and because it reuses
an existing element already styled acceptably by current browsers.
I suppose a <formula> element also creates some sort of separation of
mathematics from regular prose (as <code> does for code). I think its
a good idea, but there are times where it's hard to draw the line.
Are simple numbers part of formulas? If not, is <radical>2</radical>,
or <frac><num>1</num><den>2</den></frac>, a formula when it's used in
the middle of the prose as a constant? I don't think so. So I'm in
favor of <formula>, but only when it really designate a formula, as
decided by the author, because of a mathematical context in HTML.
Michel Fortin
michel.fortin at michelf.com
http://www.michelf.com/
More information about the whatwg
mailing list