반응형 자바101 자바 소스코드: 탭팬 만들기 package javaapplication49; import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; class TabbedPaneEx extends JFrame{ TabbedPaneEx(){ this.setTitle("탭팬 만들기 예제"); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); JTabbedPane pane=createTabbedPane(); this.add(pane, BorderLayout.CENTER); this.setSize(250, 250); this.setVisible(true); } JTabbedPane createTabb.. 2016. 12. 22. 자바 소스코드: JColorChooser 만들기 package javaapplication48; import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; class MenuAndColorChooserEx extends JFrame{ JLabel label = new JLabel("Hello"); MenuAndColorChooserEx(){ this.setTitle("JColorChooser 예제"); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); label.setHorizontalAlignment(SwingConstants.CENTER); label.setFont(new Font("Ravie",.. 2016. 12. 22. 자바 소스코드: Menu와 JFileChooser 활용 예제 package javaapplication47; import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.filechooser.*; import javax.swing.event.*; class MenuAndFileDialogEx extends JFrame{ JLabel la = new JLabel(); MenuAndFileDialogEx(){ this.setTitle("Menu와 JFileChooser 활용 예제"); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); this.add(la); createMenu(); this.setLocationRelativeTo(n.. 2016. 12. 22. 자바 소스코드: 옵션 팬 만들기 package javaapplication46; import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; class OptionPaneEx extends JFrame{ OptionPaneEx(){ this.setTitle("옵션 팬 예제"); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); this.setSize(500, 200); this.add(new MyPanel(), BorderLayout.NORTH); this.setVisible(true); } class MyPanel extends JPanel{ JButton inputBtn= new J.. 2016. 12. 22. 이전 1 2 3 4 ··· 26 다음 반응형