- From: Simon Pieters <simonp@opera.com>
- Date: Mon, 18 Mar 2013 10:46:43 +0100
- To: "Pablo Flouret" <pablof@motorola.com>, "public-webapps@w3.org" <public-webapps@w3.org>, "Alex Mogilevsky" <alexmog@microsoft.com>
On Tue, 05 Feb 2013 01:41:14 +0100, Alex Mogilevsky <alexmog@microsoft.com> wrote: > ± From: Pablo Flouret [mailto:pablof@motorola.com] > ± Sent: Monday, February 4, 2013 12:47 PM > ± > ± On Mon, 04 Feb 2013 11:59:46 -0800, Alex Mogilevsky > <alexmog@microsoft.com> > ± wrote: > ± > ± > There was a discussion here a while ago on desired default behavior > ± > for Enter in contenteditable and options for > ± > execCommand("defaultParagraphSeparator"): > ± > > http://lists.w3.org/Archives/Public/public-whatwg-archive/2011May/thre > ± > ad.html#msg171 > ± > > ± > Did it ever get to consensus? Or is there new thinking on how that > ± > should work? > ± > ± I implemented this in Opera and WebKit[1], can't really tell from the > ± bugzilla bug if it's in firefox too[2], but i think they were on board > as > ± well. > ± > ± [1] https://bugs.webkit.org/show_bug.cgi?id=59961 > ± [2] https://bugzilla.mozilla.org/show_bug.cgi?id=748303 > > The "Editing API" document flags "defaultParagraphSeparator" as having > issues, some are mentioned in the document and more raised in the > discussion. Such as > > * default value (currently 'p', but not consistent in implementations) Opera used p for compat with IE, though I don't have a strong opinion about what the default should be, so long as we all do the same thing. > * default styles (if 'p' is default, it adds default 1em margin before > first line, which most people consider undesirable) The "undesirable" style is basically the reason we implemented this in Opera. We didn't want to just use <div> by default because it was considered risky compat-wise. > * when should Enter insert a line break instead of block (e.g. when > inside <pre>)? Isn't this defined in the spec? https://dvcs.w3.org/hg/editing/raw-file/tip/editing.html#the-insertparagraph-command > * can/should the default block be set per editable area and how? This is not specific to defaultparagraphseparator but applies to many commands, and there has been a proposal to expose execCommand on elements. > * why only 'p' and 'div'? Only p and div addresses the use case of p having undesirable style. > If there is a chance to settle on what's right for any of these, it > would be awesome. > > Alex > > [1] > https://dvcs.w3.org/hg/editing/raw-file/tip/editing.html#the-defaultparagraphseparator-command -- Simon Pieters Opera Software
Received on Monday, 18 March 2013 09:47:44 UTC