[Bug 10808] i18n comment 2 : new dir attribute value: auto, and a new attribute: autodirmethod

http://www.w3.org/Bugs/Public/show_bug.cgi?id=10808

Aryeh Gregor <Simetrical+w3cbug@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |Simetrical+w3cbug@gmail.com

--- Comment #12 from Aryeh Gregor <Simetrical+w3cbug@gmail.com> 2010-10-18 18:31:58 UTC ---
Not a duplicate of bug 10807; see bug 10807 comment 16.  They address different
use-cases.  That deals with inline strings of possibly known direction not
changing the directionality of adjacent strings in the same block, while this
deals with blocks of unknown direction inferring the correct direction for
themselves.

I don't like the proposed solution, though:

1) Why would you ever want to not estimate the direction for each paragraph
separately?

2) Does it really make sense to expose the first-strong vs. any-rtl distinction
to authors?  Why not just pick whichever one seems better for the platform?  In
particular, paragraphs are of unbounded length, and the browser might not have
access to the full paragraph before it starts rendering (since it might have
only received part of the page).

any-rtl would force browsers to scan the whole paragraph before rendering,
which is bad.  Or force them to flip directionality as the page is loading/as
the user types, which is worse.  So first-strong is preferable.  Ideally we'd
look beyond the first character, e.g., checking if the first 100 characters are
at least 30% RTL, but that doesn't work well when the user is typing the
content on the fly, since then direction will switch as he types.


So I think just having dir="auto" is the right choice, requiring that it
operate paragraph-by-paragraph (whatever that's defined to mean), and having it
key off the first strong-directionality character in each paragraph.  I'm
ambivalent about whether this should be in CSS or HTML.

I think that when this behavior is defined, we should evaluate where to
activate it by default.  IMO, it would be a big win if this were enabled by
default on all textareas and inputs, at least.  I wonder if it would really
break anything much if it were the default on all elements.  Probably, but
maybe worth trying . . .

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
You reported the bug.

Received on Monday, 18 October 2010 18:32:00 UTC