Color: Remove support for underscores in color values

Values like 'on_red' will no longer work.

This feature has been deprecated since 2009.
This commit is contained in:
Tomas Babej 2015-09-03 21:54:27 +02:00 committed by Paul Beckingham
parent 8536dc9658
commit 99b650a3ba

View file

@ -100,11 +100,7 @@ Color::Color (const std::string& spec)
: _value (0)
{
#ifdef FEATURE_COLOR
// By converting underscores to spaces, we inherently support the old "on_red"
// style of specifying background colors. We consider underscores to be
// deprecated.
std::string modifiable_spec = spec;
std::replace (modifiable_spec.begin (), modifiable_spec.end (), '_', ' ');
// Split spec into words.
std::vector <std::string> words;