[whatwg] Spellchecking mark III

Mikko Rantalainen mikko.rantalainen at peda.net
Wed Jan 21 03:03:20 PST 2009


James Graham wrote:
> Mikko Rantalainen wrote:
>> My second sentence was trying to argument that page author has no
>> business forcing the spellchecking on if the page author cannot force
>> the spellchecking language! Especially for a case where the page
>> contains a mix of multiple languages.
> 
> Not really. Consider e.g. flickr in which photos may be given titles, 
> descriptions and comments in the language of the user's choice but the 
> site UI is not localised. If flickr decided to do <input type="text" 
> lang="en"> to get spellchecking to turn for photo titles then that would 
> be much worse for the large number of non-native English speakers than 
> <input type="text" spellcheck="on"> which would likely use the user's 
> preferred dictionary (although this would be UA-dependent of course).

How about <input type="text" lang="mul"> if the content author does not
want to specify a language? That would hint the UA that this field
assumes human language but the input may be in any language.

The current (heuristics) could be requested with <input type="text"
lang="und"> which explicitly marks this input to contain text with
undefined language.

> For another example, consider the case where I post on a Swedish forum 
> in English, knowing that the general level of English in Sweden is 
> excellent and in any case better than the level of my Swedish.

I agree. However, if the forum maintainer would rather have no text at
all instead of text in "wrong" language, then the forum maintainer
should use <input type="text" lang="se"> and the UA would correctly flag
any non-swedish word as incorrect.

> It doesn't seem reasonable to expect sites to always be localised or for 
>   sites accepting multilingual user generated content to not exist. 
> Therefore it seems totally conterproductive from the point of view of 
> people communicating in less dominant languages to require spellchecking 
> to be tied to language.

I'm not suggesting spellchecking to require only a single language. I'm
requesting that if the page wants automatic spell checking it must
explicitly define the language that the spellchecking should check for.
For multiple languages case, the RFC 3066 defines the MUL language code
and for the undefined case, the UND code has been defined.

Currently the lang attribute accepts exactly one language code. For the
case where acceptable input for forum message would be Swedish or
English it would be nice to be able to write <input type="text"
lang="se,en"> or perhaps even lang="se,en;q=0.1".

-- 
Mikko


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20090121/f8a596f9/attachment.pgp>


More information about the whatwg mailing list