Use is subject to License Terms. Your use of this web site or any of its content or software indicates your agreement to be bound by these License Terms.

Copyright © 2006 Sun Microsystems, Inc. All rights reserved.

JSR 216 (Maintenance Release)

Uses of Class
java.awt.Component

Packages that use Component
java.applet Provides the classes necessary to create an applet and the classes an applet uses to communicate with its applet context. 
java.awt Contains all of the classes for creating user interfaces and for painting graphics and images. 
java.awt.event Provides interfaces and classes for dealing with different types of events fired by AWT components. 
java.awt.im Provides classes and interfaces for the input method framework. 
 

Uses of Component in java.applet
 

Subclasses of Component in java.applet
 class Applet
          An applet is a small program that is intended not to be run on its own, but rather to be embedded inside another application.
 

Uses of Component in java.awt
 

Subclasses of Component in java.awt
 class Button
          This class creates a labeled button.
 class Canvas
          A Canvas component represents a blank rectangular area of the screen onto which the application can draw or from which the application can trap input events from the user.
 class Checkbox
          A check box is a graphical component that can be in either an "on" (true) or "off" (false) state.
 class Choice
          The Choice class presents a pop-up menu of choices.
 class Container
          A generic Abstract Window Toolkit(AWT) container object is a component that can contain other AWT components.
 class Dialog
          A Dialog is a top-level window with a title and a border that is typically used to take some form of input from the user.
 class FileDialog
          The FileDialog class displays a dialog window from which the user can select a file.
 class Frame
          A Frame is a top-level window with a title and a border.
 class Label
          A Label object is a component for placing text in a container.
 class List
          The List component presents the user with a scrolling list of text items.
 class Panel
          Panel is the simplest container class.
 class Scrollbar
          The Scrollbar class embodies a scroll bar, a familiar user-interface object.
 class ScrollPane
          A container class which implements automatic horizontal and/or vertical scrolling for a single child component.
 class TextArea
          A TextArea object is a multi-line region that displays text.
 class TextComponent
          The TextComponent class is the superclass of any component that allows the editing of some text.
 class TextField
          A TextField object is a text component that allows for the editing of a single line of text.
 class Window
          A Window object is a top-level window with no borders and no menubar.
 

Methods in java.awt that return Component
 Component Window.getFocusOwner()
          Returns the child Component of this Window that has focus if this Window is focused; returns null otherwise.
 Component Window.getMostRecentFocusOwner()
          Returns the child Component of this Window that will receive the focus when this Window is focused.
 Component KeyboardFocusManager.getFocusOwner()
          Returns the focus owner, if the focus owner is in the same context as the calling thread.
 Component KeyboardFocusManager.getPermanentFocusOwner()
          Returns the permanent focus owner, if the permanent focus owner is in the same context as the calling thread.
abstract  Component FocusTraversalPolicy.getComponentAfter(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus after aComponent.
abstract  Component FocusTraversalPolicy.getComponentBefore(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus before aComponent.
abstract  Component FocusTraversalPolicy.getFirstComponent(Container focusCycleRoot)
          Returns the first Component in the traversal cycle.
abstract  Component FocusTraversalPolicy.getLastComponent(Container focusCycleRoot)
          Returns the last Component in the traversal cycle.
abstract  Component FocusTraversalPolicy.getDefaultComponent(Container focusCycleRoot)
          Returns the default Component to focus.
 Component FocusTraversalPolicy.getInitialComponent(Window window)
          Returns the Component that should receive the focus when a Window is made visible for the first time.
 Component Component.getComponentAt(int x, int y)
          Determines if this component or one of its immediate subcomponents contains the (xy) location, and if so, returns the containing component.
 Component Component.locate(int x, int y)
          Deprecated. As of JDK version 1.1, replaced by getComponentAt(int, int).
 Component Component.getComponentAt(Point p)
          Returns the component or subcomponent that contains the specified point.
 Component Container.getComponent(int n)
          Gets the nth component in this container.
 Component[] Container.getComponents()
          Gets all the components in this container.
 Component Container.add(Component comp)
          Appends the specified component to the end of this container.
 Component Container.add(String name, Component comp)
          Adds the specified component to this container.
 Component Container.add(Component comp, int index)
          Adds the specified component to this container at the given position.
 Component Container.getComponentAt(int x, int y)
          Locates the component that contains the x,y position.
 Component Container.locate(int x, int y)
          Deprecated. As of JDK version 1.1, replaced by getComponentAt(int, int).
 Component Container.getComponentAt(Point p)
          Gets the component that contains the specified point.
 Component Container.findComponentAt(int x, int y)
          Locates the visible child component that contains the specified position.
 Component Container.findComponentAt(Point p)
          Locates the visible child component that contains the specified point.
 Component ContainerOrderFocusTraversalPolicy.getComponentAfter(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus after aComponent.
 Component ContainerOrderFocusTraversalPolicy.getComponentBefore(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus before aComponent.
 Component ContainerOrderFocusTraversalPolicy.getFirstComponent(Container focusCycleRoot)
          Returns the first Component in the traversal cycle.
 Component ContainerOrderFocusTraversalPolicy.getLastComponent(Container focusCycleRoot)
          Returns the last Component in the traversal cycle.
 Component ContainerOrderFocusTraversalPolicy.getDefaultComponent(Container focusCycleRoot)
          Returns the default Component to focus.
 

Methods in java.awt with parameters of type Component
protected  void ScrollPane.addImpl(Component comp, Object constraints, int index)
          Adds the specified component to this scroll pane container.
 void PopupMenu.show(Component origin, int x, int y)
          Shows the popup menu at the x, y position relative to an origin component.
 void LayoutManager2.addLayoutComponent(Component comp, Object constraints)
          Adds the specified component to the layout, using the specified constraint object.
 void LayoutManager.addLayoutComponent(String name, Component comp)
          If the layout manager uses a per-component string, adds the component comp to the layout, associating it with the string specified by name.
 void LayoutManager.removeLayoutComponent(Component comp)
          Removes the specified component from the layout.
 void KeyboardFocusManager.redispatchEvent(Component target, AWTEvent e)
          Redispatches an AWTEvent in such a way that the AWT event dispatcher will not recursively request that the KeyboardFocusManager, or any installed KeyEventDispatchers, dispatch the event again.
abstract  void KeyboardFocusManager.processKeyEvent(Component focusedComponent, KeyEvent e)
          This method initiates a focus traversal operation if and only if the KeyEvent represents a focus traversal key for the specified focusedComponent.
abstract  void KeyboardFocusManager.focusNextComponent(Component aComponent)
          Focuses the Component after aComponent, typically based on a FocusTraversalPolicy.
abstract  void KeyboardFocusManager.focusPreviousComponent(Component aComponent)
          Focuses the Component before aComponent, typically based on a FocusTraversalPolicy.
abstract  void KeyboardFocusManager.upFocusCycle(Component aComponent)
          Moves the focus up one focus traversal cycle.
 void GridLayout.addLayoutComponent(String name, Component comp)
          Adds the specified component with the specified name to the layout.
 void GridLayout.removeLayoutComponent(Component comp)
          Removes the specified component from the layout.
 void GridBagLayout.setConstraints(Component comp, GridBagConstraints constraints)
          Sets the constraints for the specified component in this layout.
 GridBagConstraints GridBagLayout.getConstraints(Component comp)
          Gets the constraints for the specified component.
protected  GridBagConstraints GridBagLayout.lookupConstraints(Component comp)
          Retrieves the constraints for the specified component.
 void GridBagLayout.addLayoutComponent(String name, Component comp)
          Adds the specified component with the specified name to the layout.
 void GridBagLayout.addLayoutComponent(Component comp, Object constraints)
          Adds the specified component to the layout, using the specified constraints object.
 void GridBagLayout.removeLayoutComponent(Component comp)
          Removes the specified component from this layout.
abstract  Component FocusTraversalPolicy.getComponentAfter(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus after aComponent.
abstract  Component FocusTraversalPolicy.getComponentBefore(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus before aComponent.
 void FlowLayout.addLayoutComponent(String name, Component comp)
          Adds the specified component to the layout.
 void FlowLayout.removeLayoutComponent(Component comp)
          Removes the specified component from the layout.
protected  boolean DefaultFocusTraversalPolicy.accept(Component aComponent)
          Determines whether a Component is an acceptable choice as the new focus owner.
 Component Container.add(Component comp)
          Appends the specified component to the end of this container.
 Component Container.add(String name, Component comp)
          Adds the specified component to this container.
 Component Container.add(Component comp, int index)
          Adds the specified component to this container at the given position.
 void Container.add(Component comp, Object constraints)
          Adds the specified component to the end of this container.
 void Container.add(Component comp, Object constraints, int index)
          Adds the specified component to this container with the specified constraints at the specified index.
protected  void Container.addImpl(Component comp, Object constraints, int index)
          Adds the specified component to this container at the specified index.
 void Container.remove(Component comp)
          Removes the specified component from this container.
 boolean Container.isAncestorOf(Component c)
          Checks if the component is contained in the component hierarchy of this container.
 Component ContainerOrderFocusTraversalPolicy.getComponentAfter(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus after aComponent.
 Component ContainerOrderFocusTraversalPolicy.getComponentBefore(Container focusCycleRoot, Component aComponent)
          Returns the Component that should receive the focus before aComponent.
protected  boolean ContainerOrderFocusTraversalPolicy.accept(Component aComponent)
          Determines whether a Component is an acceptable choice as the new focus owner.
 void CardLayout.addLayoutComponent(Component comp, Object constraints)
          Adds the specified component to this card layout's internal table of names.
 void CardLayout.addLayoutComponent(String name, Component comp)
          Deprecated. replaced by addLayoutComponent(Component, Object).
 void CardLayout.removeLayoutComponent(Component comp)
          Removes the specified component from the layout.
 void BorderLayout.addLayoutComponent(Component comp, Object constraints)
          Adds the specified component to the layout, using the specified constraint object.
 void BorderLayout.addLayoutComponent(String name, Component comp)
          Deprecated. replaced by addLayoutComponent(Component, Object).
 void BorderLayout.removeLayoutComponent(Component comp)
          Removes the specified component from this border layout.
 

Constructors in java.awt with parameters of type Component
MediaTracker(Component comp)
          Creates a media tracker to track images for a given component.
 

Uses of Component in java.awt.event
 

Methods in java.awt.event that return Component
 Component FocusEvent.getOppositeComponent()
          Returns the other Component involved in this focus change.
 Component ContainerEvent.getChild()
          Returns the component that was affected by the event.
 Component ComponentEvent.getComponent()
          Returns the originator of the event.
 

Constructors in java.awt.event with parameters of type Component
PaintEvent(Component source, int id, Rectangle updateRect)
          Constructs a PaintEvent object with the specified source component and type.
MouseEvent(Component source, int id, long when, int modifiers, int x, int y, int clickCount, boolean popupTrigger, int button)
          Constructs a MouseEvent object with the specified source component, type, modifiers, coordinates, and click count.
MouseEvent(Component source, int id, long when, int modifiers, int x, int y, int clickCount, boolean popupTrigger)
          Constructs a MouseEvent object with the specified source component, type, modifiers, coordinates, and click count.
KeyEvent(Component source, int id, long when, int modifiers, int keyCode, char keyChar)
          Constructs a KeyEvent object.
KeyEvent(Component source, int id, long when, int modifiers, int keyCode)
          Deprecated. as of JDK1.1
MouseWheelEvent(Component source, int id, long when, int modifiers, int x, int y, int clickCount, boolean popupTrigger, int scrollType, int scrollAmount, int wheelRotation)
          Constructs a MouseWheelEvent object with the specified source component, type, modifiers, coordinates, scroll type, scroll amount, and wheel rotation.
FocusEvent(Component source, int id, boolean temporary, Component opposite)
          Constructs a FocusEvent object with the specified temporary state and opposite Component.
FocusEvent(Component source, int id, boolean temporary)
          Constructs a FocusEvent object and identifies whether or not the change is temporary.
FocusEvent(Component source, int id)
          Constructs a FocusEvent object and identifies it as a permanent change in focus.
InputMethodEvent(Component source, int id, long when, AttributedCharacterIterator text, int committedCharacterCount, TextHitInfo caret, TextHitInfo visiblePosition)
          Constructs an InputMethodEvent with the specified source component, type, time, text, caret, and visiblePosition.
InputMethodEvent(Component source, int id, AttributedCharacterIterator text, int committedCharacterCount, TextHitInfo caret, TextHitInfo visiblePosition)
          Constructs an InputMethodEvent with the specified source component, type, text, caret, and visiblePosition.
InputMethodEvent(Component source, int id, TextHitInfo caret, TextHitInfo visiblePosition)
          Constructs an InputMethodEvent with the specified source component, type, caret, and visiblePosition.
ContainerEvent(Component source, int id, Component child)
          Constructs a ContainerEvent object.
ComponentEvent(Component source, int id)
          Constructs a ComponentEvent object.
 

Uses of Component in java.awt.im
 

Methods in java.awt.im with parameters of type Component
 void InputContext.removeNotify(Component client)
          Notifies the input context that a client component has been removed from its containment hierarchy, or that input method support has been disabled for the component.
 


JSR 216 (Maintenance Release)

Copyright © 2006 Sun Microsystems, Inc. All rights reserved. Use is subject to License Terms. Your use of this web site or any of its content or software indicates your agreement to be bound by these License Terms.

For more information, please consult the JSR 216 specification.
ng HTML r