Java javax.swing SwingUtilities fields, constructors, methods, implement or subclass

Example usage for Java javax.swing SwingUtilities fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for javax.swing SwingUtilities.

The text is from its open source code.

Method

Rectangle[]computeDifference(Rectangle rectA, Rectangle rectB)
Convenience returning an array of rect representing the regions within rectA that do not overlap with rectB.
RectanglecomputeIntersection(int x, int y, int width, int height, Rectangle dest)
Convenience to calculate the intersection of two rectangles without allocating a new rectangle.
intcomputeStringWidth(FontMetrics fm, String str)
Compute the width of the string using a font with the specified "metrics" (sizes).
MouseEventconvertMouseEvent(Component source, MouseEvent sourceEvent, Component destination)
Returns a MouseEvent similar to sourceEvent except that its x and y members have been converted to destination's coordinate system.
PointconvertPoint(Component source, Point aPoint, Component destination)
Convert a aPoint in source coordinate system to destination coordinate system.
PointconvertPoint(Component source, int x, int y, Component destination)
Convert the point (x,y) in source coordinate system to destination coordinate system.
voidconvertPointFromScreen(Point p, Component c)
Convert a point from a screen coordinates to a component's coordinate system
voidconvertPointToScreen(Point p, Component c)
Convert a point from a component's coordinate system to screen coordinates.
RectangleconvertRectangle(Component source, Rectangle aRectangle, Component destination)
Convert the rectangle aRectangle in source coordinate system to destination coordinate system.
ContainergetAncestorOfClass(Class c, Component comp)
Convenience method for searching above comp in the component hierarchy and returns the first object of class c it finds.
ComponentgetDeepestComponentAt(Component parent, int x, int y)
Returns the deepest visible descendent Component of parent that contains the location x, y.
RectanglegetLocalBounds(Component aComponent)
Return the rectangle (0,0,bounds.width,bounds.height) for the component aComponent
ComponentgetRoot(Component c)
Returns the root component for the current component tree.
JRootPanegetRootPane(Component c)
If c is a JRootPane descendant return its JRootPane ancestor.
ActionMapgetUIActionMap(JComponent component)
Returns the ActionMap provided by the UI in component component.
InputMapgetUIInputMap(JComponent component, int condition)
Returns the InputMap provided by the UI for condition condition in component component.
ContainergetUnwrappedParent(Component component)
Returns the first ancestor of the component which is not an instance of JLayer .
ComponentgetUnwrappedView(JViewport viewport)
Returns the first JViewport 's descendant which is not an instance of JLayer .
WindowgetWindowAncestor(Component c)
Returns the first Window ancestor of c, or null if c is not contained inside a Window.
voidinvokeAndWait(final Runnable doRun)
Causes doRun.run() to be executed synchronously on the AWT event dispatching thread.
voidinvokeLater(Runnable doRun)
Causes doRun.run() to be executed asynchronously on the AWT event dispatching thread.
booleanisDescendingFrom(Component a, Component b)
Return true if a component a descends from a component b
booleanisEventDispatchThread()
Returns true if the current thread is an AWT event dispatching thread.
booleanisLeftMouseButton(MouseEvent anEvent)
Returns true if the mouse event specifies the left mouse button.
booleanisMiddleMouseButton(MouseEvent anEvent)
Returns true if the mouse event specifies the middle mouse button.
booleanisRightMouseButton(MouseEvent anEvent)
Returns true if the mouse event specifies the right mouse button.
StringlayoutCompoundLabel(JComponent c, FontMetrics fm, String text, Icon icon, int verticalAlignment, int horizontalAlignment, int verticalTextPosition, int horizontalTextPosition, Rectangle viewR, Rectangle iconR, Rectangle textR, int textIconGap)
Compute and return the location of the icons origin, the location of origin of the text baseline, and a possibly clipped version of the compound labels string.
StringlayoutCompoundLabel(FontMetrics fm, String text, Icon icon, int verticalAlignment, int horizontalAlignment, int verticalTextPosition, int horizontalTextPosition, Rectangle viewR, Rectangle iconR, Rectangle textR, int textIconGap)
Compute and return the location of the icons origin, the location of origin of the text baseline, and a possibly clipped version of the compound labels string.
voidpaintComponent(Graphics g, Component c, Container p, int x, int y, int w, int h)
Paints a component to the specified Graphics.
voidpaintComponent(Graphics g, Component c, Container p, Rectangle r)
Paints a component to the specified Graphics.
voidreplaceUIActionMap(JComponent component, ActionMap uiActionMap)
Convenience method to change the UI ActionMap for component to uiActionMap.
voidreplaceUIInputMap(JComponent component, int type, InputMap uiInputMap)
Convenience method to change the UI InputMap for component to uiInputMap.
voidupdateComponentTreeUI(Component c)
A simple minded look and feel change: ask each node in the tree to updateUI() -- that is, to initialize its UI property with the current look and feel.
WindowwindowForComponent(Component c)
Returns the first Window ancestor of c, or null if c is not contained inside a Window.