[webkit-dev] On/Off selection gap painting during the text selection

Antonio Gomes tonikitoo at webkit.org
Tue May 3 13:11:13 PDT 2016


On Tue, May 3, 2016 at 2:11 PM, Ryosuke Niwa <rniwa at webkit.org> wrote:

>
> On Tue, May 3, 2016 at 6:24 AM, Gyuyoung Kim <gyuyoung.kim at webkit.org>
> wrote:
>
>> Hello all,
>>
>> I upload a patch to add a preference API in order to enable/disable the
>> selection gap painting feature.
>>
>> Add WKPreference for SelectionPaintingWithoutSelectionGaps
>> https://bugs.webkit.org/show_bug.cgi?id=156900
>>
>>
>> You're able to see what is the selection gap painting in below
>> screenshots.
>>
>>
>> 1. Enable selection gap painting on WebKitGTK+ (Red circles point out the
>> selection gaps)
>>
>>
>>>>>>
>> 2. Disable selection gap painting on WebKitGTK+
>>
>>
>>>> Almost browsers don't support the selection gap painting when doing text
>> selection. So I wonder why WebKit has been doing support this feature so
>> far.
>>
>
> Selection gap primarily exists to match TextEdit / NSTextView's selection
> behavior on Mac.
>
> At last year's contributor's meeting, there was a discussion about
> revising that to adopt iOS like block selection in the future once we adopt
> visual selection of contents.
>
>
Alternatively, you could also think of extending the existing
EditingBehavior class, with a method that asks about "selection gap
drawing". By design, this works as long as this behavior is to match a
platform specific behavior / pattern, rather than a port specific behavior.

However, if this is a port specific behavior, then the API seems OK.

--
--Antonio Gomes
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-dev/attachments/20160503/54ca6292/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: enable-selection-gap-painting-2.png
Type: image/png
Size: 154698 bytes
Desc: not available
URL: <https://lists.webkit.org/pipermail/webkit-dev/attachments/20160503/54ca6292/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: disable-selection-gap-painting-2.png
Type: image/png
Size: 143176 bytes
Desc: not available
URL: <https://lists.webkit.org/pipermail/webkit-dev/attachments/20160503/54ca6292/attachment-0003.png>


More information about the webkit-dev mailing list