Re: How to display/edit attributes inline
Christian Stocker <[email protected]> Wed, 26 May 2004 16:32:01 +0200
| Newsgroups | gmane.editors.bitflux.general |
|---|---|
| Message-ID | <[email protected]> |
On 26.5.2004 16:15 Uhr, Nick Mangine wrote: > I am looking into the feasibility of using BXE as an editor for EAD > (http://www.loc.gov/ead/). This is a fairly complex XML Schema used for > Archival Description. I've run into two problems and they both involve > attributes and how to display them: > > 1. Given the following tag: > > <container id="MC233.7" type="box">7</container> > > I need to display "Box MC233.7". As you can see, the text within the > tag is not important, it's the attributes that need to be displayed and > edited. mmmh. not really possible right now, and I don't know an easy solution just yet. Maybe I'll have one later ;) One solution would be to use a bxe_xpath like "container/@id", but I doubt, that it will work right now. Another question? Does it have to be editable? (I assume so...), otherwise displaying it could be done with css. With this http://www.w3.org/TR/REC-CSS2/selector.html#before-and-after and this http://www.w3.org/TR/REC-CSS2/generate.html#content > > > 2. A common technique within this schema is to place display information > within the attributes. For example, the following two tags need to be > displayed bold and underlined respectively: > > <title render="bold">Title of Book</title> > <title render="underline">Another Title</title> > should be possible: http://www.w3.org/TR/REC-CSS2/selector.html#attribute-selectors > I don't see a way to do either of these things using CSS. So my next > thought was to use xsl to transform them to: > > <container> > <type>box</type> > <id>MC233.7</id> > 7 > </container> > > and: > > <title> > <renderBold> > Title of Book > </renderBold> > </title> > <title> > <renderUnderline> > Another Title > </renderUnderline> > </title> > > I remember seeing something about "transformxml.xsl". Could I do this > transformation there? Is that the best solution? Is there a way to do > this without mucking up the XML schema? Because that defeats the > purpose of an XML editor. The whole xslt transformation stuff is currently not really maintained and works only soso... Is planned for a later release and when we have the resources for doing that. Hope that helps and if you have any further questions, just ask chregu > > Thanks for your help. > -- christian stocker | Bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71 http://www.bitflux.ch | [email protected] | gnupg-keyid 0x5CE1DECB -- bx-editor-users mailing list [email protected] http://lists.bitflux.ch/cgi-bin/listinfo/bx-editor-users