|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--javax.swing.JComponent | +--javax.swing.JPanel | +--kiwi.ui.TexturedPanel
An extension of JPanel
that provides support for background
texture tiling. Lightweight components nested within the
TexturedPanel
should be transparent and unbuffered; the tiled
background will not show through heavyweight components.
Note that images with transparent portions should not be used with
TexturedPanel
s.
A TexturedPanel
will always be transparent if a background
image has not been specified.
In most cases it is more convenient to use TexturedFrame
to
provide textured backgrounds for entire windows.
TexturedFrame
, Serialized FormInner classes inherited from class javax.swing.JPanel |
JPanel.AccessibleJPanel |
Inner classes inherited from class javax.swing.JComponent |
JComponent.AccessibleJComponent |
Fields inherited from class javax.swing.JComponent |
accessibleContext,
listenerList,
TOOL_TIP_TEXT_KEY,
ui,
UNDEFINED_CONDITION,
WHEN_ANCESTOR_OF_FOCUSED_COMPONENT,
WHEN_FOCUSED,
WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
Constructor Summary | |
TexturedPanel()
Construct a new TexturedPanel . |
|
TexturedPanel(Image image)
Construct a new TexturedPanel . |
|
TexturedPanel(LayoutManager lm)
Construct a new TexturedPanel . |
|
TexturedPanel(LayoutManager lm,
Image image)
Construct a new TexturedPanel . |
Method Summary | |
void |
paintComponent(Graphics gc)
Paint the component. |
void |
setOpaque(boolean flag)
Overridden to prevent clients from making the panel transparent. |
void |
setTexture(Image image)
Set the background texture. |
Methods inherited from class javax.swing.JPanel |
getAccessibleContext,
getUIClassID,
paramString,
updateUI |
Methods inherited from class java.awt.Container |
add,
add,
add,
add,
add,
addContainerListener,
addImpl,
countComponents,
deliverEvent,
doLayout,
findComponentAt,
findComponentAt,
getComponent,
getComponentAt,
getComponentAt,
getComponentCount,
getComponents,
getLayout,
insets,
invalidate,
isAncestorOf,
layout,
list,
list,
locate,
minimumSize,
paintComponents,
preferredSize,
print,
printComponents,
processContainerEvent,
processEvent,
remove,
remove,
removeAll,
removeContainerListener,
setLayout,
validate,
validateTree |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Constructor Detail |
public TexturedPanel()
TexturedPanel
. The newly created
TexturedPanel
will be transparent.public TexturedPanel(LayoutManager lm)
TexturedPanel
. Creates a new
TexturedPanel
with the specified layout manager. The newly
created TexturedPanel
will be transparent.lm
- The layout manager to use for the panel.public TexturedPanel(LayoutManager lm, Image image)
TexturedPanel
. Creates a new
TexturedPanel
with the specified layout manager and
background image.lm
- The layout manager to use for the panel.image
- The image with which the background of the panel will be
tiled.public TexturedPanel(Image image)
TexturedPanel
. Creates a new
TexturedPanel
with a BorderLayout
and the
specified background image.image
- The image with which the background of the panel will be
tiled.Method Detail |
public void setOpaque(boolean flag)
public void paintComponent(Graphics gc)
public void setTexture(Image image)
image
- The image to use as the background texture for the panel.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |