50 likes | 83 Views
Introduction to GUI. Zhen Jiang West Chester University zjiang@wcupa.edu. Outline. Basic items Advanced techniques Exercises. Basic Items. Windows (Code 12-1, p759) JFrame (Code 12-4, p763) Basic components (code 12-5, p766) Label Text field Button Event (Code 12-6, p773)
E N D
Introduction to GUI Zhen Jiang West Chester University zjiang@wcupa.edu
Outline • Basic items • Advanced techniques • Exercises
Basic Items • Windows (Code 12-1, p759) • JFrame (Code 12-4, p763) • Basic components (code 12-5, p766) • Label • Text field • Button • Event (Code 12-6, p773) • Sample (http://www.cs.wcupa.edu/~zjiang/csc142review1.java)
Advanced Techniques • Multiple events (Code 12-8, p783) • Layouts (table 12-5, p766) • Flowlayout (code 12-9, p788) • BorderLayout (code 12-10, p792, sample) • GridLayout (code 12-12, p799) • GridPanel (code 12-13, p801) • Buttons • Radio button (code 12-14, p806) • Check box (code 12-15, p812) • Color (code 12-7, p779) • File System (See the discussion on slides 35-38 in http://www.cs.wcupa.edu/~zjiang/csc141c.ppt)
Complex sample (code 12-16, p819) • More details available at http://www.cs.wcupa.edu/~zjiang/csc142_java_sample.htm. • Group project