correct indexing for color keys