color class constructor, and simplify the class