Closed
Bug 16176
Opened 25 years ago
Closed 25 years ago
[DOGFOOD] need to annotate line frames with whitespace trimming info
Categories
(Core :: Layout, defect, P1)
Core
Layout
Tracking
()
VERIFIED
FIXED
M11
People
(Reporter: buster, Assigned: kinmoz)
References
Details
(Whiteboard: [PDT+])
To solve the problem on imaging a space at the end of a line in the editor (that is, imaging the caret offset from the last character in a line when the last character is a space), we need the line frame to be annotated with the result of the whitespace trimming code. Given that, the caret can be taught how to paint itself to show the space. Marked dogfood because this is required to fix a dogfood caret imaging bug 14573 Kipp, please assign back to me when your part is done.
Code's in; nsILineIterator's GetLine method now returns "flags" for each line; see the definitions at the top...
assigned to sfraser, cc kin. Could one of you look at this as a high priority dogfood item? I hear lots of complaints about the editor not handling spaces correctly, and it makes for some awkward editing without the visual feedback of a space at the end of the line.
Assigning to kin@netscape.com.
Changed QA contact from petersen@netscape.com to sujay@netscape.com per beppe@netscape.com.
Updated•25 years ago
|
Priority: P2 → P1
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Fix checked in to Mozilla 5.0 tip. This fix actually went a different route, instead of using the line iterator's line flags, I modified nsTextFrame::nsGetPointFromOffset() to check mFlags and tack on the width of the missing space if it was trimmed. layout/base/src/nsCaret.cpp revision 1.36 - Modified DrawCaretWithContext so that we only adjust the caret position if we are within the frame's bounds. layout/html/base/src/nsTextFrame.cpp revision 1.189 - Modified GetPointFromOffset() to add the width of a space if the offset is after a trailing space and it was trimmed off the frame. Fix was reviewed by sfraser@netscape.com.
Comment 10•25 years ago
|
||
re-assigning to petersen.
Comment 11•25 years ago
|
||
Steve, I'm not sure what I should do to verify this fix. Is there a test case I could use to help me ?
Assignee | ||
Comment 12•25 years ago
|
||
Testing for this is easy. Startup a blank composer, then type a word and hit the space bar. The caret should advance by a space. Before this bug was fixed, the caret would not advance till you hit the space bar twice to enter 2 spaces.
Updated•25 years ago
|
Status: RESOLVED → VERIFIED
Comment 13•25 years ago
|
||
With the Dec 01 build (1999120108), this problem has been fixed.
You need to log in
before you can comment on or make changes to this bug.
Description
•