Participer au site avec un Tip
Rechercher
 

Améliorations / Corrections

Vous avez des améliorations (ou des corrections) à proposer pour ce document : je vous remerçie par avance de m'en faire part, cela m'aide à améliorer le site.

Emplacement :

Description des améliorations :

Module : java.desktop - Package : java.awt
Version documentée : Java SE 17

Classe « Component »

Informations générales

Héritage

java.lang.Object
    java.awt.Component

Interfaces implémentées

java.awt.MenuContainer
java.awt.image.ImageObserver
java.io.Serializable

Définition

public abstract class Component extends java.lang.Object
implements java.awt.MenuContainer,
java.awt.image.ImageObserver,
java.io.Serializable

Description

A venir.

Liste des attributs

Tous les attributs Attributs d'instance Attributs statiques Attributs dépréciés
QualificateursTypeNomDescription
public static float BOTTOM_ALIGNMENT
public static float CENTER_ALIGNMENT
public static float LEFT_ALIGNMENT
public static float RIGHT_ALIGNMENT
public static float TOP_ALIGNMENT
protected AccessibleContext accessibleContext

Liste des constructeurs

Constructeurs Constructeurs dépréciés
ConstructeurDescription
Component()

Liste des propriétés (getters/setters)

Propriétés Propriétés dépréciées
QualificateursTypeNomR/W
public AccessibleContext accessibleContext R/-
public float alignmentX R/-
public float alignmentY R/-
public Color background R/W
public boolean backgroundSet R/-
public BaselineResizeBehavior baselineResizeBehavior R/-
public Rectangle bounds R/W
public ColorModel colorModel R/-
public synchronized ComponentListener[] componentListeners R/-
public ComponentOrientation componentOrientation R/W
public Cursor cursor R/W
public boolean cursorSet R/-
public boolean displayable R/-
public boolean doubleBuffered R/-
public synchronized DropTarget dropTarget R/W
public boolean enabled R/W
public Container focusCycleRootAncestor R/-
public synchronized FocusListener[] focusListeners R/-
public boolean focusOwner R/-
public boolean focusTraversable R/-
public boolean focusTraversalKeysEnabled R/W
public boolean focusable R/W
public Font font R/W
public boolean fontSet R/-
public Color foreground R/W
public boolean foregroundSet R/-
public Graphics graphics R/-
public GraphicsConfiguration graphicsConfiguration R/-
public int height R/-
public synchronized HierarchyBoundsListener[] hierarchyBoundsListeners R/-
public synchronized HierarchyListener[] hierarchyListeners R/-
public boolean ignoreRepaint R/W
public InputContext inputContext R/-
public synchronized InputMethodListener[] inputMethodListeners R/-
public InputMethodRequests inputMethodRequests R/-
public synchronized KeyListener[] keyListeners R/-
public boolean lightweight R/-
public Locale locale R/W
public Point location R/W
public Point locationOnScreen R/-
public Dimension maximumSize R/W
public boolean maximumSizeSet R/-
public Dimension minimumSize R/W
public boolean minimumSizeSet R/-
public Shape mixingCutoutShape -/W
public synchronized MouseListener[] mouseListeners R/-
public synchronized MouseMotionListener[] mouseMotionListeners R/-
public Point mousePosition R/-
public synchronized MouseWheelListener[] mouseWheelListeners R/-
public String name R/W
public boolean opaque R/-
public Container parent R/-
public Dimension preferredSize R/W
public boolean preferredSizeSet R/-
public PropertyChangeListener[] propertyChangeListeners R/-
public boolean showing R/-
public Dimension size R/W
public Toolkit toolkit R/-
public Object treeLock R/-
public boolean valid R/-
public boolean visible R/W
public int width R/-
public int x R/-
public int y R/-

Propriétés héritées de la classe java.lang.Object

class

Liste des méthodes

Toutes les méthodes Méthodes d'instance Méthodes statiques Méthodes concrètes Méthodes abstraites Méthodes dépréciées
QualificateursType de retourPrototype de la méthodeDescription
public boolean action( Event evt, Object what )
public void add( PopupMenu popup )
public synchronized void addComponentListener( ComponentListener l )
public synchronized void addFocusListener( FocusListener l )
public void addHierarchyBoundsListener( HierarchyBoundsListener l )
public void addHierarchyListener( HierarchyListener l )
public synchronized void addInputMethodListener( InputMethodListener l )
public synchronized void addKeyListener( KeyListener l )
public synchronized void addMouseListener( MouseListener l )
public synchronized void addMouseMotionListener( MouseMotionListener l )
public synchronized void addMouseWheelListener( MouseWheelListener l )
public void addNotify()
public void addPropertyChangeListener( String propertyName, PropertyChangeListener listener )
public void addPropertyChangeListener( PropertyChangeListener listener )
public void applyComponentOrientation( ComponentOrientation orientation )
public boolean areFocusTraversalKeysSet( int id )
public Rectangle bounds()
public int checkImage( Image image, int width, int height, ImageObserver observer )
public int checkImage( Image image, ImageObserver observer )
protected AWTEvent coalesceEvents( AWTEvent existingEvent, AWTEvent newEvent )
public boolean contains( Point p )
public boolean contains( int x, int y )
public Image createImage( int width, int height )
public Image createImage( ImageProducer producer )
public VolatileImage createVolatileImage( int width, int height )
public VolatileImage createVolatileImage( int width, int height, ImageCapabilities caps )
public void deliverEvent( Event e )
public void disable()
protected void disableEvents( long eventsToDisable )
public void dispatchEvent( AWTEvent e )
public void doLayout()
public void enable( boolean b )
public void enable()
protected void enableEvents( long eventsToEnable )
public void enableInputMethods( boolean enable )
public void firePropertyChange( String propertyName, long oldValue, long newValue )
public void firePropertyChange( String propertyName, short oldValue, short newValue )
public void firePropertyChange( String propertyName, float oldValue, float newValue )
public void firePropertyChange( String propertyName, double oldValue, double newValue )
protected void firePropertyChange( String propertyName, Object oldValue, Object newValue )
protected void firePropertyChange( String propertyName, boolean oldValue, boolean newValue )
protected void firePropertyChange( String propertyName, int oldValue, int newValue )
public void firePropertyChange( String propertyName, byte oldValue, byte newValue )
public void firePropertyChange( String propertyName, char oldValue, char newValue )
public AccessibleContext getAccessibleContext()
public float getAlignmentX()
public float getAlignmentY()
public Color getBackground()
public int getBaseline( int width, int height )
public BaselineResizeBehavior getBaselineResizeBehavior()
public Rectangle getBounds( Rectangle rv )
public Rectangle getBounds()
public ColorModel getColorModel()
public Component getComponentAt( int x, int y )
public Component getComponentAt( Point p )
public synchronized ComponentListener[] getComponentListeners()
public ComponentOrientation getComponentOrientation()
public Cursor getCursor()
public synchronized DropTarget getDropTarget()
public Container getFocusCycleRootAncestor()
public synchronized FocusListener[] getFocusListeners()
public Set<java.awt.AWTKeyStroke> getFocusTraversalKeys( int id )
public boolean getFocusTraversalKeysEnabled()
public Font getFont()
public FontMetrics getFontMetrics( Font font )
public Color getForeground()
public Graphics getGraphics()
public GraphicsConfiguration getGraphicsConfiguration()
public int getHeight()
public synchronized HierarchyBoundsListener[] getHierarchyBoundsListeners()
public synchronized HierarchyListener[] getHierarchyListeners()
public boolean getIgnoreRepaint()
public InputContext getInputContext()
public synchronized InputMethodListener[] getInputMethodListeners()
public InputMethodRequests getInputMethodRequests()
public synchronized KeyListener[] getKeyListeners()
public <T> T[] getListeners( Class<T> listenerType )
public Locale getLocale()
public Point getLocation()
public Point getLocation( Point rv )
public Point getLocationOnScreen()
public Dimension getMaximumSize()
public Dimension getMinimumSize()
public synchronized MouseListener[] getMouseListeners()
public synchronized MouseMotionListener[] getMouseMotionListeners()
public Point getMousePosition()
public synchronized MouseWheelListener[] getMouseWheelListeners()
public String getName()
public Container getParent()
public Dimension getPreferredSize()
public PropertyChangeListener[] getPropertyChangeListeners( String propertyName )
public PropertyChangeListener[] getPropertyChangeListeners()
public Dimension getSize( Dimension rv )
public Dimension getSize()
public Toolkit getToolkit()
public Object getTreeLock()
public int getWidth()
public int getX()
public int getY()
public boolean gotFocus( Event evt, Object what )
public boolean handleEvent( Event evt )
public boolean hasFocus()
public void hide()
public boolean imageUpdate( Image img, int infoflags, int x, int y, int w, int h )
public boolean inside( int x, int y )
public void invalidate()
public boolean isBackgroundSet()
public boolean isCursorSet()
public boolean isDisplayable()
public boolean isDoubleBuffered()
public boolean isEnabled()
public boolean isFocusable()
public boolean isFocusCycleRoot( Container container )
public boolean isFocusOwner()
public boolean isFocusTraversable()
public boolean isFontSet()
public boolean isForegroundSet()
public boolean isLightweight()
public boolean isMaximumSizeSet()
public boolean isMinimumSizeSet()
public boolean isOpaque()
public boolean isPreferredSizeSet()
public boolean isShowing()
public boolean isValid()
public boolean isVisible()
public boolean keyDown( Event evt, int key )
public boolean keyUp( Event evt, int key )
public void layout()
public void list()
public void list( PrintWriter out, int indent )
public void list( PrintStream out )
public void list( PrintStream out, int indent )
public void list( PrintWriter out )
public Component locate( int x, int y )
public Point location()
public boolean lostFocus( Event evt, Object what )
public Dimension minimumSize()
public boolean mouseDown( Event evt, int x, int y )
public boolean mouseDrag( Event evt, int x, int y )
public boolean mouseEnter( Event evt, int x, int y )
public boolean mouseExit( Event evt, int x, int y )
public boolean mouseMove( Event evt, int x, int y )
public boolean mouseUp( Event evt, int x, int y )
public void move( int x, int y )
public void nextFocus()
public void paint( Graphics g )
public void paintAll( Graphics g )
protected String paramString()
public boolean postEvent( Event e )
public Dimension preferredSize()
public boolean prepareImage( Image image, ImageObserver observer )
public boolean prepareImage( Image image, int width, int height, ImageObserver observer )
public void print( Graphics g )
public void printAll( Graphics g )
protected void processComponentEvent( ComponentEvent e )
protected void processEvent( AWTEvent e )
protected void processFocusEvent( FocusEvent e )
protected void processHierarchyBoundsEvent( HierarchyEvent e )
protected void processHierarchyEvent( HierarchyEvent e )
protected void processInputMethodEvent( InputMethodEvent e )
protected void processKeyEvent( KeyEvent e )
protected void processMouseEvent( MouseEvent e )
protected void processMouseMotionEvent( MouseEvent e )
protected void processMouseWheelEvent( MouseWheelEvent e )
public void remove( MenuComponent popup )
public synchronized void removeComponentListener( ComponentListener l )
public synchronized void removeFocusListener( FocusListener l )
public void removeHierarchyBoundsListener( HierarchyBoundsListener l )
public void removeHierarchyListener( HierarchyListener l )
public synchronized void removeInputMethodListener( InputMethodListener l )
public synchronized void removeKeyListener( KeyListener l )
public synchronized void removeMouseListener( MouseListener l )
public synchronized void removeMouseMotionListener( MouseMotionListener l )
public synchronized void removeMouseWheelListener( MouseWheelListener l )
public void removeNotify()
public void removePropertyChangeListener( PropertyChangeListener listener )
public void removePropertyChangeListener( String propertyName, PropertyChangeListener listener )
public void repaint()
public void repaint( long tm, int x, int y, int width, int height )
public void repaint( int x, int y, int width, int height )
public void repaint( long tm )
protected boolean requestFocus( boolean temporary )
public void requestFocus( Cause cause )
public void requestFocus()
protected boolean requestFocus( boolean temporary, Cause cause )
protected boolean requestFocusInWindow( boolean temporary )
public boolean requestFocusInWindow( Cause cause )
public boolean requestFocusInWindow()
public void reshape( int x, int y, int width, int height )
public void resize( Dimension d )
public void resize( int width, int height )
public void revalidate()
public void setBackground( Color c )
public void setBounds( int x, int y, int width, int height )
public void setBounds( Rectangle r )
public void setComponentOrientation( ComponentOrientation o )
public void setCursor( Cursor cursor )
public synchronized void setDropTarget( DropTarget dt )
public void setEnabled( boolean b )
public void setFocusable( boolean focusable )
public void setFocusTraversalKeys( int id, Set<? extends java.awt.AWTKeyStroke> keystrokes )
public void setFocusTraversalKeysEnabled( boolean focusTraversalKeysEnabled )
public void setFont( Font f )
public void setForeground( Color c )
public void setIgnoreRepaint( boolean ignoreRepaint )
public void setLocale( Locale l )
public void setLocation( int x, int y )
public void setLocation( Point p )
public void setMaximumSize( Dimension maximumSize )
public void setMinimumSize( Dimension minimumSize )
public void setMixingCutoutShape( Shape shape )
public void setName( String name )
public void setPreferredSize( Dimension preferredSize )
public void setSize( Dimension d )
public void setSize( int width, int height )
public void setVisible( boolean b )
public void show()
public void show( boolean b )
public Dimension size()
public String toString()
public void transferFocus()
public void transferFocusBackward()
public void transferFocusUpCycle()
public void update( Graphics g )
public void validate()

Méthodes héritées de la classe java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait