CSC113_Lab8 - King Saud University College of Computer and...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
King Saud University College of Computer and Information Systems, Department of Computer Science CSC 113: Java Programming-II, Spring2011 Lab#8 : GUI Write a java program that can show the following working interface. This program represents a Burger Shop that can calculate the price of the burger depending upon its ingredients and size. The price of each option is given in parenthesis. Please note that there is no button to hit to calculate the price. Every time User clicks on radio button or check box, the price is updated in the text field. For more detail, please see the procedure after the GUI images. User has chosen Honey and Beef and the size of burger is small. The total amount according to this selection is 15+40+20=75 User has chosen Cheese , Honey , Beef and ketchup and the size of burger is medium. The total amount according to this selection is 10+15+40+5+30=100
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: King Saud University College of Computer and Information Systems, Department of Computer Science CSC 113: Java Programming-II, Spring2011 Lab#8 : GUI • User has chosen Cheese , Beef and ketchup and the size of burger is large. The total amount according to this selection is 10+40+5+40=95 Procedure: Create a class “ BurgerShop ” . JFrame will be the super class of this class and this class will also implement the ItemListener interface to implement the event handler. Add attributes of type JCheckBox, JRadioButton , JTextField and JLabel to Design the above interface. Layout Manager for the above GUI is GridLayout with 5 rows and 4 columns. You can choose some other Layout also. You can also add attributes and methods to implement the functionality. Create a Test(Main) Class to run the show....
View Full Document

Page1 / 2

CSC113_Lab8 - King Saud University College of Computer and...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online