java.lang.Object | ||||
↳ | java.util.EventObject | |||
↳ | java.awt.AWTEvent | |||
↳ | java.awt.event.ComponentEvent | |||
↳ | java.awt.event.PaintEvent |
Known Direct Subclasses |
The component-level paint event. This event is a special type which is used to ensure that paint/update method calls are serialized along with the other events delivered from the event queue. This event is not designed to be used with the Event Listener model; programs should continue to override paint/update methods in order render themselves properly.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | PAINT | The paint event type. | |||||||||
int | PAINT_FIRST | Marks the first integer id for the range of paint event ids. | |||||||||
int | PAINT_LAST | Marks the last integer id for the range of paint event ids. | |||||||||
int | UPDATE | The update event type. |
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.awt.event.ComponentEvent
| |||||||||||
From class
java.awt.AWTEvent
|
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.awt.AWTEvent
| |||||||||||
From class
java.util.EventObject
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Constructs a
PaintEvent object with the specified
source component and type. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the rectangle representing the area which needs to be
repainted in response to this event.
| |||||||||||
Returns a parameter string identifying this event.
| |||||||||||
Sets the rectangle representing the area which needs to be
repainted in response to this event.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.awt.event.ComponentEvent
| |||||||||||
From class
java.awt.AWTEvent
| |||||||||||
From class
java.util.EventObject
| |||||||||||
From class
java.lang.Object
|
The paint event type.
Marks the first integer id for the range of paint event ids.
Marks the last integer id for the range of paint event ids.
The update event type.
Constructs a PaintEvent
object with the specified
source component and type.
Note that passing in an invalid id
results in
unspecified behavior. This method throws an
IllegalArgumentException
if source
is null
.
source | the object where the event originated |
---|---|
id | the event type |
updateRect | the rectangle area which needs to be repainted |
IllegalArgumentException | if source is null
|
---|
Returns the rectangle representing the area which needs to be repainted in response to this event.
Returns a parameter string identifying this event. This method is useful for event-logging and for debugging.
Sets the rectangle representing the area which needs to be repainted in response to this event.
updateRect | the rectangle area which needs to be repainted |
---|