Re: On the connectors examples - is this intended in the 'use with symbols' example?

On Wed, Nov 12, 2014 at 4:55 AM, Juergen Roethig
<roethig@dhbw-karlsruhe.de> wrote:
> Tab Atkins Jr. wrote:
>>
>> On Sat, Nov 8, 2014 at 12:12 AM, Juergen Roethig
>> <roethig@dhbw-karlsruhe.de> wrote:
>>>
>>> As I just remembered, I would like to add that this is another perfect
>>> example for the sillyness of the precedence of CSS properties over
>>> presentation attribute values. If you now carefully realize all the
>>> negations at the inputs and outputs of the gates via markers at the start
>>> or
>>> end of the respective connectors (lines, polylines, paths, whatever)
>>> given
>>> by presentation attributes "marker-start" and/or "marker-end", one simple
>>> CSS rule
>>> * { marker-start: none; marker-end: none }
>>> (even when given in the user style sheet (!) of someones browser) will
>>> override all those nice negations given in the SVG source code ... you
>>> might
>>> try it by yourself! But this is another topic, the battle "breakage of
>>> useful content by bad design" vs. "breakage of silly content by removing
>>> silly rules" - so far, the latter seems to be a more important issue
>>> which
>>> needs to be avoided in any case.
>>
>>
>> No, if that rule shows up in the user stylesheet, the attribute wins;
>> presentational attributes are placed in the "author" origin, which
>> auto-wins against "user".
>
> Well, we might read what is given in the specification of CSS 2.1:
>  http://www.w3.org/TR/2011/REC-CSS2-20110607/cascade.html#preshint
> "For other languages [i.e. non HTML], all document language-based styling
> [i.e. values given by presentation attributes] must be translated to the
> corresponding CSS and either enter the cascade at the user agent level or,
> as with HTML presentational hints, be treated as author level rules with a
> specificity of zero placed at the start of the author style sheet."
> So, SVG is an "other language", and thus, the values of the presentation
> attributes should be placed in the "user agent level" which auto-loses
> against "user level".

You're misreading that.  It explicitly gives host languages the choice
of which place to put their presentational attributes.

> But if we compare with CSS3 (which is not at all relevant for SVG 1.1, since
> SVG 1.1 explicitly mentions CSS2):

Which spec SVG 1.1 references is irrelevant; browsers follow the
latest standards.

>  http://www.w3.org/TR/css-cascade-3/#preshint
> "All document language-based styling must be translated to corresponding CSS
> rules and either enter the cascade at the user agent level or be treated as
> author level rules with a specificity of zero placed at the start of the
> author style sheet. A document language may define whether a presentational
> hint enters at the UA or author level of the cascade; if so, the UA must
> behave accordingly. For example, [SVG11] maps its presentation attributes
> into the author level."
> This time, we have a "clear" statement saying that the document language
> might specify this or that ;-)

This statement says the exact same thing as the CSS 2.1 text, just
rephrased slightly.

> Independent from that, my opinion on the precedence of presentation
> attributes is that they should have the same priority as values given by
> style attributes - the way of usage is similar for both, as presentation
> attributes are given for specific tags like the style attribute, so all
> those values should override general rules given in an author style sheet.

Like I said, the current placement is for consistency, so that HTML
and SVG presentational attributes work the same way, even if it's not
quite the ideal location for SVG presentational attributes.

>> SVG attributes being classes as "presentational attributes" is just
>> for consistency with HTML, though the two serve different purposes -
>> the placement of HTML presentational attributes in the cascade is
>> purposeful, as they're a legacy feature that shouldn't be used, which
>> isn't true of SVG's presentational attributes, but consistency was
>> deemed more important than coming up with something slightly more
>> sensible; you can always use the style attribute to specify styles at
>> a higher point in the cascade than author rules.
>
> And the proclaimed "consistency" is falsified by the given statement from
> the CSS 2.1 spec, since HTML is mentioned as an _exception_ to all the other
> languages, placing presentational hints at author level instead of user
> agent level. That's a perfect inconsistency ... as well as the inconsistency
> of the various specs on that topic.

No it's not.  It's given as an example, not an exception. I'm not sure
how you're reading it as such.

> Btw, someone named "Tab Atkins Jr. (Google, Inc.)" is listed in that CSS2.1
> specification from above as a "Working Group member[s] active during the
> development of this specification". I am so glad that even those "experts"
> who are responsible for the deliverables do not know the content of their
> own specs ;-)

This is inappropriate.

~TJ

Received on Wednesday, 12 November 2014 20:24:48 UTC