Skip to content
Snippets Groups Projects
Commit 2f7f138c authored by koz01's avatar koz01
Browse files

font

parent f03144cb
No related merge requests found
......@@ -4,6 +4,8 @@ import javafx.animation.AnimationTimer;
import javafx.scene.canvas.Canvas;
import javafx.scene.canvas.GraphicsContext;
import javafx.scene.paint.Color;
import javafx.scene.text.Font;
import javafx.scene.text.FontWeight;
public class DrawingThread extends AnimationTimer {
......@@ -34,6 +36,10 @@ public class DrawingThread extends AnimationTimer {
y += speed * deltaT;
}
previousTime = now;
gc.setFill(Color.BLUE);
gc.setFont(Font.font("Sans Serif", FontWeight.BOLD, 50));
gc.fillText("0", 10, 70);
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment