@@ -1413,6 +1413,9 @@ class TextRange {
14131413 /// The [start] and [end] arguments must not be null. Both the [start] and
14141414 /// [end] must either be greater than or equal to zero or both exactly -1.
14151415 ///
1416+ /// The text included in the range includes the character at [start] , but not
1417+ /// the one at [end] .
1418+ ///
14161419 /// Instead of creating an empty text range, consider using the [empty]
14171420 /// constant.
14181421 const TextRange ({
@@ -1596,8 +1599,8 @@ enum BoxHeightStyle {
15961599/// Defines various ways to horizontally bound the boxes returned by
15971600/// [Paragraph.getBoxesForRange] .
15981601enum BoxWidthStyle {
1599- // Provide tight bounding boxes that fit widths to the runs of each line
1600- // independently.
1602+ /// Provide tight bounding boxes that fit widths to the runs of each line
1603+ /// independently.
16011604 tight,
16021605
16031606 /// Adds up to two additional boxes as needed at the beginning and/or end
@@ -1863,19 +1866,12 @@ class Paragraph extends NativeFieldWrapperClass2 {
18631866 }
18641867 List <int > _getPositionForOffset (double dx, double dy) native 'Paragraph_getPositionForOffset' ;
18651868
1866- /// Returns the [TextRange] of the word at the given [TextPosition.offset] .
1867- ///
1868- /// Characters not part of a word, such as spaces, symbols, and punctuation,
1869- /// have word breaks on both sides. In such cases, this method will return
1870- /// `TextRange(begin: position.offset, end: position.offset+1)` .
1871- ///
1869+ /// Returns the [start, end] of the word at the given offset. Characters not
1870+ /// part of a word, such as spaces, symbols, and punctuation, have word breaks
1871+ /// on both sides. In such cases, this method will return [offset, offset+1] .
18721872 /// Word boundaries are defined more precisely in Unicode Standard Annex #29
18731873 /// http://www.unicode.org/reports/tr29/#Word_Boundaries
1874- TextRange getWordBoundary (TextPosition position) {
1875- final List <int > range = _getWordBoundary (position.offset);
1876- return TextRange (start: range[0 ], end: range[1 ]);
1877- }
1878- List <int > _getWordBoundary (int offset) native 'Paragraph_getWordBoundary' ;
1874+ List <int > getWordBoundary (int offset) native 'Paragraph_getWordBoundary' ;
18791875
18801876 // Redirecting the paint function in this way solves some dependency problems
18811877 // in the C++ code. If we straighten out the C++ dependencies, we can remove
0 commit comments