Re: Should we take CSS into consideration? (was: Re: attribute or CSS property?)

Hey,
if we do as proposed, think about this example:

<div style="display:none;">
  <div contenteditable=true>
    Hello <span style="display:none">Austria</span>!
  </div>
</div>


If I understand you right, you want to ignore the outer display:none for
editing purposes, but respect the inner one?

I can see how that may be practical for certain purposes, but correct me if
I'm wrong, it seems like until now there was only one level something could
be display:none. Now if we choose to go this route, we will have several
layers.

We could even go further:

<div style="display:none;">
  <div contenteditable=true>
    Hello <span style="display:none"><span
contenteditable=true>Austria</span></span>!
  </div>
</div>


Now we would have two (offscreen) contenteditable areas, one within the
other, but the outer one will ignore the inner one when it comes to caret
movement, while the inner one is self-contained. I can see how that could
come in handy for some things.

How about CSS specs? It seems at least the definition of display:none would
need to be amended slightly:
http://www.w3.org/TR/CSS2/visuren.html#display-prop

"none: This value causes an element to not appear in the formatting
structure (i.e., in visual media the element generates no boxes and has no
effect on layout). Descendant elements do not generate any boxes either;
the element and its content are removed from the formatting structure
entirely. This behavior cannot be overridden by setting the 'display'
property on the descendants.

Please note that a display of 'none' does not create an invisible box; it
creates no box at all. CSS includes mechanisms that enable an element to
generate boxes in the formatting structure that affect formatting but are
not visible themselves. Please consult the section on visibility for
details."

-- 
Johannes Wilm
Fidus Writer
http://www.fiduswriter.org

Received on Monday, 15 December 2014 22:11:34 UTC