APIdia Launch Partner
Top Description Inners Fields Constructors Methods
javax.swing.plaf.basic

public Class BasicInternalFrameTitlePane

extends JComponent
Class Inheritance
Known Direct Subclasses
javax.swing.plaf.metal.MetalInternalFrameTitlePane, javax.swing.plaf.synth.SynthInternalFrameTitlePane, com.sun.java.swing.plaf.motif.MotifInternalFrameTitlePane
Annotations
@SuppressWarnings:serial
Imports
sun.swing.SwingUtilities2, .DefaultLookup, java.awt.*, java.awt.event.*, javax.accessibility.AccessibleContext, javax.swing.*, javax.swing.plaf.*, javax.swing.event.InternalFrameEvent, java.beans.PropertyChangeListener, .PropertyChangeEvent, .PropertyVetoException

The class that manages a basic title bar

Warning

Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeans has been added to the java.beans package. Please see java.beans.XMLEncoder.

Authors
David Kloba, Steve Wilson

Nested and Inner Type Summary

Modifier and TypeClass and Description
public class
BasicInternalFrameTitlePane.CloseAction

This class should be treated as a "protected" inner class.

private class
public class
BasicInternalFrameTitlePane.IconifyAction

This class should be treated as a "protected" inner class.

public class
BasicInternalFrameTitlePane.MaximizeAction

This class should be treated as a "protected" inner class.

public class
BasicInternalFrameTitlePane.MoveAction

This class should be treated as a "protected" inner class.

private static class
public class
BasicInternalFrameTitlePane.PropertyChangeHandler

This class should be treated as a "protected" inner class.

public class
BasicInternalFrameTitlePane.RestoreAction

This class should be treated as a "protected" inner class.

private class
public class
BasicInternalFrameTitlePane.SizeAction

This class should be treated as a "protected" inner class.

public class
BasicInternalFrameTitlePane.SystemMenuBar

This class should be treated as a "protected" inner class.

public class
BasicInternalFrameTitlePane.TitlePaneLayout

This class should be treated as a "protected" inner class.

Field Summary

Modifier and TypeField and Description
protected static final String
CLOSE_CMD

The close button text property.

protected Action
closeAction

The instance of a CloseAction.

protected JButton
closeButton

The close button.

private String
protected Icon
closeIcon

The close icon.

protected JInternalFrame
frame

The instance of JInternalFrame.

private BasicInternalFrameTitlePane.Handler
protected JButton
iconButton

The iconify button.

private String
protected Icon
iconIcon

The iconify icon.

protected static final String
ICONIFY_CMD

The minimize button text property.

protected Action
iconifyAction

The instance of an IconifyAction.

protected JButton
maxButton

The maximize button.

private String
protected Icon
maxIcon

The maximize icon.

protected static final String
MAXIMIZE_CMD

The maximize button text property.

protected Action
maximizeAction

The instance of a MaximizeAction.

protected Icon
minIcon

The minimize icon.

protected static final String
MOVE_CMD

The move button text property.

protected Action
moveAction

The instance of a MoveAction.

protected Color
notSelectedTextColor

The color of a not selected text.

protected Color
notSelectedTitleColor

The color of a not selected title.

protected PropertyChangeListener
propertyChangeListener

The instance of a PropertyChangeListener.

protected static final String
RESTORE_CMD

The restore button text property.

protected Action
restoreAction

The instance of a RestoreAction.

private String
protected Color
selectedTextColor

The color of a selected text.

protected Color
selectedTitleColor

The color of a selected title.

protected static final String
SIZE_CMD

The size button text property.

protected Action
sizeAction

The instance of a SizeAction.

protected JMenu
windowMenu

The instance of JMenu.

Inherited from javax.swing.JComponent:
listenerListTOOL_TIP_TEXT_KEYuiUNDEFINED_CONDITIONWHEN_ANCESTOR_OF_FOCUSED_COMPONENTWHEN_FOCUSEDWHEN_IN_FOCUSED_WINDOW

Constructor Summary

AccessConstructor and Description
public
BasicInternalFrameTitlePane(JInternalFrame
an instance of JInternalFrame
f
)

Constructs a new instance of BasicInternalFrameTitlePane.

Method Summary

Modifier and TypeMethod and Description
protected void
addSubComponents()

Adds subcomponents.

protected void
addSystemMenuItems(JMenu
an instance of JMenu
systemMenu
)

Adds system menu items to systemMenu.

protected void
assembleSystemMenu()

Assembles system menu.

pack-priv ActionMap
protected void
createActions()

Creates actions.

protected void
createButtons()

Creates buttons.

protected LayoutManager

Returns:

a layout manager
createLayout
()

Returns a layout manager.

protected PropertyChangeListener

Returns:

an instance of PropertyChangeListener
createPropertyChangeListener
()

Returns an instance of PropertyChangeListener.

protected JMenu

Returns:

a new instance of JMenu
createSystemMenu
()

Returns a new instance of JMenu.

protected JMenuBar

Returns:

a new instance of JMenuBar
createSystemMenuBar
()

Returns a new instance of JMenuBar.

protected void
enableActions()

Enables actions.

private static int
private BasicInternalFrameTitlePane.Handler
protected String

Returns:

the title.
getTitle
(String
a text
text
,
FontMetrics
an instance of FontMetrics
fm
,
int
an available text width
availTextWidth
)

Returns the title.

protected void
installDefaults()

Installs default properties.

protected void
installListeners()

Registers listeners.

protected void
installTitlePane()

Installs the title pane.

public void
paintComponent(Graphics g)

Overrides javax.swing.JComponent.paintComponent.

Calls the UI delegate's paint method, if the UI delegate is non-null.

protected void
paintTitleBackground(Graphics
the graphics to use to render the background
g
)

Invoked from paintComponent.

protected void
postClosingEvent(JInternalFrame
an instance of JInternalFrame
frame
)

Post a WINDOW_CLOSING-like event to the frame, so that it can be treated like a regular Frame.

protected void
setButtonIcons()

Sets the button icons.

protected void
showSystemMenu()

Shows system menu.

protected void
uninstallDefaults()

Uninstalls default properties.

protected void
uninstallListeners()

Unregisters listeners.

private void
Inherited from javax.swing.JComponent:
addAncestorListeneraddNotifyaddVetoableChangeListenercomputeVisibleRectcontainscreateToolTipdisableenablefirePropertyChangefirePropertyChangefirePropertyChangefireVetoableChangegetActionForKeyStrokegetActionMapgetAlignmentXgetAlignmentYgetAncestorListenersgetAutoscrollsgetBaselinegetBaselineResizeBehaviorgetBordergetBoundsgetClientPropertygetComponentGraphicsgetComponentPopupMenugetConditionForKeyStrokegetDebugGraphicsOptionsgetDefaultLocalegetFontMetricsgetGraphicsgetHeightgetInheritsPopupMenugetInputMapgetInputMapgetInputVerifiergetInsetsgetInsetsgetListenersgetLocationgetMaximumSizegetMinimumSizegetNextFocusableComponentgetPopupLocationgetPreferredSizegetRegisteredKeyStrokesgetRootPanegetSizegetToolTipLocationgetToolTipTextgetToolTipTextgetTopLevelAncestorgetTransferHandlergetUIgetUIClassIDgetVerifyInputWhenFocusTargetgetVetoableChangeListenersgetVisibleRectgetWidthgetXgetYgrabFocushideisDoubleBufferedisLightweightComponentisManagingFocusisOpaqueisOptimizedDrawingEnabledisPaintingForPrintisPaintingOriginisPaintingTileisRequestFocusEnabledisValidateRootpaintpaintBorderpaintChildrenpaintImmediatelypaintImmediatelyparamStringprintprintAllprintBorderprintChildrenprintComponentprocessComponentKeyEventprocessKeyBindingprocessKeyEventprocessMouseEventprocessMouseMotionEventputClientPropertyregisterKeyboardActionregisterKeyboardActionremoveAncestorListenerremoveNotifyremoveVetoableChangeListenerrepaintrepaintrequestDefaultFocusrequestFocusrequestFocusrequestFocusInWindowrequestFocusInWindowresetKeyboardActionsreshaperevalidatescrollRectToVisiblesetActionMapsetAlignmentXsetAlignmentYsetAutoscrollssetBackgroundsetBordersetComponentPopupMenusetDebugGraphicsOptionssetDefaultLocalesetDoubleBufferedsetEnabledsetFocusTraversalKeyssetFontsetForegroundsetInheritsPopupMenusetInputMapsetInputVerifiersetMaximumSizesetMinimumSizesetNextFocusableComponentsetOpaquesetPreferredSizesetRequestFocusEnabledsetToolTipTextsetTransferHandlersetUIsetVerifyInputWhenFocusTargetsetVisibleunregisterKeyboardActionupdateupdateUI