Closed Bug 357625 Opened 15 years ago Closed 15 years ago
Text At Offset doesn't seem to work well with text with <br> in it
14.54 KB, text/x-python
620 bytes, text/html
1) To get end of line use eSelectLine with large desiredX, 2) Modify logic for increasing start of line index, 3) Improve <br> check at end of line so extra dom nodes don't break the check
3.64 KB, patch
|Details | Diff | Splinter Review|
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9a1) Gecko/20061016 Minefield/3.0a1 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9a1) Gecko/20061016 Minefield/3.0a1 I did a search and saw a similar problem in bug 349909 https://bugzilla.mozilla.org/show_bug.cgi?id=349909. It was marked as fixed, but I either don't have the fix in my version from Oct 16 (the ftp site is down for me to be able to get the latest nightly) or a different bug still exists. Reproducible: Always Steps to Reproduce: 1. Open the attached URL as the only content in firefox (i.e., don't open any other tabs) 2. Run the attached standalone app 3. Turn on caret navigation and arrow up/down in the content (the caret is just a way to trigger the analysis code in the standalone app). Actual Results: Text (len=304): 1This sentence is in Comic Sans MSl font. 2This sentence is in Courier New Font. 3This sentence is in Garamondl font. 4This sentence is in Impact font. 5This sentence is in Lucida Console font. 6This sentence is in Sydnie font. 7This sentence is in Tahoma font. 8This sentence is in Times New Roman font. CHAR AT OFFSET 0: '1' LINE AT OFFSET 0: (0:41) 1This sentence is in Comic Sans MSl font. CHAR AT OFFSET 41: ' ' CHAR AT OFFSET 42: '2' LINE AT OFFSET 42: (0:41) 1This sentence is in Comic Sans MSl font. END OFFSET < OFFSET!!!! Expected Results: The getTextAtOffset for a line at character 42 should not be for the text range (0:41). In this case, it should start at 42.
Component: Disability Access → General
Product: Firefox → Core
QA Contact: disability.access → general
Version: unspecified → Trunk
The last component change looks like an error.
Assignee: nobody → aaronleventhal
Component: General → Disability Access APIs
QA Contact: general → accessibility-apis
Using TEXT_BOUNDARY_LINE_START We should be getting 0,42 for the first line, and 42, whatever for the second line. Right?
Correct! In the output, you'll see that character 42 is '2', which is the beginning of the next line. Thanks!
Status: UNCONFIRMED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.