63 std::stringstream str_data;
66 auto result = ConsoleUtils::breakStringList(str_data.str(), indentation_, max_lines_, current_column_pos_);
72 if (result.size() == 1)
74 current_column_pos_ += result.back().size();
78 current_column_pos_ = result.back().size();
83 *stream_ << result[0];
84 for (
size_t i = 1; i < result.size(); ++i)
87 *stream_ << result[i];
94 typedef std::ostream& (*StreamManipulator)(std::ostream&);
Color and style the fonts shown on cout/cerr (or other streams)
Definition: Colorizer.h:71
Class for writing data which spans multiple lines with an indentation for each line (all except the f...
Definition: IndentedStream.h:36
std::ostream * stream_
the underlying stream to print to
Definition: IndentedStream.h:104
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:106
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:105
IndentedStream & operator<<(const T &data)
Definition: IndentedStream.h:60
UInt max_line_width_
width of console/output
Definition: IndentedStream.h:107
unsigned int UInt
Unsigned integer type.
Definition: Types.h:68
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:101
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:22