java.awt
public abstract class GraphicsEnvironment extends Object
Since: 1.4
See Also: GraphicsDevice GraphicsConfiguration
UNKNOWN: updated to 1.4
Constructor Summary | |
---|---|
protected | GraphicsEnvironment()
The environment must be obtained from a factory or query method, hence
this constructor is protected. |
Method Summary | |
---|---|
abstract Graphics2D | createGraphics(BufferedImage image)
Return a Graphics2D object which will render into the specified image.
|
abstract Font[] | getAllFonts()
Returns an array of the one-point size fonts available in this
environment. |
abstract String[] | getAvailableFontFamilyNames()
Returns an array of the font family names available in this environment.
|
abstract String[] | getAvailableFontFamilyNames(Locale l)
Returns an array of the font family names available in this environment,
localized to the current Locale if l is non-null. |
Point | getCenterPoint()
Returns the point where a window should be centered. |
abstract GraphicsDevice | getDefaultScreenDevice()
Get the default screen GraphicsDevice object.
|
static GraphicsEnvironment | getLocalGraphicsEnvironment()
Returns the local graphics environment. |
Rectangle | getMaximumWindowBounds()
Returns the maximum bounds for a centered window object. |
abstract GraphicsDevice[] | getScreenDevices()
Get an array of all the GraphicsDevice objects.
|
static boolean | isHeadless()
Check if the local environment is headless, meaning that it does not
support a display, keyboard, or mouse. |
boolean | isHeadlessInstance()
Check if the given environment is headless, meaning that it does not
support a display, keyboard, or mouse. |
Parameters: image the image to render into
Returns: the object that renders into the image
deriveFont
.
Only one master version of each font appears in this array; if a font
can be derived from another, it must be created in that way.
Returns: the array of available fonts
Since: 1.2
See Also: getAvailableFontFamilyNames Font
Returns: the array of available font families
Since: 1.2
See Also: getAllFonts getFamily
Parameters: l the locale to use
Returns: the array of available font families, localized
Since: 1.2
See Also: getAllFonts getFamily
Returns: the centering point
Throws: HeadlessException if the environment is headless
Since: 1.4
See Also: getMaximumWindowBounds
Returns: the default screen device
Throws: HeadlessException if the environment is headless
Returns: the local environment
Returns: the maximum window bounds
Throws: HeadlessException if the environment is headless
Since: 1.4
See Also: getCenterPoint getBounds getScreenInsets
Returns: the available graphics devices, may be 0 length
Throws: HeadlessException if the environment is headless
Returns: true if the environment is headless, meaning that graphics are unsupported
Since: 1.4
Returns: true if the environment is headless, meaning that graphics are unsupported
Since: 1.4