[Bug] Moving the cursor should automatically scroll textareas
Categories
(Core :: Layout, defect)
Tracking
()
People
(Reporter: ekager, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 obsolete file)
From github: https://github.com/mozilla-mobile/fenix/issues/15485.
Steps to reproduce
write a long search query into github issues search box
Expected behavior
The cursor would scroll the textarea
Actual behavior
I noticed that when you're editing a search query in the issues page of a GitHub repo, when you move the cursor of a long query Firefox doesn't automatically scroll the textbox. The cursor also scrolls vertically when it can only scroll horizontally. Pretty annoying.
Device information
- Android device: ?
- Fenix version: Today's Nightly
Change performed by the Move to Bugzilla add-on.
Comment 2•4 years ago
|
||
Looks like this isn't a duplicate after all. Sending to APZ since this is about cursor and scrolling.
Comment 3•4 years ago
|
||
Moving to DOM: Selection
(I think this is the successor of what used to be the Layout: Text Selection
component?) as the cursor behaviour is handled by AccessibleCaret
.
Comment 4•4 years ago
|
||
I played the description of comment#0 a bit on Window Surface Pro and also Android.
What I notice is that the threshold to trigger scroll left and right are different.
So it is easy to move the cursor to scroll left, but you need to move the cursor far enough to the right to trigger scroll right.
And it seems there isn't enough space on Android device to make scroll right work?
TYLin might have some idea about this.
Comment 5•4 years ago
|
||
AccesibleCaret uses the same underlying auto scroll mechanism [1] like extending a selection hightlight by dragging a mouse to the right edge of an <input>
on the desktop. In fact, this bug can also be reproduced on desktop by setting layout.accessiblecaret.enabled=true
and layout.accessiblecaret.hide_carets_for_mouse_input=false
.
Dragging mouse to extend the selection works fine. In my testing, as soon as the mouse touching the right edge of the <input>
, it starts scrolling. We can investigate this by checking the frame and the pointer that AccessibleCaret gives to the StartAutoScrollTimer
API. That can give us a better sense of what goes wrong.
Comment 6•4 years ago
|
||
If I move the mouse cursor to middle of the <input>
element and slide my mouse to the right, it works as expected. So, a different thing from nsIFrame::HandleDrag()
is, mouse event is fired outside the <input>
element due to the accessible caret position.
Updated•3 years ago
|
Updated•1 year ago
|
Updated•1 year ago
|
Description
•