Bug 4708
Summary: | kEventTextInputGetSelectedText doesn't return any text from WebHTMLViews | ||
---|---|---|---|
Product: | WebKit | Reporter: | Alexey Proskuryakov <ap> |
Component: | HTML Editing | Assignee: | Dave Hyatt <hyatt> |
Status: | RESOLVED DUPLICATE | ||
Severity: | Normal | CC: | evan |
Priority: | P2 | ||
Version: | 420+ | ||
Hardware: | Mac | ||
OS: | OS X 10.4 |
Alexey Proskuryakov
When an input method asks a WebHTMLView for the currently selected text, nothing is returned.
Steps to reproduce:
1. Open WebCore/layout-tests/editing/inserting/typing-001.html
2. Type something with Kotoeri Hiragana, confirm the inline input area
3. Select one character
4. Press Control-1 or Control-2 (Search similar Kanji, Convert to related character)
Expected results: an inline input area is created from the selection
Actual results: nothing happens
Discussion: here is how the reply to kEventTextInputGetSelectedText looks like (note the emply
kEventParamTextInputReplyText 'trtx'):
(gdb) call (void)_DebugPrintEvent(0x5CD49D0)
Displaying event 5CD49D0...
Class text
Kind 6
When 3132.53
Priority Standard
RetainCount 1
Queued No
Info kEventTextInputGetSelectedText
Parameters
param: tsci
type: cmpi
size: 4
data: 00FFFFFF810003
param: buff
type: long
size: 4
data: 00000100
param: tssm
type: magn
size: 4
data: 00000001
param: tssl
type: intl
size: 2
data: 0001
param: tsrc
type: long
size: 4
data: 04FFFFFFE92230
"0
param: trsl
type: intl
size: 4
data: 0001000B
param: trtx
type: utxt
size: 0
data:
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Alexey Proskuryakov
This is fixed by implementing attributedSubstringFromRange
*** This bug has been marked as a duplicate of 4680 ***