This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 22057 - Clarify InputMethodContext's scope in the spec
Summary: Clarify InputMethodContext's scope in the spec
Status: RESOLVED FIXED
Alias: None
Product: WebAppsWG
Classification: Unclassified
Component: HISTORICAL - IME API (show other bugs)
Version: unspecified
Hardware: PC All
: P2 normal
Target Milestone: ---
Assignee: Takayoshi Kochi
QA Contact: public-webapps-bugzilla
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-16 08:46 UTC by Takayoshi Kochi
Modified: 2013-07-04 07:32 UTC (History)
5 users (show)

See Also:


Attachments

Description Takayoshi Kochi 2013-05-16 08:46:41 UTC
An InputMethodContext can be obtained from any HTMLElement, but in some cases
it is unrealistic that all elements in a page have different contexts.

This point is ambiguous in the spec.

For example, consider the following HTML:

<html>
<body>
<input type=text>
<textarea>
...
</textarea>
<div contenteditable=true>
  <span id=span1> ... </span>
  <span id=span2> ... </span>
</div>
</body>
</text>

It makes sense <input> and <textarea> can have different context, but
if span1 and span2 can have different contexts, 
 - once cursor enters any of the span, switch to the active context?
 - if selection encompasses 2 <span>s, what context should be activated?

This may complicate the implementation too much.  Probably a guideline

  under one contentable element, all DOM elements under the element
  usually share the same context

makes sense for most implementations.
Comment 1 Travis Leithead [MSFT] 2013-05-28 22:03:00 UTC
Yes, it’s our thinking that if the developer queries for input method context on child elements inside the same contentEditable element, he’ll get the same context as on the parent contentEditable element.
Comment 2 Takayoshi Kochi 2013-07-04 07:32:41 UTC
I'll clear this in the next working draft spec.