Session Details
Week 2,
Session 5 — Thu Mar 18
Reading
-
Big Java, §2.11–2.13
HW Due
-
HW 4
Topics
-
Implementing Classes in Java
-
Introduction to Java GUIs
- Swing: JFrame, JComponent, how to draw Shapes in a JComponent
Resources
-
Slides
-
SwingDemo1 instructions: optional if you want more details or want to work independently.
Outline
-
[5 min] Questions
-
[15 min] Review WordGames, including Review Quiz on Implementing Classes
-
[30 min] More transformers in WordGames
-
[5 min] Break
-
[50 min] A first Java graphics program
- Live coding of a JFrame that adds a class that extends JComponent
- Live coding of overriding paintComponent to draw various Shapes
- See SwingDemo1 for detailed instructions of the live coding if you want them
HW Assigned
-
HW 5