Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2005
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Re: Getting a pure text widget?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg61501] Re: Re: Getting a pure text widget?
  • From: "Steven T. Hatton" <hattons at globalsymmetry.com>
  • Date: Thu, 20 Oct 2005 00:56:20 -0400 (EDT)
  • References: <NDBBJGNHKLMPLILOIPPOAEIIELAA.djmp@earthlink.net> <200510170629.CAA16332@smc.vnet.net> <dj27gl$bn6$1@smc.vnet.net> <200510190616.CAA16741@smc.vnet.net> <dj71th$cnv$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Chris Chiasson wrote:

> Steven,
> As far as I know (I'm not an expert by any means), general XML can't
> be rendered (by a browser), even with a DTD or Schema specified. After
> all, the DTD/Schema only specifies the allowable structure of a
> document. One could define CSS styles for something like <BoxData> or
> <Cell> in NotebookML, but the browser still wouldn't know how to
> render these elements.
> 
> That is why there is a transformation file (XSLT file) that will (or
> should, if WRI hasn't made one yet) create XHTML (+ MathML + SVG) from
> the NotebookML, so that it can be viewed with a browser that
> understands this (these three) language(s).
> 
> Corollary: I would be pretty amazed if a browser that didn't have
> native support for SVG could read an SVG DTD and a CSS file and then
> render SVG markup as graphics on the screen.
> 
> As you said, it would be nice to have cascading styles for notebooks,
> XML or not.

This is taken directly from the Mathematica documentation:

"Displaying NotebookML Using CSS

NotebookML can be displayed in many current generation browsers, by using
CSS style sheets. For example, Internet Explorer 5 or later and Netscape 6
or later have built-in support for CSS. CSS can even mimic the behavior of
Mathematica's environments (like Working, Printout, Presentation, and so
forth). To save a notebook as NotebookML with a Cascading Style Sheet, use
the Export function, with a conversion option of "StyleSheets" pointing to
the relevant stylesheet. 

[See documentation for an example]

If you save a notebook as NotebookML and CSS (instead of simply converting
it to HTML), the resulting file can be rendered in a web browser. The
advantage of this approach is that you only need to create a single
document, which can be viewed either in web browsers or in Mathematica. A
non-Mathematica user can view the document in any web browser. But a
Mathematica user will be able to open and edit the document as a notebook,
evaluate the input, manipulate the graphics, and so on."

What the documentation fails to mention is that no CSS is provided with
Mathematica.  It is correct that CSS can be used to render XML without a
need to translate it to html or xhtml.  I've done it for simple XML
documents. There are problems with the CSS support in IE.  There may also
be problems with the support in Mozilla, but I did not encounter any.  

-- 
"Philosophy is written in this grand book, The Universe. ... But the book
cannot be understood unless one first learns to comprehend the language...
in which it is written. It is written in the language of mathematics, ...;
without which wanders about in a dark labyrinth."   The Lion of Gaul


  • Prev by Date: Re: Language vs. Library why it matters / Turing
  • Next by Date: Re: regress versus fit - force through zero/forceconstant term to zero
  • Previous by thread: Re: Re: Getting a pure text widget?
  • Next by thread: Re: Getting a pure text widget?