1. A non-transitory machine readable medium storing a program which when executed by at least one processing unit edits an image, the image comprising a plurality of pixels having pixel values in a color space, the program comprising sets of instructions for: based on a selected section of pixels of the image, identifying (i) a first portion of the color space and (ii) a second portion of the color space that encloses the first portion, wherein pixels whose pixel values are in the first portion of the color space are fully selected and pixels whose pixel values are in the second portion of the color space are partially selected; displaying a first freely deformable shape in two dimensions of the color space that represents the first portion in the two dimensions of the color space; and displaying a second freely deformable shape that encloses the first freely deformable shape in the two dimensions of the color space and represents the second portion in the two dimensions of the color space, wherein user modification to the first freely deformable shape causes automatic modification to the second freely deformable shape in order to maintain that the second freely deformable shape encloses the first freely deformable shape in the color space.