Closed
Bug 875794
Opened 12 years ago
Closed 12 years ago
get text at offset for line boundary fails on last empty line
Categories
(Core :: Disability Access APIs, defect)
Tracking
()
RESOLVED
FIXED
mozilla25
People
(Reporter: MarcoZ, Assigned: surkov)
References
Details
(Keywords: regression)
Attachments
(2 files)
3.04 KB,
patch
|
Details | Diff | Splinter Review | |
2.67 KB,
patch
|
Details | Diff | Splinter Review |
STR:
1. With NVDA running, either connect a braille display.
2. Find any textarea.
3. Type something.
4. press Enter.
Expected: Braille display should be blank, with cursor blinking on first cell of the line.
Actual: Text remains on the display, and the cursor blinks after the last character, as if no newline was inserted.
This is a regression from bug 873358 and first appears in 24.0a1 (2013-05-24).
Assignee | ||
Comment 1•12 years ago
|
||
Jamie, could you take a look what's broken? Presumably it is something wrong with text interface line boundary?
Flags: needinfo?(jamie)
Comment 2•12 years ago
|
||
Consider a textarea where you type "test" and then press enter, so the entire text is "test\n". IAccessibleText::textAtOffset(4, IA2_TEXT_BOUNDARY_LINE) (4 is the line feed) returns offsets of (0, 5), which is correct. However, IAccessibleText::textAtOffset(5, IA2_TEXT_BOUNDARY_LINE) (5 is where the caret lands after pressing enter) returns offset of (0, 4). Aside from being oddly inconsistent (why 4 instead of 5?), this is incorrect, since we're on the new line, so it should be at least (5, 5).
The tricky part is that there's actually no character there yet, which makes bounds checking a bit weird. Essentially, we have to pretend there's a character there.
Flags: needinfo?(jamie)
Assignee | ||
Comment 3•12 years ago
|
||
(In reply to James Teh [:Jamie] from comment #2)
> Consider a textarea where you type "test" and then press enter, so the
> entire text is "test\n". IAccessibleText::textAtOffset(4,
> IA2_TEXT_BOUNDARY_LINE) (4 is the line feed) returns offsets of (0, 5),
> which is correct. However, IAccessibleText::textAtOffset(5,
> IA2_TEXT_BOUNDARY_LINE) (5 is where the caret lands after pressing enter)
> returns offset of (0, 4). Aside from being oddly inconsistent (why 4 instead
> of 5?), this is incorrect, since we're on the new line, so it should be at
> least (5, 5).
yep (5,5) seems correct here (I'm pretty sure we have todo in our test suite for this)
> The tricky part is that there's actually no character there yet, which makes
> bounds checking a bit weird. Essentially, we have to pretend there's a
> character there.
so if we return (5, 5, "") then it is still a problem for NVDA?
Assignee | ||
Updated•12 years ago
|
Blocks: getText*a11y
Comment 4•12 years ago
|
||
(In reply to alexander :surkov from comment #3)
> > The tricky part is that there's actually no character there yet, which makes
> > bounds checking a bit weird. Essentially, we have to pretend there's a
> > character there.
> so if we return (5, 5, "") then it is still a problem for NVDA?
Not at all. I was just making an observation about why the regression probably crept in.
Assignee | ||
Comment 5•12 years ago
|
||
ok, thanks. renaming bug
Summary: After bug 873358, when inserting a newline at the end of a textarea, the braille display does no longer get blank → get text at offset for line_start boundary fails on last empty line
Assignee | ||
Comment 6•12 years ago
|
||
Assignee: nobody → surkov.alexander
Status: NEW → ASSIGNED
Attachment #756398 -
Flags: review?(trev.saunders)
Assignee | ||
Comment 7•12 years ago
|
||
Attachment #756990 -
Flags: review?(trev.saunders)
Assignee | ||
Updated•12 years ago
|
Summary: get text at offset for line_start boundary fails on last empty line → get text at offset for line boundary fails on last empty line
Assignee | ||
Updated•12 years ago
|
Attachment #756398 -
Attachment description: patch → part1: line start case
Assignee | ||
Updated•12 years ago
|
No longer blocks: getText*a11y
Assignee | ||
Comment 8•12 years ago
|
||
Comment on attachment 756398 [details] [diff] [review]
part1: line start case
canceling review, replaced by bug 882281
Attachment #756398 -
Flags: review?(trev.saunders)
Assignee | ||
Updated•12 years ago
|
Attachment #756990 -
Flags: review?(trev.saunders)
Assignee | ||
Comment 9•12 years ago
|
||
Flags: in-testsuite+
Comment 10•12 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla25
Assignee | ||
Comment 11•12 years ago
|
||
part2: http://hg.mozilla.org/integration/mozilla-inbound/rev/29139ed969a5 (pulls r+ from bug 882281)
Comment 12•12 years ago
|
||
You need to log in
before you can comment on or make changes to this bug.
Description
•