|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.lwuit.painter.PainterChain
public class PainterChain
A painter chain allows us to chain together several painters to provide a "layer" effect where each painter only draws one element.
Constructor Summary | |
---|---|
PainterChain(Painter painter)
Create a new painter chain which will paint all of the elements in the chain in sequence from 0 to the last element |
|
PainterChain(Painter[] chain)
Create a new painter chain which will paint all of the elements in the chain in sequence from 0 to the last element |
Method Summary | |
---|---|
PainterChain |
addPainter(Painter p)
Creates a new chain based on the existing chain with the new element added at the end |
Painter[] |
getChain()
Allows us to traverse the painter chain |
static void |
installGlassPane(Form f,
Painter p)
Installs a glass pane on the given form making sure to make it a painter chain only if required by existing painter |
void |
paint(Graphics g,
Rectangle rect)
Draws inside the given rectangle clipping area. |
PainterChain |
prependPainter(Painter p)
Creates a new chain based on the existing chain with the new element added at the beginning |
static void |
removeGlassPane(Form f,
Painter p)
Removes a glass pane from the given form, this is the opposite operation for the install glass pane |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PainterChain(Painter[] chain)
chain
- the chain of components in the painterpublic PainterChain(Painter painter)
painter
- the chain first PainterMethod Detail |
---|
public PainterChain addPainter(Painter p)
p
- new painter
public PainterChain prependPainter(Painter p)
p
- new painter
public void paint(Graphics g, Rectangle rect)
Painter
paint
in interface Painter
g
- the Graphics
objectrect
- the given rectangle cliping areapublic static void installGlassPane(Form f, Painter p)
f
- form on which to install the chainp
- painter to installpublic Painter[] getChain()
public static void removeGlassPane(Form f, Painter p)
f
- form from which to remove the chainp
- painter to remove
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |