debugging legend generation for auto-colors