- From: David Young <dyoung@pobox.com>
- Date: Fri, 6 Nov 2015 01:21:33 -0600
- To: public-editing-tf@w3.org
On Fri, Nov 06, 2015 at 07:32:58AM +0100, Johannes Wilm wrote: > Hey, > looking at some files around IME in blink's source code. The code for > markers (spelling, composition) looks interesting. Are there security > concerns that make us not expose those to JS? If so, what concerns are > those? > > It seems like the main problem problem for IME is figuring out what is a > candidate text (what is underlined), what is committed. Candidate text is > already part of the DOM, so for us who look at the DOM from the perspective > of JavaScript, it makes it all really difficult to deal with, and for those > working in the browser world everything is getting more complex when we try > to do anything unpredicted in JS because you then need to make sure that > your underlining mechanism works correctly. > > But what if we exposed something like > > addCompositionMarker(range,color,thickness,backgroundColor) Say that the editor's author decides that underline and thickness do not apply? Is something like this not possible, where the editor JavaScript would activate the composition style on the composition-start event, and deactivate the style when the -end event arrived? Example 1: enter a "naked" accent user key commands JavaScript events ----------------- ----------------- Option-E composition start insert ´ E delete backward 1 insert é composition end Example 2: enter accented e (é) user key commands JavaScript events ----------------- ----------------- Option-E composition start insert ´ Space bar composition end Dave -- David Young dyoung@pobox.com Urbana, IL (217) 721-9981
Received on Friday, 6 November 2015 07:22:02 UTC