[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: attribute value templates in elements fetched from
Am 03.09.2020 um 16:24 schrieb Graydon graydon@xxxxxxxxx:
On Wed, Sep 02, 2020 at 10:27:17PM -0000, Martin Honnen martin.honnen@xxxxxxscripsit: I don't understand where you use xsl:evaluate and where you bind the value to $calculated. structural categories. (block, table, inline, link, etc.) That happens via map lookup:
style. There are many more rendering styles than there are structures, but many fewer than input element names; perhaps a hundred. The rendering style is usually but not always a simple mapping between the element name and a style name, and I could -- for at least 80% of the cases -- store that in the same map as element markup if I went from
long term maintenance simpler; the templates and the logic are stable and behaviour gets driven from the map, making it easy to add new elements or change a style.
information that depends on the input element context is required, such as title depth. (title depth = "how many of my ancestors have titles?") This means there's extra/different markup in the style definition and a value that isn't statically derived from the element name. What I want to do is to store the style markup in the map in the same way, and populate it with the specific values somehow after I retrieve it.
element markup back out of a map and put it into evaluation context without having to use transform() and start a whole new process and pass in the whole input document for context anyway. I haven't completely understood it but the third point sounds like you need fn:transform on dynamically constructed or retrieved code. I know you ruled that out in your initial post but I am not sure there is a simpler way.
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|