Bug 103072

Summary: RTL/LTR Override Character can break caret movement/placement
Product: WebKit Reporter: Yair Yogev <progame+wk>
Component: HTML EditingAssignee: Nobody <webkit-unassigned>
Status: UNCONFIRMED ---    
Severity: Normal CC: ap, glenn, max.hong.shen, mitz, playmobil, xji
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 105451    
Bug Blocks:    
Attachments:
Description Flags
testcase none

Description Yair Yogev 2012-11-22 08:12:28 PST
Created attachment 175680 [details]
testcase

Steps to repro:
1. Put the caret in the second (empty) line
2. Press the Left arrow key
- the caret will appear in the middle of the line instead of at the end of it. 
3. Try to place the caret in the second part of the line using the mouse
- that part of the line is not "clickable"

There is also the symmetric case using RTL textarea and LTR Override Character.

Tested using
Google Chrome    25.0.1323.1 (Official Build 167142) dev-m
OS    Windows XP
WebKit    537.19 (@134111)
JavaScript    V8 3.15.1.2
Comment 1 Yi Shen 2012-12-19 12:17:06 PST
This bug contains two issues - First. press the left arrow key from the second line move the caret to the middle of the line instead of the end of it. -- this problem is because webkit lacks of one-to-one correspondence between visual and logical character positions. 

The second issue is unable to place the caret in the RTL text in the first line by using mouse click -- I have created a separated bug 105451 and submit a patch for it.

(In reply to comment #0)
> Created an attachment (id=175680) [details]
> testcase
> 
> Steps to repro:
> 1. Put the caret in the second (empty) line
> 2. Press the Left arrow key
> - the caret will appear in the middle of the line instead of at the end of it. 
> 3. Try to place the caret in the second part of the line using the mouse
> - that part of the line is not "clickable"
> 
> There is also the symmetric case using RTL textarea and LTR Override Character.
> 
> Tested using
> Google Chrome    25.0.1323.1 (Official Build 167142) dev-m
> OS    Windows XP
> WebKit    537.19 (@134111)
> JavaScript    V8 3.15.1.2