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

public Class BasicPasswordFieldUI

extends BasicTextFieldUI
Class Inheritance
Known Direct Subclasses
com.sun.java.swing.plaf.motif.MotifPasswordFieldUI
Imports
java.awt.*, javax.swing.*, javax.swing.text.*, javax.swing.event.*, javax.swing.plaf.*

Provides the Windows look and feel for a password field. The only difference from the standard text field is that the view of the text is simply a string of the echo character as specified in JPasswordField, rather than the real text contained in the field.
Author
Timothy Prinzing

Constructor Summary

AccessConstructor and Description
public
BasicPasswordFieldUI()

Constructs a BasicPasswordFieldUI.

Method Summary

Modifier and TypeMethod and Description
public View

Returns:

the view
create
(Element
the element
elem
)

Overrides javax.swing.plaf.basic.BasicTextFieldUI.create.

Implements javax.swing.text.ViewFactory.create.

Creates a view (PasswordView) for an element.

public static ComponentUI

Returns:

the UI
createUI
(JComponent
the JPasswordField
c
)

Hides javax.swing.plaf.basic.BasicTextFieldUI.createUI.

Creates a UI for a JPasswordField.

protected String

Returns:

the name ("PasswordField")
getPropertyPrefix
()

Overrides javax.swing.plaf.basic.BasicTextFieldUI.getPropertyPrefix.

Fetches the name used as a key to look up properties through the UIManager.

protected void
installDefaults()

Overrides javax.swing.plaf.basic.BasicTextUI.installDefaults.

Installs the necessary properties on the JPasswordField.

Inherited from javax.swing.plaf.basic.BasicTextFieldUI:
getBaselinegetBaselineResizeBehavior

Constructor Detail

BasicPasswordFieldUIback to summary
public BasicPasswordFieldUI()

Constructs a BasicPasswordFieldUI.

Method Detail

createback to summary
public View create(Element elem)

Overrides javax.swing.plaf.basic.BasicTextFieldUI.create.

Implements javax.swing.text.ViewFactory.create.

Creates a view (PasswordView) for an element.

Parameters
elem:Element

the element

Returns:View

the view

createUIback to summary
public static ComponentUI createUI(JComponent c)

Hides javax.swing.plaf.basic.BasicTextFieldUI.createUI.

Creates a UI for a JPasswordField.

Parameters
c:JComponent

the JPasswordField

Returns:ComponentUI

the UI

getPropertyPrefixback to summary
protected String getPropertyPrefix()

Overrides javax.swing.plaf.basic.BasicTextFieldUI.getPropertyPrefix.

Fetches the name used as a key to look up properties through the UIManager. This is used as a prefix to all the standard text properties.

Returns:String

the name ("PasswordField")

installDefaultsback to summary
protected void installDefaults()

Overrides javax.swing.plaf.basic.BasicTextUI.installDefaults.

Installs the necessary properties on the JPasswordField.

Since
1.6