/// Find right end of semantic block.
Find right end of semantic block.
Find right end of semantic block .
pub fn semantic_search_right(&self, mut point: Point<usize>) -> Point<usize> {
        // Limit the starting point to the last line in the history
        point.line = min(point.line, self.total_lines() - 1);
        let mut iter = self.grid.iter_from(point);
        let last_col = self.cols() - 1;
        let wide = Flags::WIDE_CHAR | Flags::WIDE_CHAR_SPACER | Flags::LEADING_WIDE_CHAR_SPACER;
        while let Some(cell) = iter.next() {
            if !cell.flags.intersects(wide) && self.semantic_escape_chars.contains(cell.c) {
                break;
            }
            point = iter.point();
            if point.col == last_col && !cell.flags.contains(Flags::WRAPLINE) {
                break; // cut off if on new line or hit escape char
            }
        }
        point
    }
pub fn semantic_search_right ( & self , mut point : Point < usize > ) -> Point < usize > { // Limit the starting point to the last line in the history point . line = min ( point . line , self . total_lines ( ) - 1 ) ; let mut iter = self . grid . iter_from ( point ) ; let last_col = self . cols ( ) - 1 ; let wide = Flags :: WIDE_CHAR | Flags :: WIDE_CHAR_SPACER | Flags :: LEADING_WIDE_CHAR_SPACER ; while let Some ( cell ) = iter . next ( ) { if ! cell . flags . intersects ( wide ) && self . semantic_escape_chars . contains ( cell . c ) { break ; } point = iter . point ( ) ; if point . col == last_col && ! cell . flags . contains ( Flags :: WRAPLINE ) { break ; // cut off if on new line or hit escape char } } point }
Find right end of semantic block.
Find right end of semantic block .
&self
point
Point<usize>