Closed Bug 246482 Opened 16 years ago Closed 14 years ago

Double click fails to select a word in BiDi texts

Categories

(Core :: DOM: Selection, defect)

x86
Windows XP
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: bugzillamozilla, Unassigned)

References

Details

(Keywords: testcase)

Attachments

(1 file)

To reproduce:
In the soon-to-be-attached testcase, double click any word in the first line.

Actual result:
Regardless of which word of the three is double-clicked, the last two "עברית
English2" get selected.

Expected result:
Only the double-clicked word should be selected, as it does in the RTL-only
second line (or in IE6).

Prog.
Attached file Testcase
This almost certainly has the same underlying cause as bug 299535.
Depends on: 299535
(In reply to comment #2)
And indeed it seems my patch for 299535 solves this as well: If you click a word
in the first line, only that word gets selected.

However, and this may be a separate bug (or expected behavior? not likely), and
happens even without my patch, clicking _between_ two Hebrew words on the
_second_ line causes both of them to be selected.

(In reply to comment #3)
> clicking _between_ two Hebrew words on the _second_ line causes both of them to 
> be selected.

It's not the expected behavior on Windows, but it's actually more useful. If
you're not a UI consistency fanatic, then I suggest you leave this one alone.

Prog.
(In reply to comment #4)
As you can tell from the patch, I'm not a purist about this, I just want to help
get this code to a sort-of-workable state.
Well, it seems I spoke too soon. My patch was with the wrong diff, and with the
right diff I only partially fix this. So back to the debugger with me.
*** Bug 301474 has been marked as a duplicate of this bug. ***
(In reply to comment #4)
> (In reply to comment #3)
> > clicking _between_ two Hebrew words on the _second_ line causes both of them to 
> > be selected.
> 
> It's not the expected behavior on Windows, but it's actually more useful. If
> you're not a UI consistency fanatic, then I suggest you leave this one alone.
> 
> Prog.
> 

Actually, it's bug 200098.
Keywords: testcase
The easiest way to fix this might be simply to envoke PeekOffset in "logical mode" for double-click, when such a mode becomes available (see the last sentence of bug 330175 comment #1).
Depends on: 330175
Fixed by the patch on bug 330175, as described in comment #9.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9alpha
*** Bug 287502 has been marked as a duplicate of this bug. ***
Duplicate of this bug: 367487
You need to log in before you can comment on or make changes to this bug.