Errata

Java AWT Reference

Errata for Java AWT Reference

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.

Color Key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted by Date submitted
Printed Page 25
getClipRect() is NOT abstract

Anonymous   
Printed Page 48
is Empty : a rectangle is empty if *either* its width or height

is less than or equal to 0

Anonymous   
Printed Page 219
In window and frame, a few methods have been specified as

synchronized while they were not (or the reverse) window::addNotify,
synchronized Frame::set[Tiltle | IconImage ]

It would be worth telling that window::pack() starts with calling
addNotify to make sure all the components of the container have a peer
(that their size can be known : they are valid).

Anonymous   
Printed Page 229
I believe there is an error in an example on page 229 of this

book. In the example at the bottom of the page, which addresses
handling WINDOW_CLOSING events under the 1.1 delegation model, the
last line of the example shows the invocation:

super.processEvent(e)

I believe it should be:

super.processWindowEvent(e)

Anonymous   
Printed Page 257, 259, 560
Errata on class BorderLayout: the method public

Dimension maximumLayoutsize(Container target) is said to be abstract.
Javadoc 1.1 does not:

"
maximumLayoutSize

public Dimension maximumLayoutSize(Container target)
Returns the maximum dimensions for this layout given the
components in the specified target container.
Parameters:
target - the component which needs to be laid out
See Also:
Container, minimumLayoutSize, preferredLayoutSize
"

In my opinion, it should do the same as preferred or minimumLayoutSize
but with calling getMaximumSize on its components.

Anonymous   
Printed Page 281
It says "The north region contains a panel with a single Label

in it" and then explains why a panel was used instead of adding the
label directly to the Applet. But, the source code at the top of
p.281 does add the Label directly to the applet.

Anonymous   
Printed Page 369
CheckboxMenuItem Methods lists two identical constructors for

CheckboxMenuItem(String label) and explains in the text for one that it
creates a unlabled checkbox, and explains in the text for the other that it
does create a labled checkbox. Its my guess that the first constructor is
a typo and should actually read 'public CheckboxMenuItem()' rather than
'public CheckboxMenuItem(String label)'

Anonymous   
Printed Page 378
The line that starts with (is.getSelectedObjecteds ... has one

too many )s. It should be "0));".

(I think this is true, but since I don't know Java, I'm waiting for
confirmation before I move it up. -efm)

Anonymous