[om] OpenMath and Imaging

Vilya Harvey vilya at nag.co.uk
Tue Sep 28 13:07:23 CEST 1999


Manfred Riem wrote:
> One question about XSL in Java, how is it generally implemented, do I
> get a Canvas, can I select the sub-parts of an given equation. Can I
> move part of an equation on-the-fly?

Now that I've thought about it a bit more, it would seem that XSL is not
so ideally suited to your problem. I'm starting to think that you're
pretty much on the right track with your original suggestion. You could
have a companion file for each of the CDs which contained the presentation
information you need about every symbol in that CD (which is actually the
recommended approach for presentation info, according to the recent drafts
of the OM specification). Calling it a stylesheet language is probably a
bit misleading though. :-)

>From an earlier message:
> The second question I've got is more towards the
> 'stylesheet' language: "What kind of parameters
> should I expect?" So far I've only specified the
> general parameters like
>         1. Font (size, style, color).
>         2. Background
>         3. Abbreviation style.

If you were feeling energetic, you could implement all of the CSS
properties [1]. That's a fairly comprehensive list and you could use a
standard stylesheet format too. I *think* there is at least one freely
available CSS parser, but I could be wrong; if not, writing one shouldn't
be an overly complex task. Implementing all of the properties in your
renderer is a different matter, of course.

If you're not feeling quite *that* energetic, then the list you have is
probably a decent starting point.

One question: in your proposed system, what would be the operator (or
image class or whatever you want to call it) for rendering things in a
function notation, like f(x)? The closest I could see in your list was
this:
> Type 1 operator:
>         renders a 'vector' with begin 'symbol' and
>         end symbol' and (optional) separator 'symbol'
but for a function you also need to render the function name; it would
also be nice if the begin and end symbols were optional (so you can omit
the brackets around the argument to a single parameter function, for
example).

Finally...
Are you sure that the JAI library is what you want to use? When I
responded to your original post, I hadn't made the connection between that
acronym and the Java Advanced Imaging API. I don't see how that provides
the features you would need. Surely the AWT, possibly with some of the
Java 1.2 extensions (java.awt.font, java.awt.geom, etc.), or Swing is more
appropriate?

Hope this is helping...
Vil.
[1] http://www.w3.org/TR/REC-CSS1 and
    http://www.w3.org/TR/REC-CSS2
-- 
Vilya Harvey  <vilya at nag.co.uk>    Wilkinson House  Mob: +44  961 106 505
Computational Mathematics Group   Jordan Hill Road   Wk: +44 1865 511 245
NAG Limited                    Oxford  UK  OX2 8DR  Fax: +44 1865 311 205
--
om at openmath.org  -  general discussion on OpenMath
Post public announcements to om-announce at openmath.org
Automatic list maintenance software at majordomo at openmath.org
Mail om-owner at openmath.org for assistance with any problems



More information about the Om mailing list