Opened 9 years ago

Last modified 9 years ago

#14321 confirmed Bug

[FF] Selection from native getSelection inconsistent with other browsers.

Reported by: kkrzton Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

In FF getSelection method inside contenteditable=true works differently than in other browsers (Chrome, IE, Opera) which is the cause of some issues (e.g. #8958, #10709, #10966, #14288). In FF selection from caret on exactly same position can have to different states while in other browsers it is always the same one state. Considering sample html:

normal^<strong>bold<strong>

in FF when caret is moved (via arrow keys) from normal to marked caret position, selection points to normal text node and typing produces normal text. When caret is moved from bold to marked caret postion, selection points to bold text/element node and typing produces bold text. So it basically depends on context from which cursor was moved (see more detailed description or jsfiddle sample).

In other browsers, no matter what previous context was, selection always points on the same element (usually it is the node/element before caret).

It is the difference between native implementations not the issue in CKEditor. However, as mentioned earlier, this difference causes some issues so it is worth considering if and how it could be handled in CKEditor.

Change History (1)

comment:1 Changed 9 years ago by kkrzton

Status: newconfirmed
Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy