Added functionalities for coloring pixel and vertical and horizontal segments