COSC 3461 – Section M – Winter 2002
User Interfaces

Instructor: Scott MacKenzie, CSB 3045, Office Hours: TR 9-10 a.m.

Last update: 20-Apr-02

 

Main page for 3461


Apr 19, 2002 – Grades for Assignment #3 now posted.


Apr 19, 2002 – Note:  The duration of the final exam has been changed slightly.  The exam will be 2.5 hours, starting at 19:00 and finishing at 21:30.


Apr 5, 2002 – Here are the TA office hours leading up to the final exam:

 

            Friday, Apr 19, 13:00 - 14:00, Szymon Stachniak, CSB 3017

            Sunday, Apr 21,  13:00 - 14:00, Andriy Pavlovych, CSB 2057 (Note: campus parking is free on Sundays)

            Monday, Apr 22, 13:00 - 14:00, Yang Yang, CSB 1006C


Apr 4, 2002 – Click to download the power point slides from today’s class: Course Summary


Apr 4, 2002 – Here are professor MacKenzie’s office hours during the exam period:

 

Thurs, Apr 11, 9:00 – 11:00 a.m., CSB 3045

Thurs, Apr 18, 9:00 – 11:00 a.m., CSB 3045


Apr 2, 2002 – Click to download power point slides from today’s class: The Two-handed Desktop Interface: Are We There Yet?


Apr 1, 2002 – An extra slot of TA office hours has been booked for this Thursday (no fooling!):

 

            Thurs, Apr   4, 12:00 - 14:00, Andriy Pavlovych, CSB 2057


Mar 28, 2002 – Here are the power point slides from today’s class: Design Principles and Guidelines: Hints for Good Design


Mar 27, 2002 – Here are the data files that are used in the example invocations of DemoTable: quotations.txt | worldrecordsmen.txt | worldrecordswomen.txt | d1-wordfreq.txt


Mar 26, 2002 – Click to download recent power point slides: Designing for Humans: What Went Wrong | Designing for Humans: Human Limits and Capabilities | Readings from the Swing Tutorial


Mar 21, 2002 – TA office hourse for Assignment #3:

 

            Wed, Mar 27        17:00 - 19:00     Szymon Stachniak      CSB 3017

            Mon, Apr   1         12:00 - 14:00     Andriy Pavlovych       CSB 2057

            Wed, Apr   3         9:30 - 11:30       Yang Yang                  CSB 1006C


Mar 19, 2002 – To download the source code for Java 1.3.1 go to http://java.sun.com/j2se/1.3/


Mar 19, 2002Click here to download the second set of PPT slides from today’s class, “Crash Course on Usability Testing”


Mar 19, 2002Click here to download the first set of PPT slides from today’s class, “Design for Humans - SR Compatibility”


Mar 14, 2002 – Grades for Assignment #2 now posted.


Mar 14, 2002 – Required reading: A Swing architecture overview: The inside story on JFC component

design by Amy Fowler


Mar 14, 2002 – Here are the demo programs from today’s class: DemoTree.java | DemoTree-1.gif | DemoTree-2.gif | DemoTree2.java | DemoTree2-1.gif | DemoTree2-2.gif | DemoTree2-3.gif | DemoCustomButtonUI.java | DemoCustomButtonUI-1.gif | DemoCustomButtonUI-2.gif | DemoCustomButtonUI-3.gif


Mar 14, 2002Click here to download the PPT slides from this week’s classes, “Model-View Controller”


Mar 12, 2002 – Here are the demo programs from today’s class: DemoTable2.java | DemoInputValidation3.java | DemoLookAndFeel.java | DemoLookAndFeel-1.gif | DemoLookAndFeel-2.gif | DemoLookAndFeel-3.gif | DemoLookAndFeel-4.gif | DemoTable3.java | DemoTable3-1.gif | DemoTable3-2.gif | DemoTable3-3.gif


Mar 7, 2002Click here to download the PPT files from today’s class, “Output Model”


Mar 7, 2002 – Here are the demo programs from today’s class: DemoImage.java | DemoImage.gif | DemoImage2.java | DemoImage2.gif | varihall.jpg | DemoList3.java | DemoList3-1.gif | DemoTimer.java |  DemoTimer-1.gif | DemoTimer-2.gif | clouds-1.gif | spaceship-1.gif | spaceship-2.gif


Mar 7, 2002Programming Challenge SolutionPC_LayoutExample.java | PC_LayoutExample-1.gif | PC_LayoutExample-2.gif


Mar 7, 2002 – Assignment #3 now posted. See the course’s main web page for details.


Mar 5, 2002 – Here are the demo programs from today’s class: DemoPaintPanel.java | DemoPaintPanel-1.gif | DemoPaintPanel2.java | DemoPaintPanel2-1.gif | DemoPaintPanel2-2.gif | DemoPaintPanel3.java | DemoMouseInk.java | DemoMouseInk-1.gif | DemoMouseUnistrokes.java | DemoMouseUnistrokes-1.gif |DemoMouseUnistrokes-2.gif | Unistroke.class | StrokeDef.class


Mar 5, 2002Programming Challenge SolutionPC_SizeProperties.java | PC_SizeProperties-1.gif


Feb 28, 2002Programming Challenge – Please see slide #43 from today’s lecture “Laying Out Components”


Feb 28, 2002Click here to download the PPT files from today’s class, “Laying Out Components”


Feb 28, 2002 – Here are the demo programs from today’s class, plus DemoComboBox2 that I forgot to post earlier: DemoBoxLayout.java | DemoBoxLayout-1.gif | DemoBoxLayout-2.gif | DemoBoxLayout-3.gif | DemoSizeControl.java | DemoSizeControl-1.gif | DemoSizeControl-2.gif | DemoSizeControl-3.gif | DemoSizeControl-4.gif | DemoSizeControl-5.gif | DemoComboBox2.java | DemoComboBox2-1.gif | DemoComboBox2-2.gif | DemoComboBox2-3.gif


Feb 28, 2002Programming Challenge – Make a copy of DemoSizeProperties.java and rename it PC_SizeProperties.java.  Modify the program to present the output in a JTable, rather than sending it to the console.  For each component, the JTable should contain the component’s name, class, and its preferred, minimum, and maximum size properties.


Feb 27, 2002 – Some readings you may find useful for learning to work with images and graphics include Amy Fowler’s article Painting in AWT and Swing and the lesson Working with Graphics in the Swing tutorial


Feb 26, 2002 – Midterm marks now posted.


Feb 26, 2002 – Here are the demo programs from today’s class: DemoSizeProperties.java | DemoSizeProperties-1.gif | DemoSize.java | DemoSize-1.gif | DemoSize-2.gif | DemoSize-3.gif | DemoPosition.java | DemoAbsolute.java | DemoAbsolute-1.gif | DemoBorderLayout.java | DemoBorderLayout-1.gif | DemoBorderLayout-2.gif |  DemoFlowLayout.java | DemoFlowLayout-1.gif | DemoFlowLayout-2.gif | DemoGridLayout.java | DemoGridLayout-1.gif | DemoGridLayout-2.gif


Feb 25, 2002 – The date, time, and location for the final exam are now set.  See the course’s main page for details.


Feb 23, 2002Click here to view some comments on the grading for Assignment #1.


Feb 20, 2002 – Here are the TA office hours for Assignment #2:

 

            Wed, Feb 27         17:00 - 19:00     Szymon Stachniak      CSB 3017

            Mon, Mar  4         12:00 - 14:00     Andriy Pavlovych       CSB 2057

            Wed, Mar  6         9:30 - 11:30       Yang Yang                  CSB 1006C


Feb 19, 2002 – Here are the demo programs and support files from today’s class:  DemoScrollPane.java | DemoScrollPane-1.gif | map.gif | DemoScrollPane2.java | DemoScrollPane2-1.gif | hockeyplayer.gif | logo.jpg | DemoList.java | DemoList-1.gif | DemoList2.java | DemoList2-1.gif | DemoListMultiple.java | DemoListMultiple-1.gif | DemoTable.java | DemoTable-1.gif | DemoTable-2.gif | DemoTable-3.gif | DemoTable2.java


Feb 18, 2002 – A note has been added to Assignment #2’s requirements, re creating an initial puzzle configuration that is guaranteed to be solvable.


Feb 18, 2002 – Grades for Assignment #1 now posted.  To view your grade, login to Ariel and issue the command

 

      courseInfo 3461M 2001-02 W

      

Note: Each group will soon (probably today) receive an email message from the TA explaining the breakdown of your mark.


Feb 14, 2002Click here to download the PPT slides for the topic we are currently studying – “Widgets”


Feb 14, 2002DemoCustomDialog.java – This is another demo program that relates to work previously discussed. It follows on from DemoFileChooser.java. Related files: DemoCustomDialog-0.gif | DemoCustomDialog-1.gif | DemoCustomDialog-2.gif | DemoCustomDialog-3.gif


Feb 14, 2002DemoFileMenu.java – This is another demo program that relates to work previously discussed. It follows on from DemoMenu2.java.  Related files: DemoFileMenu-1.gif | DemoFileMenu-2.gif | new.gif | open.gif | close.gif | save.gif | blank.gif


Feb 13, 2002 – A note has just been added to Assignment #2’s requirements.  Do not use the york package!


Feb 12, 2002 – Note: The due date for Assignment #2 has been pushed back one week.  It is now due on March 8.


Feb 7, 2002 – Here are the demo programs from today’s class: DemoTextField.java | DemoTextField.gif | DemoFileChooser.java | DemoFileChooser-1.gif | DemoSliderBB.java | DemoSliderBB-1.gif | DemoSlider.java | DemoSlider-1.gif | DemoScrollBarBB.java | DemoScrollBarBB-1.gif


Feb 6, 2002 – Date for midterm exam now set.  See the main course web page for details.


Feb 6, 2002 – Assignment #2 now posted.  See the main course web page for details.


Feb 5, 2002 – Here are the demo programs from today’s class, along with screen snaps for the API: DemoToolBar.java | DemoToolBar.gif | DemoMessageBox.java | DemoMessageBox.gif | DemoInputValidation1.java | DemoInputValidation1-1.gif | DemoInputValication2.java

 

As well, you’ll need the following image files for the button icons:  left.gif | right.gif | bigger.gif | smaller.gif | red.gif | green.gif | blue.gif | italic.gif | bold.gif | underline.gif | restore.gif


Jan 31, 2002 – Here are the demo programs from today’s class, along with screen snaps for the API: DemoButtons.java | DemoButtons.gif | DemoIconButton.java | DemoIconButton-1.gif | DemoDisabledButton.java | DemoDisabledButton-1.gif | DemoDisabledButton-2.gif | DemoHTMLButton.java | DemoHTMLButton-1.gif | DemoComboBox.java | DemoComboBox-1.gif

 

As well, you’ll need the following image files for the various button icons: decrementIcon.gif | incrementIcon.gif | decrementIcon-disabled.gif | incrementIcon-disabled.gif | triangle.gif | yikes.gif


Jan 29, 2002 – Here are the demo programs from today’s class, along with screen snaps for the API: DemoMenu.java | DemoMenu-1.gif | DemoMenu2.java | DemoMenu2-1.gif | DemoLookAndFeel.java | DemoLookAndFeel-1.gif | DemoLookAndFeel-2.gif |  DemoLookAndFeel-3.gif |  DemoLookAndFeel-4.gif


Jan 29, 2002Click here to download the PPT files from today’s class – “WIMP Elements”


Jan 26, 2002 – FYI, assignments will be marked using letter grades.  Click here for a description of the meaning associated with letter grades.


Jan 24, 2002 – Here is the demo program from today’s class, along with screen snaps for the API: DemoCursorControl.java | DemoCursorControl-1.gif  | DemoCursorControl-2.gif  | DemoCursorControl-3.gif  | DemoCursorControl-4.gif  


Jan 23, 2002 – Yesterday in class, someone asked “Why are Java’s adapter classes abstract, even though the methods in the adapter classes are not?”  Below is a more comprehensive answer than given in class. 

 

Java’s adapter class are provided as a convenience.  They provide dummy, do-nothing implementations of the methods in the corresponding interface.  For example, WindowAdapter – an adapter class, which is declared abstract – provides an empty implementation of each of the seven methods in the WindowListener interface.  Because WindowAdapter is abstract, it cannot be instantiated, thus there is no way to directly use the methods in WindowAdapter.  This is the reason WindowAdapter is declared abstract – to prevent programmers from instantiating the class and incorrectly using the methods defined within. This is good since the method implementations are empty.  However, WindowAdapter can be extended, and the subclass needn’t be abstract.  The only proviso is that the subclass must override any method of interest in WindowAdapter.  The subclass can be instantiated and the overridden methods can be invoked on objects of the subclass.

 

This is demonstrated in DemoSwing, as follows. WindowCloser extends WindowAdapter and overrides the windowClosing method in WindowAdapter. (Note that WindowAdapter, which is abstract, implements WindowListener.)  The method addWindowListener, which is invoked on the JFrame in the demo program, requires a WindowListener object as an argument.  In the demo, this appears as “new WindowCloser()”.

 

Note: Sun recently published a comprehensive Tech Tip with a section called Abstract Classes vs. Interfaces.  Please read this.


Jan 23, 2002 – Here are the TA office hours for Assignment #1:

 

Wed, Jan 30         17:00 - 19:00        Szymon Stachniak      CSB 3017

Mon, Feb  4          12:00 - 14:00        Andriy Pavlovych       CSB 2057

Wed, Feb  6          9:30 - 11:30          Yang Yang                  CSB 1006C

 

Note: CSB 1006C is the "South Meeting Room" inside the Prism Lab.


Jan 22, 2002 – Please verify your enrolment status.  Changes in enrolment status have just been posted outside the main office (CSB 1003A).


Jan 22, 2002 – Here are the demo programs from today’s class, along with screen snaps for the API: DemoKeyEvents2.java | DemoKeyEvents2-1.gif | DemoMouseEvents.java | DemoMouseEvents-1.gif | DemoLowLevelEvents.java | DemoLowLevelEvents-1.gif | DemoHighLevelEvents.java | DemoHighLevelEvents-1.gif | DemoActionEvents.java | DemoActionEvents-1.gif | DemoFocusEvents.java


Jan 22, 2002Click here to download the PPT files from last Thursday’s class – “Interaction Styles”.  Click here to download the PPT files from today’s class: “Sequential vs. Event-Driven Programming”


Jan 17, 2002 – Here are some demo programs from recent classes, along with screen snaps for the API: DemoHelloWord.java | DemoHelloWorld-1.gif | DemoHelloWorld2.java | DemoHelloWorld2-1.gif | DemoSwing.java | DemoSwing-1.gif | DemoTranslateEnglishConsole.java | DemoTranslateEnglishConsole-1.gif | DemoKeyEvents.java | DemoKeyEvents-1.gif | DemoTranslateEnglishGUI.java | DemoTranslateEnglishGUI-1.gif


Jan 10, 2002 – Please note: Prof. MacKenzie will be away next Tuesday (Jan 15).  His office hours for that day are cancelled.  The lecture will take place, however.  It will be given by Prof. Tzerpos.    


Jan 10, 2002 – Assignment #1 now posted.  See the main course web page for details.


Jan 8, 2002 – Normally, I wouldn’t post a job ad on the course web page, but this one, for a Usability Specialist, seems particularly relevent to the topics discussed in class today.  The ad is current, posted just today.  You’ll notice that much of the terminology presented in class is also found in the ad.


Jan 8, 2002Click here to download the PowerPoint slides from today’s class – “User Interface Design in the Workplace”.


Jan 3, 2002Click here to download the PowerPoint slides from today’s class – “Introduction”.


Jan 3, 2002 – Here are the demo programs from today’s class: DemoLargestConsole.java | DemoLargestGUI.java

 

Just a suggestion…  Put the demo programs in a directory, then issue the command javadoc *.java.  This will create API documentation for the programs in a format similar to the Java API.  Open the file index.html from a browser.  This is the preferred way to read the comments in the source files.  Some screen snaps are also included for convenience: DemoLargestConsole-1.gif | DemoLargestGUI-1.gif | DemoLargestGUI-2.gif

 


Jan 2, 2002 – Announcements, etc.

 

·        Resources – Sun’s Java 2 Platform, Standard Edition, v1.3.1, API Specification is available for download to your personal machine.  For details, go to Sun’s website at

 

http://java.sun.com/j2se/1.3/docs.html

 

·        Resources – Sun’s The Java Tutorial and The JFC Swing Tutorial are available at

 

http://java.sun.com/docs/books/tutorial/index.html

 

·        Resources – To learn about Java events, event listeners, interfaces, GUI programming, etc., try Chapters 10 and 12 in  Horstmann’s Computing Concepts with Java 2 Essentials.  This is the text used for COSC 1020.  It’s a good place to start, since you may already have the book, plus the source code for all example programs is available on line.  To get the source code for the example programs, go to

 

http://www.horstmann.com/ccj.html