added duplicate and delete to colorArray
fixed minor bugs