On Wed, 6 Dec 2006, Cyril Concolato wrote:
>
> In Section 2.6 "The inherited element" and
Section 2.7 "The xbl:inherits
> attribute" use the same root 'inherit' while they
are about different
> behaviors: - "inherited" is related to the
extends attribute and to
> inheritance - "inherits" is related to
attribute forwarding. Please
> rename the second to "forwards" or something
less confusing.
I spoke with David Hyatt about this and we agree that
xbl:inherits
clashing with inherited/extends is a bit confusing. We don't
really like
the idea of calling it 'xbl:forwards', though, because that
is easier to
typo than 'inherits' for some reason. I'd rather have
xbl:inherits and the
resulting minor confusion than xbl:forwards and the
resulting typos.
Do you have any better suggestions for an alternative name?
> Could you explain why the WG prefered specifying the
attribute
> 'inherits' with a specific syntax (difficult) to parse
and not an
> element with sub-elements like the following ?
>
> <forwards>
> <attribute name="[bound element's
attribute]"/>
> <attribute name="xbl:text">some
text</attribute>
> </forwards>
Elements are harder to process (you have to handle erroneous
tree
structures, whitespace nodes, unexpected other nodes, etc),
and
significantly harder to author. Also, in the case of the
shadow tree we
would have to somehow hide the <forwards> elements
from the final
flattened tree, the creation of which is already quite a
confusing
operation. Overall, the parsing of the attribute is less
difficult than
the processing of elements in this situation.
--
Ian Hickson U+1047E
)._.,--....,'``. fL
http://ln.hixie.ch/
U+263A /, _.. _ ;`._ ,.
Things that are impossible just take longer.
`._.-(,_..'--(,_..'`-.;.'
|