Re: [editing] Should the caret move by default, and should we define this behavior? (#58)

PS: Another difficulty with browsers that insert content and have restrictions on where carets can go in even slightly different ways is trying to synchronize them. 

* If two users on two different computers with different browsers are writing in the same document, one after another, one can have a "cleanup" function that cleans the content before the editing process starts and before saving it.  
* If two users on two different computers with different browsers are writing in the same document simultaneously, and the browsers need the content in different ways, it's not enough to just send diffs to the DOM back in forth. Instead, one needs to keep the document in a browser-independent format managed by the JS and synchronize between the DOM and this browser-independent format always when there is reason to believe there has been a change to one of them. For this there need to be distinct translators between DOM and browser-independent format for each of the four main browsers, if one wants to support all of them. The browser independent format then needs to synchronize with all the other participants in the editing process through some type of Operational Transformations. It's almost an MVC-model, but because the DOM is both used to render the current state of the document AND to record changes to it, it is a somewhat more messy process.
If, instead, one could guarantee that all browsers are happy with the exact same DOM structure and also handle insertions/deletions the same way, one would be able to remove at least one level of complexity.


---
Reply to this email directly or view it on GitHub:
https://github.com/w3c/editing/issues/58#issuecomment-108968767

Received on Thursday, 4 June 2015 16:55:18 UTC