removed code duplication

involving calculate of area of voronoi cells

moved to inside the painting method