-
What is the difference between
the paint() and repaint() methods?
- The paint() method supports
painting via a Graphics object. The
repaint() method is used to cause
paint() to be invoked by the AWT
painting thread.
-
How can the Checkbox class be
used to create a radio button? -
By associating Checkbox objects with
a CheckboxGroup
-
What is the difference between a
Choice and a List? - A Choice is
displayed in a compact form that
requires you to pull it down to see
the list of available choices. Only
one item may be selected from a
Choice. A List may be displayed in
such a way that several List items
are visible. A List supports the
selection of one or more List items.
-
What interface is extended by AWT
event listeners? - All AWT event
listeners extend the
java.util.EventListener interface.
-
What is a layout manager? - A
layout manager is an object that is
used to organize components in a
container
-
Which Component subclass is used
for drawing and painting? -
Canvas
-
What are the problems faced by
Java programmers who dont use layout
managers? - Without layout
managers, Java programmers are faced
with determining how their GUI will
be displayed across multiple
windowing systems and finding a
common sizing and positioning that
will work within the constraints
imposed by each windowing system
-
What is the difference between a
Scrollbar and a ScrollPane? (Swing)
- A Scrollbar is a Component, but
not a Container. A ScrollPane is a
Container. A ScrollPane handles its
own events and performs its own
scrolling.