Accéder au contenu principal

Articles

Affichage des articles du octobre, 2018

Java swing Forme graphiue 2D et Animation thread et Timer

import java.awt.EventQueue; import javax.swing.JFrame; import javax.swing.JPanel; import java.awt.BorderLayout; import java.awt.Color; import java.awt.FlowLayout; import java.awt.Panel; import javax.swing.GroupLayout; import javax.swing.GroupLayout.Alignment; import javax.swing.JMenuBar; import javax.swing.JMenuItem; import javax.swing.JMenu; import java.awt.event.ActionListener; import java.awt.event.ActionEvent; import javax.swing.event.ChangeListener; import javax.swing.event.MenuEvent; import javax.swing.event.MenuListener; import javax.swing.event.ChangeEvent; //devlopper par mzili toufik import java.awt.event.ItemListener; import java.awt.event.ItemEvent; public class dis extends JFrame{    dis(){ this.setBounds(100, 100, 450, 300); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); pan panel = new pan(); getContentPane().add(panel, BorderLayout.CENTER); JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JM...