color: fallback and test label as an effect
With this changeset, we can now send a color name directly to the label
function, e.g.
$ hg log -r . -T "{label('red', node|short)}\n"
--- a/hgext/color.py Mon Apr 07 15:33:46 2014 -0500
+++ b/hgext/color.py Mon Apr 07 15:37:27 2014 -0500
@@ -382,6 +382,8 @@
s = _styles.get(l, '')
if s:
effects.append(s)
+ elif valideffect(l):
+ effects.append(l)
effects = ' '.join(effects)
if effects:
return '\n'.join([render_effects(s, effects)