[Webkit-unassigned] [Bug 108513] [Chromium] Replace correct misspelled range

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Feb 4 10:24:09 PST 2013


--- Comment #14 from Ryosuke Niwa <rniwa at webkit.org>  2013-02-04 10:26:14 PST ---
(In reply to comment #13)
> (In reply to comment #12)
> > (From update of attachment 186083 [details] [details])
> > Going to write the test.
> Would it be OK to add window.internals.replaceMisspellingRange() method for testing WebKit::WebFrameImpl::replaceMisspelledRange() from Source/WebKit/chromium/src/WebFrameImpl.h ?

It's a WebKit API so it needs to be testRunner but I don't think we should be adding port specific testRunner method like that.

(In reply to comment #3)
> (In reply to comment #2)
> > (From update of attachment 186074 [details] [details])
> > View in context: https://bugs.webkit.org/attachment.cgi?id=186074&action=review
> > 
> > > Source/WebKit/chromium/src/WebFrameImpl.cpp:1319
> > > -    frame()->editor()->replaceSelectionWithText(text, false, true);
> > > +    frame()->editor()->replaceSelectionWithText(text, false, false);
> > 
> > Why are you disabling smart replace?
> If the user selects "wellcome_" together with underline, context clicks on the selection, and chooses the "welcome" suggestion, then smart replace will result in "welcome _". I think that might be OK behavior for replaceRange(), but not for replaceMisspelledRange(). This method should only replace the misspelling, not introduce extra spaces.

You should be able to create a selection like that manually using getSelection(). There ought to be a way to trigger correction once the text is selected.

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list