Re: XSLT like CSS with media and different styles
Axel Hecht <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.layout.xslt |
|---|---|
| Organization | Another Netscape Collabra Server User |
| Message-ID | <[email protected]> |
Bernd Fuhrmann wrote: > Axel Hecht wrote: > >> This is not implemented, and I don't see us doing it, really. >> >> Note that doing a new transform for printing would nuke all form >> entries in a page, for example, which would be a very unexpected >> behaviour. > > > Yes, this would certainly be difficult. To be honest, I have no idea how > it is currently done (especially handling script-generated content) or > if such a thing could be solved. > >> I'd suggest that you do one transform, and then work with CSS. > > > That is what I was about to do now. But it is sometimes nasty because > you need to have all your structural changes in advance and then select > via display:none and so on which one you want to have. This is not good. > It's also a waste of resources. > >> There is no support for alternative stylesheets on XSLT either. Not >> sure what the specs would say on that. > > > The reason why I thought that it might be possible is this one: > http://www.w3.org/TR/xml-stylesheet/ > > This document says something about an alternative way to use CSS (via > processing instruction). It does not say, however that this is limited > to CSS. There is not much difference to specifying an XSLT stylesheet. > So I thought it would be just logic to have XSLT stylesheets handled in > the same way. It would certainly be useful, because one could change the > actual structure of a document depending on the media. > > Just think you would have a look at a site with your browser > (media=screen) that contains some applet. Then you want to print that > site and get a different document that explains e.g. different states of > that applet, so you wont miss anything important. To have such thing it > would be useful (though not absolutely necessary) to have > media-dependant XSLTs. Given the number of problems wrt the common printing experience, plus the possible workaround by using CSS, I don't think it's worth the hassle. Axel