Bug 10108 - Deleting an RTL letter followed by a space and an LTR run deletes the space as well
Summary: Deleting an RTL letter followed by a space and an LTR run deletes the space a...
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: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-07-25 12:59 PDT by mitz
Modified: 2010-09-11 10:06 PDT (History)
2 users (show)

See Also:


Attachments
Test case (157 bytes, text/html)
2006-07-25 13:00 PDT, mitz
no flags Details
TestCase2 (890 bytes, text/html)
2009-06-04 08:00 PDT, Yair Yogev
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description mitz 2006-07-25 12:59:11 PDT
To reproduce this bug, open the attached test case and delete the Hebrew letter ב, either by selecting it or placing the caret after it (that is, to its left) and pressing the delete key. The space between the RTL run and the LTR run will be deleted.
Comment 1 mitz 2006-07-25 13:00:22 PDT
Created attachment 9684 [details]
Test case
Comment 2 mitz 2007-02-22 04:49:34 PST
The space is deleted because CompositeEditCommand::deleteInsignificantText() assumes that InlineTextBoxes are in logical order. Need to figure out an efficient way to implement this function when the assumption is false (to be used when containsReversedText() is true).
Comment 3 Yair Yogev 2009-05-14 03:55:13 PDT
this is not only a mac issue
Comment 4 Yair Yogev 2009-06-04 07:15:56 PDT
this issue is worst than it may seem.
i am not sure how to make a test case for it yet, but in some cases the space is deleted even if the deleted character and the next characters also are all RTL
Comment 5 Yair Yogev 2009-06-04 08:00:15 PDT
Created attachment 30946 [details]
TestCase2

in a multi-line RTL div, deleting the last character of a Hebrew word deletes the following space too.
the last line in the div doesn't have this issue.
Comment 6 Yair Yogev 2010-09-11 03:45:02 PDT
Yey! this is no longer reproducible for me, can anyone double check?
i wonder where it was fixed / who is to "blame" :)
Comment 7 mitz 2010-09-11 10:06:14 PDT
This was most likely fixed in <http://trac.webkit.org/changeset/65144> where deleteInsignificantText() was changed to handle the containsReversedText() case correctly.