protected void draw() {
		GraphicsContext gc = this.getGraphicsContext2D();
		//clear area with white
		gc.setFill(Color.WHITE);
		gc.fillRect(0, 0, this.getWidth(), this.getHeight());
		//draw debug lines
		gc.setStroke(Color.RED);
		gc.strokeLine(0, 0, this.getWidth(), this.getHeight());
		gc.strokeLine(this.getWidth(), 0, 0, this.getHeight());
		//animate and draw symbols
		gc.setFill(Color.BLACK);
		for (int i = 0; i < mainPanel.symbolsCount.intValue(); i++) {
			BaseSymbol symbol = symbols.get(i);
			symbol.x += symbol.dirX * 5;
			symbol.y += symbol.dirY * 5;
			if (symbol.x < 0)
				symbol.dirX = Math.abs(symbol.dirX);
			if (symbol.y < 0)
				symbol.dirY = Math.abs(symbol.dirY);
			if (symbol.x > getWidth())
				symbol.dirX = -1 * Math.abs(symbol.dirX);
			if (symbol.y > getHeight())
				symbol.dirY = -1 * Math.abs(symbol.dirY);
			symbol.draw(gc);
		}
		//measure FPS
		frameCount++;
		long currentTime = System.nanoTime();
		if (currentTime > lastSecondStart + 1000000000) {
			int fps = frameCount;
			frameCount = 0;
			lastSecondStart = currentTime;
			mainPanel.onFPSChange(fps);
		}
	}