APIdia Launch Partner
Top Description Constructors Methods
javax.swing.plaf.metal

public Class MetalPopupMenuSeparatorUI

extends MetalSeparatorUI
Class Inheritance
Imports
javax.swing.*, java.awt.Color, .Dimension, .Graphics, .Insets, .Rectangle, javax.swing.plaf.*

A Metal L&F implementation of PopupMenuSeparatorUI. This implementation is a "combined" view/controller.
Author
Jeff Shapiro

Constructor Summary

AccessConstructor and Description
public
MetalPopupMenuSeparatorUI()

Constructs a MetalPopupMenuSeparatorUI.

Method Summary

Modifier and TypeMethod and Description
public static ComponentUI

Returns:

a new MetalPopupMenuSeparatorUI instance
createUI
(JComponent
a component
c
)

Hides javax.swing.plaf.metal.MetalSeparatorUI.createUI.

Constructs a new MetalPopupMenuSeparatorUI instance.

public Dimension
getPreferredSize(JComponent c)

Overrides javax.swing.plaf.metal.MetalSeparatorUI.getPreferredSize.

Returns the specified component's preferred size appropriate for the look and feel.

public void
paint(Graphics g, JComponent c)

Overrides javax.swing.plaf.metal.MetalSeparatorUI.paint.

Paints the specified component appropriately for the look and feel.

Inherited from javax.swing.plaf.metal.MetalSeparatorUI:
installDefaults

Constructor Detail

MetalPopupMenuSeparatorUIback to summary
public MetalPopupMenuSeparatorUI()

Constructs a MetalPopupMenuSeparatorUI.

Method Detail

createUIback to summary
public static ComponentUI createUI(JComponent c)

Hides javax.swing.plaf.metal.MetalSeparatorUI.createUI.

Constructs a new MetalPopupMenuSeparatorUI instance.

Parameters
c:JComponent

a component

Returns:ComponentUI

a new MetalPopupMenuSeparatorUI instance

getPreferredSizeback to summary
public Dimension getPreferredSize(JComponent c)

Overrides javax.swing.plaf.metal.MetalSeparatorUI.getPreferredSize.

Doc from javax.swing.plaf.ComponentUI.getPreferredSize.

Returns the specified component's preferred size appropriate for the look and feel. If null is returned, the preferred size will be calculated by the component's layout manager instead (this is the preferred approach for any component with a specific layout manager installed). The default implementation of this method returns null.

paintback to summary
public void paint(Graphics g, JComponent c)

Overrides javax.swing.plaf.metal.MetalSeparatorUI.paint.

Doc from javax.swing.plaf.ComponentUI.paint.

Paints the specified component appropriately for the look and feel. This method is invoked from the ComponentUI.update method when the specified component is being painted. Subclasses should override this method and use the specified Graphics object to render the content of the component.