xproc / Vnext

Assembly point for all issues for a next version of XProc
1 stars 0 forks source link

Too strong on exclude-inline-prefixes? #55

Open xatapult opened 3 weeks ago

xatapult commented 3 weeks ago

The standard reads about the exclude-inline-prefixes attribute:

The value of the attribute is either #all, or a whitespace-separated list of tokens,

This seems to forbid that exclude-inline-prefixes can be empty (exclude-inline-prefixes="").

Unfortunately, I ran into a use-case where on the root it declared exclude-inline-prefixes="#all" and on a deeper level I wanted locally to revert to excluding no prefixes. I couldn't do that and I don't see a reason why not.

Maybe this is VNext issue, but it seems like a non-breaking change if we do 3.1 anyway.

ndw commented 3 weeks ago

It's worse than that, even if you could specify "", it wouldn't do what you want, because:

In other words, the effect of several exclude-inline-prefixes attributes among the ancestors of p:inline is cumulative.

It isn't the most recent ancestor [p:]exclude-inline-prefixes attribute that matters, it's the union of all the ancestors.

On the one hand, we could certainly make it possible to "add them back in", but on the other, it seems like the pipeline could be rewritten so it didn't put #all at the top if that doesn't do the right thing.

xatapult commented 3 weeks ago

Hmm. Very inconvenient.

Add a exclude-inline-prefixes="#none" that "resets" this?

Ok, definitely a VNext issue