|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel com.alee.laf.panel.WebPanel
public class WebPanel
This JPanel extension class provides a direct access to WebPanelUI methods. By default WebPanel uses BorderLayout instead of FlowLayout (unlike JPanel).
This component should never be used with a non-Web UIs as it might cause an unexpected behavior. You could still use that component even if WebLaF is not your application L&F as this component will use Web-UI in any case.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
javax.swing.JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
java.awt.Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary |
---|
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 |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
WebPanel()
Constructs new panel. |
|
WebPanel(boolean decorated)
Constructs new panel which is either decorated or undecorated. |
|
WebPanel(boolean decorated,
java.awt.Component component)
Constructs new panel which is either decorated or undecorated. |
|
WebPanel(boolean decorated,
java.awt.LayoutManager layout)
Constructs new panel with the specified layout which is either decorated or undecorated. |
|
WebPanel(java.awt.Component component)
Constructs new panel with the specified component automatically added into panel's center area. |
|
WebPanel(java.awt.LayoutManager layout)
Constructs new panel with the specified layout. |
|
WebPanel(java.awt.LayoutManager layout,
boolean isDoubleBuffered)
Constructs new panel with the specified layout and double-buffered mark. |
|
WebPanel(java.awt.LayoutManager layout,
java.awt.Component... components)
Constructs new panel with the specified layout. |
|
WebPanel(java.awt.LayoutManager layout,
Painter painter)
Constructs new panel with the specified layout and painter. |
|
WebPanel(java.awt.LayoutManager layout,
Painter painter,
java.awt.Component... components)
Constructs new panel with the specified layout and painter. |
|
WebPanel(Painter painter)
Constructs new panel with the specified painter. |
|
WebPanel(Painter painter,
java.awt.Component component)
Constructs new panel with the specified painter. |
|
WebPanel(java.lang.String styleId)
Constructs new panel with the specified style ID. |
|
WebPanel(java.lang.String styleId,
java.awt.Component component)
Constructs new panel with the specified style ID. |
|
WebPanel(java.lang.String styleId,
java.awt.LayoutManager layout)
Constructs new panel with the specified style ID. |
Method Summary | |
---|---|
WebPanel |
add(java.awt.Component... components)
Adds all specified components into the panel. |
WebPanel |
add(int index,
java.awt.Component... components)
Adds all components into the panel under the specified index. |
WebPanel |
add(java.util.List<? extends java.awt.Component> components)
Adds all components from the list into the panel. |
WebPanel |
add(java.util.List<? extends java.awt.Component> components,
int index)
Adds all components from the list into the panel under the specified index. |
WebPanel |
add(java.util.List<? extends java.awt.Component> components,
java.lang.String constraints)
Adds all components from the list into the panel under the specified constraints. |
WebPanel |
add(java.lang.String constraints,
java.awt.Component... components)
Adds all components into the panel under the specified constraints. |
java.awt.Color |
getBorderColor()
Returns decoration border color. |
java.awt.Stroke |
getBorderStroke()
Returns decoration border stroke. |
java.awt.Color |
getDisabledBorderColor()
Returns decoration disabled border color. |
java.awt.Component |
getFirstComponent()
Returns first component contained in this panel. |
java.lang.String |
getLanguageContainerKey()
Returns language container key for container which implements this interface. |
java.awt.Component |
getLastComponent()
Returns last component contained in this panel. |
java.awt.Insets |
getMargin()
Returns panel margin. |
int |
getMinimumHeight()
Returns component minimum height. |
int |
getMinimumWidth()
Returns component minimum width. |
Painter |
getPainter()
Returns panel painter. |
int |
getPreferredHeight()
Returns component preferred height. |
java.awt.Dimension |
getPreferredSize()
Returns component preferred size. |
int |
getPreferredWidth()
Returns component preferred width. |
int |
getRound()
Returns decoration corners rounding. |
float |
getShadeTransparency()
Returns decoration shade transparency. |
int |
getShadeWidth()
Returns decoration shade width. |
java.lang.String |
getStyleId()
Returns component style ID. |
WebPanelUI |
getWebUI()
Returns Web-UI applied to this class. |
boolean |
isPaintBackground()
Returns whether should paint decoration background or not. |
boolean |
isPaintBottom()
Returns whether should paint bottom side or not. |
boolean |
isPaintBottomLine()
Returns whether should paint bottom side line or not. |
boolean |
isPaintFocus()
Returns whether focus should be painted or not. |
boolean |
isPaintLeft()
Returns whether should paint left side or not. |
boolean |
isPaintLeftLine()
Returns whether should paint left side line or not. |
boolean |
isPaintRight()
Returns whether should paint right side or not. |
boolean |
isPaintRightLine()
Returns whether should paint right side line or not. |
boolean |
isPaintTop()
Returns whether should paint top side or not. |
boolean |
isPaintTopLine()
Returns whether should paint top side line or not. |
boolean |
isUndecorated()
Returns whether panel is undecorated or not. |
boolean |
isWebColoredBackground()
Returns whether should paint web-styled background or not. |
java.awt.Shape |
provideShape()
Returns component shape. |
void |
removeLanguageContainerKey()
Removes language container key for container which implements this interface. |
WebPanel |
setBorderColor(java.awt.Color color)
Sets decoration border color. |
WebPanel |
setBorderStroke(java.awt.Stroke stroke)
Sets decoration border stroke. |
WebPanel |
setDisabledBorderColor(java.awt.Color color)
Sets decoration disabled border color. |
void |
setLanguageContainerKey(java.lang.String key)
Sets language container key for container which implements this interface. |
void |
setMargin(java.awt.Insets margin)
Sets panel margin. |
WebPanel |
setMargin(int spacing)
Sets panel margin. |
WebPanel |
setMargin(int top,
int left,
int bottom,
int right)
Sets panel margin. |
WebPanel |
setMinimumHeight(int minimumHeight)
Sets component minimum height. |
WebPanel |
setMinimumWidth(int minimumWidth)
Sets component minimum width. |
WebPanel |
setPaintBackground(boolean paint)
Sets whether should paint decoration background or not. |
void |
setPaintBottom(boolean bottom)
Sets whether should paint bottom side or not. |
void |
setPaintBottomLine(boolean bottom)
Sets whether should paint bottom side line or not. |
WebPanel |
setPainter(Painter painter)
Sets panel painter. |
WebPanel |
setPaintFocus(boolean paint)
Sets whether focus should be painted or not. |
void |
setPaintLeft(boolean left)
Sets whether should paint left side or not. |
void |
setPaintLeftLine(boolean left)
Sets whether should paint left side line or not. |
void |
setPaintRight(boolean right)
Sets whether should paint right side or not. |
void |
setPaintRightLine(boolean right)
Sets whether should paint right side line or not. |
void |
setPaintSideLines(boolean top,
boolean left,
boolean bottom,
boolean right)
Sets whether should paint specific side lines or not. |
void |
setPaintSides(boolean top,
boolean left,
boolean bottom,
boolean right)
Sets whether should paint specific sides or not. |
void |
setPaintTop(boolean top)
Sets whether should paint top side or not. |
void |
setPaintTopLine(boolean top)
Sets whether should paint top side line or not. |
WebPanel |
setPreferredHeight(int preferredHeight)
Sets component preferred height. |
WebPanel |
setPreferredWidth(int preferredWidth)
Sets component preferred width. |
WebPanel |
setRound(int round)
Sets decoration corners rounding. |
WebPanel |
setShadeTransparency(float transparency)
Sets decoration shade transparency. |
WebPanel |
setShadeWidth(int shadeWidth)
Sets decoration shade width. |
void |
setStyleId(java.lang.String id)
Sets custom component style ID. |
WebPanel |
setUndecorated(boolean undecorated)
Sets whether panel should be undecorated or not. |
WebPanel |
setWebColoredBackground(boolean webColored)
Sets whether should paint web-styled background or not. |
void |
updateUI()
Installs a Web-UI into this component. |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI |
Methods inherited from class javax.swing.JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public WebPanel()
public WebPanel(boolean decorated)
decorated
- whether panel should be decorated or notpublic WebPanel(boolean decorated, java.awt.LayoutManager layout)
decorated
- whether panel should be decorated or notlayout
- panel layoutpublic WebPanel(boolean decorated, java.awt.Component component)
decorated
- whether panel should be decorated or notcomponent
- component to add into the panelpublic WebPanel(java.awt.Component component)
component
- component to add into the panelpublic WebPanel(Painter painter)
painter
- panel painterpublic WebPanel(java.awt.LayoutManager layout, Painter painter)
layout
- panel layoutpainter
- panel painterpublic WebPanel(Painter painter, java.awt.Component component)
painter
- panel paintercomponent
- component to add into the panelpublic WebPanel(java.awt.LayoutManager layout, Painter painter, java.awt.Component... components)
layout
- panel layoutpainter
- panel paintercomponents
- components to add into panelpublic WebPanel(java.awt.LayoutManager layout)
layout
- panel layoutpublic WebPanel(java.awt.LayoutManager layout, boolean isDoubleBuffered)
layout
- panel layoutisDoubleBuffered
- whether panel should be double-buffered or notpublic WebPanel(java.awt.LayoutManager layout, java.awt.Component... components)
layout
- panel layoutcomponents
- components to add into panelpublic WebPanel(java.lang.String styleId)
styleId
- style IDpublic WebPanel(java.lang.String styleId, java.awt.LayoutManager layout)
styleId
- style IDlayout
- panel layoutpublic WebPanel(java.lang.String styleId, java.awt.Component component)
styleId
- style IDcomponent
- component to add into panelMethod Detail |
---|
public WebPanel add(java.util.List<? extends java.awt.Component> components, int index)
components
- components to add into panelindex
- index where components should be placed
public WebPanel add(java.util.List<? extends java.awt.Component> components, java.lang.String constraints)
components
- components to add into panelconstraints
- constraints for all components
public WebPanel add(java.util.List<? extends java.awt.Component> components)
components
- components to add into panel
public WebPanel add(int index, java.awt.Component... components)
index
- index where components should be placedcomponents
- components to add into panel
public WebPanel add(java.lang.String constraints, java.awt.Component... components)
constraints
- constraints for all componentscomponents
- components to add into panel
public WebPanel add(java.awt.Component... components)
components
- components to add into panel
public java.awt.Component getFirstComponent()
public java.awt.Component getLastComponent()
public boolean isUndecorated()
public WebPanel setUndecorated(boolean undecorated)
undecorated
- whether panel should be undecorated or not
public boolean isPaintFocus()
public WebPanel setPaintFocus(boolean paint)
paint
- whether focus should be painted or not
public java.awt.Insets getMargin()
public void setMargin(java.awt.Insets margin)
margin
- new panel marginpublic WebPanel setMargin(int top, int left, int bottom, int right)
top
- top panel marginleft
- left panel marginbottom
- bottom panel marginright
- right panel margin
public WebPanel setMargin(int spacing)
spacing
- panel margin
public boolean isPaintTop()
public void setPaintTop(boolean top)
setPaintTop
in interface PartialDecoration
top
- whether should paint top side or notpublic boolean isPaintLeft()
public void setPaintLeft(boolean left)
setPaintLeft
in interface PartialDecoration
left
- whether should paint left side or notpublic boolean isPaintBottom()
public void setPaintBottom(boolean bottom)
setPaintBottom
in interface PartialDecoration
bottom
- whether should paint bottom side or notpublic boolean isPaintRight()
public void setPaintRight(boolean right)
setPaintRight
in interface PartialDecoration
right
- whether should paint right side or notpublic void setPaintSides(boolean top, boolean left, boolean bottom, boolean right)
setPaintSides
in interface PartialDecoration
top
- whether should paint top side or notleft
- whether should paint left side or notbottom
- whether should paint bottom side or notright
- whether should paint right side or notpublic boolean isPaintTopLine()
public void setPaintTopLine(boolean top)
setPaintTopLine
in interface PartialDecoration
top
- whether should paint top side line or notpublic boolean isPaintLeftLine()
public void setPaintLeftLine(boolean left)
setPaintLeftLine
in interface PartialDecoration
left
- whether should paint left side line or notpublic boolean isPaintBottomLine()
public void setPaintBottomLine(boolean bottom)
setPaintBottomLine
in interface PartialDecoration
bottom
- whether should paint bottom side line or notpublic boolean isPaintRightLine()
public void setPaintRightLine(boolean right)
setPaintRightLine
in interface PartialDecoration
right
- whether should paint right side line or notpublic void setPaintSideLines(boolean top, boolean left, boolean bottom, boolean right)
setPaintSideLines
in interface PartialDecoration
top
- whether should paint top side line or notleft
- whether should paint left side line or notbottom
- whether should paint bottom side line or notright
- whether should paint right side line or notpublic int getRound()
public WebPanel setRound(int round)
round
- decoration corners rounding
public int getShadeWidth()
public WebPanel setShadeWidth(int shadeWidth)
shadeWidth
- decoration shade width
public float getShadeTransparency()
public WebPanel setShadeTransparency(float transparency)
transparency
- new decoration shade transparency
public java.awt.Stroke getBorderStroke()
public WebPanel setBorderStroke(java.awt.Stroke stroke)
stroke
- decoration border stroke
public java.awt.Color getBorderColor()
public WebPanel setBorderColor(java.awt.Color color)
color
- decoration border color
public java.awt.Color getDisabledBorderColor()
public WebPanel setDisabledBorderColor(java.awt.Color color)
color
- decoration disabled border color
public boolean isPaintBackground()
public WebPanel setPaintBackground(boolean paint)
paint
- whether should paint decoration background or not
public boolean isWebColoredBackground()
public WebPanel setWebColoredBackground(boolean webColored)
webColored
- whether should paint web-styled background or not
public Painter getPainter()
public WebPanel setPainter(Painter painter)
painter
- new panel painter
public java.lang.String getStyleId()
getStyleId
in interface Styleable
public void setStyleId(java.lang.String id)
setStyleId
in interface Styleable
id
- custom component style IDpublic java.awt.Shape provideShape()
provideShape
in interface ShapeProvider
public WebPanelUI getWebUI()
public void updateUI()
updateUI
in class javax.swing.JPanel
public int getPreferredWidth()
getPreferredWidth
in interface SizeMethods<WebPanel>
public WebPanel setPreferredWidth(int preferredWidth)
setPreferredWidth
in interface SizeMethods<WebPanel>
preferredWidth
- new component preferred width
public int getPreferredHeight()
getPreferredHeight
in interface SizeMethods<WebPanel>
public WebPanel setPreferredHeight(int preferredHeight)
setPreferredHeight
in interface SizeMethods<WebPanel>
preferredHeight
- new component preferred height
public int getMinimumWidth()
getMinimumWidth
in interface SizeMethods<WebPanel>
public WebPanel setMinimumWidth(int minimumWidth)
setMinimumWidth
in interface SizeMethods<WebPanel>
minimumWidth
- new component minimum width
public int getMinimumHeight()
getMinimumHeight
in interface SizeMethods<WebPanel>
public WebPanel setMinimumHeight(int minimumHeight)
setMinimumHeight
in interface SizeMethods<WebPanel>
minimumHeight
- new component minimum height
public java.awt.Dimension getPreferredSize()
getPreferredSize
in interface SizeMethods<WebPanel>
getPreferredSize
in class javax.swing.JComponent
public void setLanguageContainerKey(java.lang.String key)
setLanguageContainerKey
in interface LanguageContainerMethods
key
- language container keypublic void removeLanguageContainerKey()
removeLanguageContainerKey
in interface LanguageContainerMethods
public java.lang.String getLanguageContainerKey()
getLanguageContainerKey
in interface LanguageContainerMethods
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |