PrevUpHomeNext

Function template prev_allowed_line_break

boost::text::v1::prev_allowed_line_break

Synopsis

// In header: <boost/text/line_break.hpp>


template<code_point_range R> 
  unspecified prev_allowed_line_break(R && r, std::ranges::iterator_t< R > it);

Description

Finds the nearest line break opportunity at or before before it. If it == r.begin(), that is returned. Otherwise, the first code point of the line that it is within is returned (even if it is already at the first code point of a line. Returns a line_break_result; in C++20 and later, if std::ranges::borrowed_range<R> is false, this function returns a std::ranges::dangling instead.

Returns a grapheme_iterator to the nearest line break opportunity at or before before it. If it == r.begin(), that is returned. Otherwise, the first grapheme of the line that it is within is returned (even if it is already at the first grapheme of a line). Returns a line_break_result; in C++20 and later, if std::ranges::borrowed_range<R> is false, this function returns a std::ranges::dangling instead.


PrevUpHomeNext