Added support for tolerance

Added support to set a tolerance value to the start color to be
colored. Witch can be usefull to solve the problem of not coloring the
border of the shape due to minor color/alpha changes of the initial
color.