[Webkit-unassigned] [Bug 204946] New: Improve typing into an anchor
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Dec 6 05:32:57 PST 2019
https://bugs.webkit.org/show_bug.cgi?id=204946
Bug ID: 204946
Summary: Improve typing into an anchor
Product: WebKit
Version: Other
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: WebKitGTK
Assignee: webkit-unassigned at lists.webkit.org
Reporter: mcrha at redhat.com
CC: bugs-noreply at webkitgtk.org
I'm using webkit-2.26 branch at r252187 currently.
When typing at the end of the anchor, the text is added after it, not into it. While it can make sense for things like \n or \t, the other text might be nice to have inside the anchor. It's questionable with respect of space, because sometimes it can be part of it, but sometimes not.
Steps:
a) run: MiniBrowser --editor-mode
b) click Insert Link button and type some text into the entry, like "abc" and confirm the dialog
c) move cursor to the right (by pressing the right arrow, which deselects the link text)
d) verify in the inspector that the current selection is at the end of the anchor, like with this:
> document.getSelection().baseNode
< "abc"
> document.getSelection().baseOffset
< 3
> document.getSelection().baseNode.parentElement
< <a href="abc">abc</a>
e) type a letter, like 'd'
The 'd' is added after the anchor, not inside it, where the cursor was.
Evolution (its mail composer) has some workaround code for it, but:
a) it adds inconsistency from the default behaviour;
b) it adds a maintenance burden;
c) I think it would make sense to have WebKit itself behave better.
I know there might be a challenge to be able to write out of the anchor, like to be able to continue writing after the anchor, but for that could be special-cased just some keys, like a space, insertParagraph and such, which will behave like now. The space can be part of the description of the anchor, especially in an HTML message, but as long as the characters will be significant only at the end of the anchor text (there is no need to change anything when writing on previous positions in the anchor), then it should be fine, I believe.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20191206/56647815/attachment.htm>
More information about the webkit-unassigned
mailing list