Added function for change width and color painter.