Color: Improve colorize() performance

- Improves "render" time by ~45-55% across relevant performance tests.
- Improves "list" performance test by ~20%.
- Improves "all" performance test by ~40%.
This commit is contained in:
Wilhelm Schuermann
2015-10-31 12:05:36 +01:00
parent 5b2328cd6c
commit 3e8cb20284
3 changed files with 77 additions and 27 deletions

View File

@@ -61,6 +61,7 @@ public:
std::string colorize (const std::string&);
static std::string colorize (const std::string&, const std::string&);
void _colorize (std::string&, const std::string&);
static std::string strip (const std::string&);
bool nontrivial () const;