Java basics-GUI programming (2), java basics gui Programming
I. event listening Mechanism
-- Event Source: the graphical components in the awt or swing package, that is, the components in which the event occurs.
-- Event: An opera
Java basics-GUI programming (1), java basics gui Programming
I. Definition
The full name of GUI is Graphical User Interface, that is, Graphical User Interface. JDK provides two packages
Java gui programming Overview Study Notes (22), gui Study Notes
The following content is my study notes on the java video tutorial of Miss Bi Xiangdong!
Java gui programming:Windows
1. First, let's look at my needs, as follows:control text box can only enter numeric characters2. Source code:
Packagecn.itcast_07;Importjava.awt.FlowLayout;ImportJava.awt.Frame;ImportJava.awt.Label;ImportJava.awt.TextField;ImportJava.awt.event.KeyAdapter;Importjava.awt.event.KeyEvent;ImportJava.awt.event.WindowAdapter;Importjava.awt.event.WindowEvent;/** If you enter a non-numeric character, the effect of your keyboard entry will be canceled. */ Public classFramedemo { Public Static voidMa
1. First: Menu componentsMenubar,menu,menuitemCreate a menu bar, create a menu, and set up menu items in each menu.The menu can also be added to the menu as a submenu.Add a menu to the frame by using the Setmenubar () method.2. Case code: Packagecn.itcast_08;Importjava.awt.FlowLayout;ImportJava.awt.Frame;ImportJava.awt.Menu;ImportJava.awt.MenuBar;ImportJava.awt.MenuItem;Importjava.awt.event.ActionEvent;ImportJava.awt.event.ActionListener;ImportJava.awt.event.WindowAdapter;Importjava.awt.event.Wi
API XXX", such as "Site:docs.oracle.com Java API JTextField"3. Summarize the working principle of Java event-driven, refer to and rewrite the textbook example 6-1 (p115-116), rewrite the applet as JFrame.
4. Why do I need to "knock" code? See Bowen to all BBS students: How to learn a good way. It's easier to go to the stupid method of Python. Item Two: Picture displayObjective: To understand the common way
Item Two: Picture DisplayObjective: To understand the common way of GUI image display. Goal: Use project one to get the image file that needs to be displayed, and display it on the interface (see: What controls are used in the Java swing to load a picture?), Java programming 14th Week of experiment:
for all levels of Java programmers to read, but also the University of the teaching of object-oriented programming language and the Java language of the excellent teaching materials and reference books."Recommended Reasons"This book has won wide acclaim from the world's programmers, even the most obscure concepts, in
Reprinted:
The most painful thing to learn about Java is the choice of future career directions. Especially when developing Java applications or Java Web, there are still a few small classes that you can't learn after you set the category.
Therefore, as a beginner, you must read this article. You will learn how to learn J
Sold out ~~!!!
I flipped through two more books and added a total of five books to the previous one. Let's take a look ~~
Are Dangdang buy genuine, put me here a little waste, anyway, certainly cheap, trading way we Q chat: 423257356 (note to buy a book), mail: zhangyue0503@sohu.com ~~~
1... NET FrameworkProgramDesign (revision)
. NET Framework programming
Http://www.cnblogs.com/dugang/archive/2010/10/22/1858478.htmlAwtAWT is the abbreviation for the abstract window Toolkit (Abstraction Windows Toolkit), which is the earliest and original development kit that Sun has dedicated to Java GUI programming to build and set up the Java graphical user interface, This toolkit pro
Reprinted:
Ii. Advanced Java programming
IntendProgramProgrammers who have made a living should continue to learn Java reconstruction and framework after the basic java entry-level in the semester. To lay a good Java Foundation, more practical experience is needed. I don't
3. java gui Programming Frame window, 3. javaguiframe
Create a graphical interface:
1. Create a frame form;
2. Perform basic settings on the form;
Such as size, location, Layout
3. Define components;
4. add the component to the form using the add method;
5. display the form using setVisible (ture ).
------------------------------
Create a new class named studyfra
The day before yesterday to introduce you to the Java beginners should learn which foundation, is also the United States Network small series from the Java three general direction: J2SE, J2ME, and we do the Outlook analysis, these two days also received a lot of feedback from everyone, Many small partners looked at their own Java
GUI, Graphics User Interface, graphical User Interface. GUI intuitively presents the functions of the computer to the user, and the GUI is more intuitive and easy to accept.
The GUI must be supported by the operating system and hardware. Therefore, GUI
Java GUI programming: coin gamePreface: I am very interested in learning java se GUI programming. I don't know why the teacher told me not to spend too much time on GUI
Java GUI programming (Graphic user Interface, graphical user interface) is implemented on its Abstract Window Toolkit (abstract Windows TOOLKIT,AWT). java.awt is the AWT Tool class library, which includes rich graphics, user interface components, and layout manager support.
The GUI is mainly used in two places:
Appli
Earlier procedures used the simplest input and output methods, the user input data in the keyboard, the program will output information on the screen. Modern procedures require the use of graphical user interface (graphical user Interface,gui), the interface has a menu, buttons, etc., the user through the mouse to select the menu options and click the button, command program function module. This chapter learns how to write
.(3) upward development. It's a design-level book.Suggest to see "Head First design mode", "Grinding design mode", "Gof design mode", "Reconstruction", "Enterprise design mode" and so on books, of course, these books for the first graduate of the small partners can not need to pay too much attention. Wait until you have three years experience to further study. This will be more profound (listen to what the
java.awt.event.*;import java.util.*;p ublic class Mymouseadapter {public static void main ( String[] (args) {new MyFrame ("Drawing ...");}} Class MyFrame extends Frame {arraylist"Window Event"The event class corresponding to window time is windowevent, and the corresponding event listener interface is WindowListener.The methods defined by WindowListener are:public void windowopened (WindowEvent e)public void windowclosing (WindowEvent e)public void windowclosed (WindowEvent e)public void window
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.