89 std::stringstream str_data;
92 auto result = ConsoleUtils::breakStringList(str_data.str(), indentation_, max_lines_, current_column_pos_);
98 if (result.size() == 1)
100 current_column_pos_ += result.back().size();
104 current_column_pos_ = result.back().size();
109 *stream_ << result[0];
110 for (
size_t i = 1; i < result.size(); ++i)
113 *stream_ << result[i];
120 typedef std::ostream& (*StreamManipulator)(std::ostream&);
Color and style the fonts shown on cout/cerr (or other streams)
Definition: Colorizer.h:97
Class for writing data which spans multiple lines with an indentation for each line (all except the f...
Definition: IndentedStream.h:62
std::ostream * stream_
the underlying stream to print to
Definition: IndentedStream.h:130
IndentedStream & operator<<(Colorizer &colorizer)
IndentedStream & operator<<(IndentedStream &self)
Support calling our member functions within a stream.
~IndentedStream()
D'tor flushes the stream.
UInt max_lines_
maximum number of lines a single item is split into before excess lines are replaced by '....
Definition: IndentedStream.h:132
IndentedStream(std::ostream &stream, const UInt indentation, const UInt max_lines)
C'tor.
IndentedStream & operator<<(StreamManipulator manip)
Overload for function pointers, e.g. std::endl.
IndentedStream & indent(const UInt new_indent)
UInt indentation_
number of spaces in prefix of each line
Definition: IndentedStream.h:131
IndentedStream & operator<<(const T &data)
Definition: IndentedStream.h:86
UInt max_line_width_
width of console/output
Definition: IndentedStream.h:133
unsigned int UInt
Unsigned integer type.
Definition: Types.h:94
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:127
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:48