Bug 6289 - REGRESSION: firstCharacterForRange(0, 0) returns a 0x0 rect
Summary: REGRESSION: firstCharacterForRange(0, 0) returns a 0x0 rect
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: HTML Editing (show other bugs)
Version: 420+
Hardware: Mac OS X 10.4
: P2 Normal
Assignee: Alexey Proskuryakov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-12-29 16:56 PST by mitz
Modified: 2005-12-30 13:25 PST (History)
1 user (show)

See Also:


Attachments
band-aid fix (1.48 KB, patch)
2005-12-29 22:42 PST, Alexey Proskuryakov
mjs: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description mitz 2005-12-29 16:56:23 PST
The following layout tests are failing in TOT due to firstCharacterForRange(0, 0) returning a 0x0 rect:
editing/input/firstrectforcharacterrange-plain
editing/input/firstrectforcharacterrange-styled
fast/text/attributed-substring-from-range

It looks like a regression from fixing bug 6246.
Comment 1 Alexey Proskuryakov 2005-12-29 22:42:51 PST
Created attachment 5369 [details]
band-aid fix

Looks like an indirect result of issues described in bug 5610: the range
returned for (0, 0) in these tests is (#text, 1)-(#text,1) rather than (#text,
0)-(#text,0) - and the latter or equivalent don't give correct results in
firstRectForDOMRange (which may be a separate issue). Going to cleanup this
further as part of the investigation on 5610...
Comment 2 Maciej Stachowiak 2005-12-30 02:09:56 PST
r=me, looks like an ok fix for now if it gets the tests passing and doesn't break anything.