resolving a bug with color gradient