ansi.py: define sgr attributes as ints not strings, simplify render