Bonjour

je veux définir une fonction qui prend en entré les coordonnées x et y et dessine le point voici ce que j'ai fait jusqu’à maintenant
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
  for (int i = 0; i <= 5; i++) {
      Dimension size = getSize();
      int w = size.width ;
      int h = size.height;
 
      Random r = new Random();
      int x = Math.abs(r.nextInt()) % w;
      int y = Math.abs(r.nextInt()) % h;
      g2d.drawLine(x, y, x, y);
    }
mais les points ne se vois meme pas !!
une idée svp ?