@Override
	protected void paintComponent(Graphics g) {
		if (numLines != -1) {
			System.out.println("Painting");
			
			if (numLines < currentNumLines) {	//We have to clear the grid
				g.clearRect(0, 0, WIDTH, WIDTH);
			}
			int gap = 512/numLines;
			g.setColor(Color.white);
			for (int i=0; i < 512; i+= gap) {
				//System.out.println("Making lines");
				g.drawLine(i, 0, i, 512);
				g.drawLine(0, i, 512, i);
			}
		}
	
	}