auto invert colors for different groups
delete rarely used code