WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED INVALID
120121
Fix startOfWord method to not include white space between words.
https://bugs.webkit.org/show_bug.cgi?id=120121
Summary
Fix startOfWord method to not include white space between words.
Roger Fong
Reported
2013-08-21 10:35:03 PDT
In VisibileUnits.cpp. Consider startOfWord for the boundary argument LEFT_WORD_IF_ON_BOUNDARY. If the current position of the caret is at the start of a word, that is considered on the boundary. The method in this case returns the previous boundary hoping to get the start of the previous word. However, instead it just returns the end of the previous word, as that is indeed the previous boundary. Will fix this so that startOfWord does not treat the whitespace between words as boundaries. I'm not sure yet whether it makes sense to ignore situations where there is more than one character being used as whitespace between words since that seems to be more deliberate.
Attachments
patch
(1.69 KB, patch)
2013-08-22 13:57 PDT
,
Roger Fong
cfleizach
: review-
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2013-08-21 10:35:36 PDT
<
rdar://problem/14797275
>
Roger Fong
Comment 2
2013-08-22 13:57:12 PDT
Created
attachment 209392
[details]
patch This just ignores a single whitespace character between words... I'm not yet sure I want to extend this to more than one.
Alexey Proskuryakov
Comment 3
2013-08-22 15:38:16 PDT
Comment on
attachment 209392
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=209392&action=review
> Source/WebCore/ChangeLog:3 > + <
https://bugs.webkit.org/show_bug.cgi?id=120119
> Fix startOfWord method to not include white space between words.
This is a major change very low at the editing stack. I'll be surprised if it doesn't change any behavior.
Roger Fong
Comment 4
2013-08-22 15:51:07 PDT
(In reply to
comment #3
)
> (From update of
attachment 209392
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=209392&action=review
> > > Source/WebCore/ChangeLog:3 > > + <
https://bugs.webkit.org/show_bug.cgi?id=120119
> Fix startOfWord method to not include white space between words.
I liked to the wrong bug in my changelog -_-
> > This is a major change very low at the editing stack. I'll be surprised if it doesn't change any behavior.
I'll try to find a good way to test this on both mac and windows.
Alexey Proskuryakov
Comment 5
2013-08-22 16:00:38 PDT
Looks like this patch is failing a bunch of tests, EWS just couldn't make up its mind enough to tell us about that. You can see the failures if you click on a yellow bubble.
Roger Fong
Comment 6
2013-08-22 16:34:05 PDT
Actually I can't imagine this working in the more general case at all. startOfWord calls isStartOfWord, which calls startOfWord....etc etc...my manual tests were clearly not extensive enough. Will rework things or find a higher level place to fix this.
Roger Fong
Comment 7
2013-08-22 16:49:47 PDT
(In reply to
comment #6
)
> Actually I can't imagine this working in the more general case at all. > startOfWord calls isStartOfWord, which calls startOfWord....etc etc...my manual tests were clearly not extensive enough. > > Will rework things or find a higher level place to fix this.
So in webkit, the white space between words also counts as a word. So no change needs to be made to this file.
Roger Fong
Comment 8
2013-08-22 17:45:52 PDT
Holding on that thought, need to first investigate the impact of this on text navigation in screen readers that use iaccessible text like nvda
chris fleizach
Comment 9
2013-08-26 11:18:09 PDT
Comment on
attachment 209392
[details]
patch r- to help clear the r? queue
Roger Fong
Comment 10
2013-09-05 18:33:40 PDT
Not a bug, there are other ways of navigating through words while ignoring white space in place.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug