Closed tommilligan closed 7 years ago
Have fixed syntax error in my suggestion, build is now failing due to existing work on the dev
tree.
Let me know if you have any feedback!
I just looked at your code and it seems okay to me for as it is. Although for changelog and history cleanliness, I'll have to fold the 3 commits in one and reformat the summary line. There seems to be a dangling issue on travis here that might be unrelated to your code as I understand it (in the last travis build, the python 2 version would fail because of PyPI being not responsive, but the python 3 build was not trivial and might be unrelated also to your code.) I'll have to check this as soon as possible (but now I need to go to bed :) ). Many thanks for your interests and this PR.
Added
invert
attribute to theColor
class. All current colour atributes are supported (I think). Hue is rotated x+0.5, all other attributes are 1-x type inversion.Takes one argument (the attribute to invert), toabi I agree it's a bit more complex but I'd prefer to be at least able to choose hue, rgb or hsl to invert, if not every attribute.
Usage:
New attribute inversions can be supported by adding to the dictionary/lists just after attribute declaration. If attribute not recognised, ValueError will be raised.
Also wanted to say thanks vaab for a great module!