added check for invalid colours

(0) -10 -1 +1 +10 +30 +100 tip

mercurial