Closed Bug 64170 Opened 24 years ago Closed 14 years ago

when textbox is focused, it needs to scroll to make insertion point visible

Categories

(Core :: Layout: Form Controls, defect)

defect
Not set
minor

Tracking

()

RESOLVED FIXED
mozilla1.9.3a4

People

(Reporter: jruderman, Assigned: ehsan.akhgari)

References

Details

(Keywords: access, testcase, Whiteboard: [fixed by bug 353539])

Attachments

(2 files)

Steps to reproduce:
1. Go to Prefs->MailNews->Address Books or
data:text/html,<input type=radio><input type="text" size="3" value="123456789">.
2. Click on the control that's before the tiny textbox.
3. Press tab.

Result: keyboard focus is switched to the textbox and the insertion point is 
put at the end of the text in the textbox, but the textbox doesn't scroll to 
make the insertion point visible.
Blocks: 18575
reassigning
Assignee: rods → beppe
reassign to kin for review
Assignee: beppe → kin
Accepting bug.
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla1.0
Keywords: access
QA Contact Update
QA Contact: bsharma → vladimire
Keywords: fcc508
Fixing bug 28583, "Focusing text widget (except on click) should select widget",
would make this bug less important.  (Scripts would still be able to put the
insertion point at the end of a text field using selectionStart and selectionEnd.)
Bulk move of mozilla1.0 bugs to mozilla.1.0.1. I will try to pull some of these
back in if I can.
Target Milestone: mozilla1.0 → mozilla1.0.1
Keywords: mozilla1.0
Target Milestone: mozilla1.0.1 → ---
Set milestone to Moz1.1
Target Milestone: --- → mozilla1.1
Priority: -- → P3
Target Milestone: mozilla1.1alpha → Future
*** Bug 51897 has been marked as a duplicate of this bug. ***
How does a multi-platform, normal severity, priority one bug with more (but not
excessive) included commentary get duped to a later file, single platform, minor
priority bug, as bug 51897 was to this, and not acquire all those higher
priority attributes?
invalid, should highlight the text instead (there is already a bug on it)
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → INVALID
saari, 

What do you mean, exactly?

Since when should bringing focus to a textfield highlight the whole field?

If this bug is about something else than what I understand, I'll re-open Bug 
51897 
Does anyone understand the last comment from saari?

Hey saari, what about mentioning a bug number?
Saari is referring to bug 28583, "Focusing text widget (except on click) should
select widget contents".  I don't think fixing bug 28583 would be sufficient,
for two reasons:

1. Bug 28583 does not apply to textareas.
2. CSS3 may allow web pages to specify what happens when you tab to a text field
using the user-focus-key property (http://www.w3.org/TR/css3-userint#user-focus).
Status: RESOLVED → REOPENED
Resolution: INVALID → ---
Bug 51897 duped to this was:

OS-ALL
Priority-P1
Severity-normal

This bug should not have any of the same attributes set to a lower level than
the above. This is not a windoze only bug any more. There is no good reason for
a missing focus bug to be considered minor.
Is there any traction on this?

Bug 51897 was reported two years ago, had high priorities, and is, all things 
considered, a Netscape 1.0-era usability problem.

A form puts focus on a field, and there is no visible indication of that. This 
applies to thousands of applications that worked correctly for years and years, 
and are broken with Netscape 6+
Attached file testcase
This bug is still present in
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030914
Firebird/0.6.1+
Keywords: testcase
Attached patch version 0.1Splinter Review
bz: How does this look?

Essentially this makes any textarea or input=text scroll to the caret position
on focus.

I initially wanted to add it to
<http://lxr.mozilla.org/seamonkey/source/layout/forms/nsTextControlFrame.cpp#310>,
but mTextSelImpl is private to nsTextControlFrame ...

I'm not sure if we should do it for both inputs and text areas? I'd like to,
but some people might find it annoying, I don't know.

mpt: Any thoughts?
Assignee: kinmoz → vhaarr+bmo
Status: REOPENED → ASSIGNED
Attachment #196678 - Flags: review?(bzbarsky)
Just three. (1) Tabbing to single-line fields should not scroll them, except 
as allowed by bug 172203. (2) Clicking to focus a field should never result 
in scrolling (even if a previous selection was off-field). (3) Thanks Vidar!
Vidar, I'd need to apply that patch and play with it for a while to say anything
useful -- I don't really know that code very well...  You might want to try a
different reviewer, because I doubt I'll have the time to really look at this in
the near future (months, possibly).
Comment on attachment 196678 [details] [diff] [review]
version 0.1

Not quite sure who knows this code ...

Maybe dbaron ? :-)
Attachment #196678 - Flags: review?(bzbarsky) → review?(dbaron)
Have you tested that this does what comment 19 says?  What else have you tested, for HTML text inputs, XUL text inputs, and HTML textareas?
(In reply to comment #22)
> Have you tested that this does what comment 19 says?  What else have you
> tested, for HTML text inputs, XUL text inputs, and HTML textareas?

Hm, I can't remember which one, but I think one of the points in comment 19 gave unwanted behavior with the patch. Also, I don't think I tested XUL text inputs.

I'll hopefully get to testing this within a week or so. If anyone know any good testcases, please let me know.
Comment on attachment 196678 [details] [diff] [review]
version 0.1

minusing review request until questions are answered; feel free to re-request
Attachment #196678 - Flags: review?(dbaron) → review-
Assignee: vhaarr+bmo → nobody
Status: ASSIGNED → NEW
See also bug 353539, same bug for textareas.
Filter on "Nobody_NScomTLD_20080620"
QA Contact: vladimire → layout.form-controls
OS: Windows 98 → All
Hardware: PC → All
Priority: P3 → --
Target Milestone: Future → ---
My patch in bug 353539 fixes this problem.
Assignee: nobody → ehsan.akhgari
Status: NEW → ASSIGNED
Depends on: 353539
Whiteboard: [will be fixed by bug 353539]
Bug 353539 landed.
Status: ASSIGNED → RESOLVED
Closed: 22 years ago14 years ago
Resolution: --- → FIXED
Whiteboard: [will be fixed by bug 353539] → [fixed by bug 353539]
Target Milestone: --- → mozilla1.9.3a4
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: