CPSC150 Java Lynn Lambert Create your own GUI From lab3 From lab3 Build an empty Window with 4 button Build an empty Window with 4 button Each button should.

Slides:



Advertisements
Similar presentations
Introduction to Programming Java Lab 1: My First Program 11 January JavaLab1.ppt Ping Brennan
Advertisements

 Base “primitive” types: TypeDescriptionSize intThe integer type, with range -2,147,483, ,147,483,647 4 bytes byteThe type describing a single.
Unit 3 Graphical User Interface (GUI) Dr. Magdi AMER.
Building Applications Dialogs Passing data between windows Validating Input using FocusListeners.
 What are the basic GUI components we’ve learned so far? › JFrame › JPanel › JButton › JLabel › JTextArea › JTextField › JCheckBox › JRadioButton › Paint.
Chapter 6 Graphical User Interface (GUI) and Object-Oriented Design (OOD)
Using JOptionPanes for graphical communication with our programs. Pages Horstmann 139.
Lecture 15 Graphical User Interfaces (GUI’s). Objectives Provide a general set of concepts for GUI’s Layout manager GUI components GUI Design Guidelines.
Introduction to Computers and Programming Lecture 3: Variables and Input Professor: Evan Korth New York University.
School of Computing Science CMT1000 Ed Currie © Middlesex University Lecture 4: 1 CMT1000: Introduction to Programming Ed Currie Lecture 5a: Input and.
CPSC150 Week 12 Graphical User Interfaces Chapter 11.
CPSC150 JavaLynn Lambert CPSC150 Week 12 InheritanceInterfaces.
10.1 AWT The AWT classes Users today expect a Graphical User Interface (GUI) Improves application usability Difficult to implement cross-platform.
GUI Programming in Java Tim McKenna GUI Programming Concepts l conventional programming: sequence of operations is determined by the program.
GUI Basics: Introduction. Creating GUI Objects // Create a button with text OK JButton jbtOK = new JButton("OK"); // Create a label with text "Enter your.
Programming With Java ICS201 University Of Ha’il1 Chapter 17 Graphical User Interfaces Swing I.
JLabel, JTextField, JButton and JOptionPane
Karel J Robot An introduction to BlueJ and Object- Oriented Programming.
Intro to GUIs (Graphical User Interfaces) Section 2.5Intro. to GUIs: a GUI Greeter Section 3.7Graphical/Internet Java: Einstein's Equation.
Introduction to GUI in Java 1. Graphical User Interface Java is equipped with many powerful,easy to use GUI component such as input and output dialog.
Java Programming, Second Edition Chapter Five Input and Selection.
Programming Fundamentals 2: Simple/ F II Objectives – –give some simple examples of Java applications and one applet 2. Simple Java.
Timer class and inner classes. Processing timer events Timer is part of javax.swing helps manage activity over time Use it to set up a timer to generate.
Object Oriented programming Instructor: Dr. Essam H. Houssein.
POS 407 Assignments Emilio Yanine. Workshop 3 Programming Assignment Implement FHiLo as an Applet, call it JHiLo2.java Modify applet to use multiple JPanels.
CS Fall 2012, Lab 09 Haohan Zhu. Boston University Slideshow Title Goes Here CS Fall 2012, Lab /20/2015 GUI - Graphical User Interface.
Programming with Java’s Swing API February 4, 2003 CMPS Advanced Programming Graphical User Interfaces.
CS1054: Lecture 21 - Graphical User Interface. Graphical User Interfaces vs. Text User Interface.
CS 4244: Internet Programming User Interface Programming in Java 1.0.
Graphical User Interfaces. Graphical input and output with JOptionPane.
GUI Graphical User Interface Each onscreen component and window is an object Object interaction makes communication and scoping challenging Event-driven.
Adding a Link List Blogger TLDE. First, you should: Log in to Gmail At the top, click “More” and select “Blogger”
Basics of GUI Programming Chapter 11 and Chapter 22.
Graphical User Interfaces Tonga Institute of Higher Education.
Compiling and running Java programs with BlueJ. Successfully compiled files program files in BlueJ You can tell from the shade of a program icon in BlueJ.
Computer Science [3] Java Programming II - Laboratory Course Lab 4 -1 : Introduction to Graphical user interface GUI Components Faculty of Engineering.
SE-1020 Dr. Mark L. Hornick 1 Graphical User Interfaces.
JAVA: An Introduction to Problem Solving & Programming, 6 th Ed. By Walter Savitch ISBN © 2012 Pearson Education, Inc., Upper Saddle River,
CPSC 871 John D. McGregor Module 8 Session 3 Assignment.
Lecture 33: More Graphical User Interface (GUI) Announcements & Review Read Ch GU1 & GU2 Cohoon & Davidson Ch 14 Reges & Stepp Lab 10 set game due 4/26.
Creating and Using Dialogs ● A dialog is a box that pops up and prompts the user for a value or informs them of something ● One way: directly create objects.
Event Handler Methods Text field Object Responder JAVA AWT Environment: Messages are sent between JAVA Objects Screen Event Notification Press Button.
CIS 270—Application Development II Chapter 11—GUI Components: Part I.
Introduction to GUI in 1 Graphical User Interface Nouf Almunyif.
12-Jun-16 Event loops. 2 Programming in prehistoric times Earliest programs were all “batch” processing There was no interaction with the user Input Output.
Event Driven (Asynchronous) Programming. Event handling in Unity Subclass a class that contains event handling methods, and then override those methods.
Prepared by: Dr. Abdallah Mohamed, AOU-KW Unit 6 Graphical user interfaces 1.
A Quick Java Swing Tutorial
Java GUI.
Event loops 16-Jun-18.
Section 64 – Manipulating Data Using Methods – Java Swing
Lecture 27 Creating Custom GUIs
Ellen Walker Hiram College
Timer class and inner classes
CS18000: Problem Solving and Object-Oriented Programming
Flooding © 2018.
Chapter 2 - Introduction to Java Applications
Event loops.
Event loops 17-Jan-19.
Event loops 17-Jan-19.
GUI Test Information.
Event loops 8-Apr-19.
Java Programming with BlueJ Objectives
Ch. No Name Marks 01 AWT Networking JDBC Swing 05
Ch. No Name Marks 01 AWT Networking JDBC Swing 05
F II 2. Simple Java Programs Objectives
Event loops.
Event loops 19-Aug-19.
TA: Nouf Al-Harbi NoufNaief.net :::
Presentation transcript:

CPSC150 Java Lynn Lambert Create your own GUI From lab3 From lab3 Build an empty Window with 4 button Build an empty Window with 4 button Each button should pop up a different kind of JOptionPane Each button should pop up a different kind of JOptionPane

CPSC150 Java Lynn Lambert Adding JOptionPanes Go to ng/package-summary.html Go to ng/package-summary.html ng/package-summary.html ng/package-summary.html Find JOptionPane and read it Find JOptionPane and read it Create the following 4 types of JOptionPanes Create the following 4 types of JOptionPanes a showConfirmDialog a showConfirmDialog a ShowInputDialog (print the resulting message using System.out.println) a ShowInputDialog (print the resulting message using System.out.println) a ShowMessageDialog a ShowMessageDialog a showOptionDialogu a showOptionDialogu

CPSC150 Java Lynn Lambert More Add icons to the JOptionPane Add icons to the JOptionPane (you can find ones you like or use jpegs in your programming assignments) Go back to your original button window. Use different layout managers to arrange them Go back to your original button window. Use different layout managers to arrange them Add a JLabel to the bottom of your button window Add a JLabel to the bottom of your button window Loop up another component (e.g., JRadioButton) and implement it Loop up another component (e.g., JRadioButton) and implement it

CPSC150 Java Lynn Lambert Finally turn in your blueJ code as classwork assignment 6 turn in your blueJ code as classwork assignment 6