diff --git a/src/columns/Column.cpp b/src/columns/Column.cpp index e4b477ac3..963117367 100644 --- a/src/columns/Column.cpp +++ b/src/columns/Column.cpp @@ -292,3 +292,27 @@ void Column::renderDouble ( } //////////////////////////////////////////////////////////////////////////////// +void Column::renderStringLeft ( + std::vector & lines, + int width, + Color& color, + const std::string& value) +{ + lines.push_back ( + color.colorize ( + leftJustify (value, width))); +} + +//////////////////////////////////////////////////////////////////////////////// +void Column::renderStringRight ( + std::vector & lines, + int width, + Color& color, + const std::string& value) +{ + lines.push_back ( + color.colorize ( + rightJustify (value, width))); +} + +//////////////////////////////////////////////////////////////////////////////// diff --git a/src/columns/Column.h b/src/columns/Column.h index 2ff7712f1..903f2db7a 100644 --- a/src/columns/Column.h +++ b/src/columns/Column.h @@ -66,8 +66,10 @@ public: virtual std::string modify (std::string& input) { return input; }; protected: - void renderInteger (std::vector &, int, Color&, int); - void renderDouble (std::vector &, int, Color&, double); + void renderInteger (std::vector &, int, Color&, int); + void renderDouble (std::vector &, int, Color&, double); + void renderStringLeft (std::vector &, int, Color&, const std::string&); + void renderStringRight (std::vector &, int, Color&, const std::string&); protected: std::string _name;