Skip to content

Commit 2378848

Browse files
authored
Minor comment fix and add TODO. (flutter#7158)
1 parent 08922e1 commit 2378848

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

third_party/txt/src/txt/paragraph.cc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -479,8 +479,12 @@ void Paragraph::Layout(double width, bool force) {
479479
}
480480
}
481481

482-
// Exclude trailing whitespace from right-justified lines so the last
483-
// visible character in the line will be flush with the right margin.
482+
// TODO(garyq): Make GetRectsForRange return a zero-width box for the
483+
// excluded whitespace such that the caret placement is correct regardless
484+
// of the index being whitespace or not.
485+
486+
// Exclude trailing whitespace from right and center-justified lines so the
487+
// last visible character in the line will be flush with the right margin.
484488
size_t line_end_index =
485489
(paragraph_style_.effective_align() == TextAlign::right ||
486490
paragraph_style_.effective_align() == TextAlign::center)

0 commit comments

Comments
 (0)