erwan arrete de copier mon git

This commit is contained in:
Vieira Enzo 2022-02-14 16:11:04 +01:00
parent 70c2cf6f54
commit 2c8304e303
6 changed files with 4 additions and 3 deletions

Binary file not shown.

Binary file not shown.

View File

@ -14,8 +14,8 @@ public class Paintsablier extends JComponent {
secondPinceau.fillRect(0, 0, this.getWidth(), this.getHeight());
}
secondPinceau.setColor(Color.CYAN);
for (int i=0; i<(this.getWidth()/50); i++) {
for (int j=0; j<(this.getHeight()/50); j++) {
for (int i=0; i<5; i++) {
for (int j=0; j<5; j++) {
secondPinceau.fillPolygon(new int[] {25+i*50,50+i*50,25+i*50,0+i*50},new int[] {-25+j*50,0+j*50,25+j*50,0+j*50},4);
}
}

Binary file not shown.

View File

@ -3,8 +3,9 @@ import java.awt.*;
public class Sablier {
public static void main(String[] args) {
JFrame fenetre = new JFrame();
fenetre.setSize(500, 500);
fenetre.setSize(260, 260);
fenetre.setLocation(100, 100);
fenetre.setResizable(false);
fenetre.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
Paintsablier draw = new Paintsablier();
fenetre.add(draw, BorderLayout.CENTER);