Implemented mouse detection and added switches for different drawing modes - interpolation, dithering, plain, isolines, grid.