|
org.openide.loaders 5.9.31 | |||||||||
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.JToolBar org.openide.awt.Toolbar
public class Toolbar
Toolbar provides a component which is useful for displaying commonly used
actions. It can be dragged inside its ToolbarPanel
to
customize its location.
Nested Class Summary | |
---|---|
static class |
Toolbar.DnDEvent
DnDEvent is Toolbar's drag and drop event. |
static interface |
Toolbar.DnDListener
DnDListener is Drag and Drop listener for Toolbar motion events. |
Nested classes/interfaces inherited from class javax.swing.JToolBar |
---|
JToolBar.AccessibleJToolBar, JToolBar.Separator |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
static int |
BASIC_HEIGHT
Deprecated. Use getBasicHeight instead. |
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 javax.swing.SwingConstants |
---|
CENTER, EAST, HORIZONTAL, LEADING, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, SOUTH, SOUTH_EAST, SOUTH_WEST, TRAILING, VERTICAL, WEST |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
Toolbar()
Create a new Toolbar with empty name. |
|
Toolbar(String name)
Create a new not floatable Toolbar with programmatic name. |
|
Toolbar(String name,
boolean f)
Create a new Toolbar . |
|
Toolbar(String name,
String displayName)
Create a new not floatable Toolbar with specified programmatic name and display name |
|
Toolbar(String name,
String displayName,
boolean f)
Create a new Toolbar . |
Method Summary | |
---|---|
protected void |
addImpl(Component c,
Object constraints,
int idx)
Overridden to set focusable to false for any AbstractButton subclasses which are added |
void |
addNotify()
|
protected void |
fireDragToolbar(int dx,
int dy,
int type)
Fire drag of Toolbar |
protected void |
fireDropToolbar(int dx,
int dy,
int type)
Fire drop of Toolbar |
static int |
getBasicHeight()
Returns basic toolbar height according to preferred icons size. |
Component[] |
getComponents()
|
String |
getDisplayName()
|
Dimension |
getPreferredSize()
|
String |
getUIClassID()
|
void |
paint(Graphics g)
|
void |
removeAll()
Removes all ACTION components. |
static int |
rowCount(int height)
Compute with HEIGHT_TOLERANCE number of rows for specific toolbar height. |
void |
setDisplayName(String displayName)
Sets new display name of this toolbar. |
void |
setDnDListener(Toolbar.DnDListener l)
Set DnDListener to Toolbar. |
void |
setUI(ToolBarUI ui)
|
void |
setVisible(boolean b)
|
Methods inherited from class javax.swing.JToolBar |
---|
add, addSeparator, addSeparator, createActionChangeListener, createActionComponent, getAccessibleContext, getComponentAtIndex, getComponentIndex, getMargin, getOrientation, getUI, isBorderPainted, isFloatable, isRollover, paintBorder, paramString, setBorderPainted, setFloatable, setLayout, setMargin, setOrientation, setRollover, updateUI |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int BASIC_HEIGHT
Constructor Detail |
---|
public Toolbar()
public Toolbar(String name)
public Toolbar(String name, String displayName)
public Toolbar(String name, boolean f)
Toolbar
.
name
- a String
containing the associated namef
- specified if Toolbar is floatable
Display name of the toolbar is set equal to the name.public Toolbar(String name, String displayName, boolean f)
Toolbar
.
name
- a String
containing the associated namef
- specified if Toolbar is floatableMethod Detail |
---|
public void paint(Graphics g)
paint
in class JComponent
public void addNotify()
addNotify
in class JComponent
public Component[] getComponents()
getComponents
in class Container
public void setVisible(boolean b)
setVisible
in class JComponent
protected void addImpl(Component c, Object constraints, int idx)
public static int getBasicHeight()
public String getUIClassID()
getUIClassID
in class JToolBar
public Dimension getPreferredSize()
getPreferredSize
in class JComponent
public void removeAll()
public static int rowCount(int height)
height
- of some toolbar
public void setDnDListener(Toolbar.DnDListener l)
l
- DndListener for toolbarpublic String getDisplayName()
public void setDisplayName(String displayName)
protected void fireDragToolbar(int dx, int dy, int type)
dx
- distance of horizontal draggingdy
- distance of vertical draggingtype
- type of toolbar draggingprotected void fireDropToolbar(int dx, int dy, int type)
dx
- distance of horizontal droppingdy
- distance of vertical droppingtype
- type of toolbar droppingpublic void setUI(ToolBarUI ui)
|
org.openide.loaders 5.9.31 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |