EasyApp

Easily construct GUI applications, with components (Buttons, TextFields, etc), and using IBIO.

The EasyApp class contains two sets of useful methods:

  1. IBIO simple input and output methods
  2. addComponent methods for creating components

addComponent

There is an add.. method for each normal AWT component:

   Button, TextField, TextArea, Label, List, Choice, Checkbox

EasyApp uses a null Layout manager, so each component is placed and sized directly in the add.. method.  Some methods require a String as the first component - this will be displayed by the component.  They all end with the four parameters left, top, width, height.

The add.. methods also execute and addListener(this) command, so the control actions are automatically connected to the actionPerformed and itemStateChanged methods.  The application must override these event handlers.

Comments

The use of a null layout manager reduces cross-platform flexibility, as standard font sizes are not the same in variaous OS's.  However, the direct control of the placement of components is probably a simpler concept for beginning programmers.

All the components are standard AWT components.  All standard methods function as normal, including adding further listeners.

Using EasyApp is not significantly different than using a GUI IDE like NetBeans, but in EasyApp the students must do a bit more work, and will hopefully learn a bit more.