Skip to content
Snippets Groups Projects
Commit b8dc2b1f authored by SAYEH Nahlane ghina's avatar SAYEH Nahlane ghina
Browse files

modification de ShapeContainer

creation de AbstractShape
creation de Polygon,BorderDecorator et CenterDecorator
parent cad426c7
No related branches found
No related tags found
No related merge requests found
......@@ -12,6 +12,7 @@ import javafx.stage.Stage;
public class App extends Application {
public static void main(String[] args) {
......@@ -26,10 +27,14 @@ public class App extends Application {
ShapeContainer shapeContainer = new ShapeContainer();
graphicsContext.setFill(Color.AQUAMARINE);
graphicsContext.fillOval(10,10,10,10);
shapeContainer.addShape(new Rectangle(Color.BLUE,new Point2D(10,10), new Point2D(40,40)));
shapeContainer.add(new Rectangle(Color.BLUE,new Point2D(10,10), new Point2D(40,40)));
shapeContainer.draw(graphicsContext);
root.getChildren().add(canvas);
primaryStage.setScene(new Scene(root));
primaryStage.show();
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment