A class for generating gradients