gnu.java.awt.peer.headless

Class HeadlessToolkit


public class HeadlessToolkit
extends ClasspathToolkit

Field Summary

Fields inherited from class java.awt.Toolkit

Object>(), desktopProperties, desktopPropsSupport

Method Summary

void
beep()
@Override
boolean isModalExclusionTypeSupported(Dialog.ModalExclusionType modalExclusionType)
@Override
boolean isModalityTypeSupported(Dialog.ModalityType modalityType)
int
checkImage(Image image, int width, int height, ImageObserver observer)
protected ButtonPeer
createButton(Button target)
protected CanvasPeer
createCanvas(Canvas target)
protected CheckboxPeer
createCheckbox(Checkbox target)
protected CheckboxMenuItemPeer
createCheckboxMenuItem(CheckboxMenuItem target)
protected ChoicePeer
createChoice(Choice target)
protected DialogPeer
createDialog(Dialog target)
DragSourceContextPeer
createDragSourceContextPeer(DragGestureEvent e)
EmbeddedWindowPeer
createEmbeddedWindow(EmbeddedWindow w)
Creates an embedded window peer, and associates it with an EmbeddedWindow object.
protected FileDialogPeer
createFileDialog(FileDialog target)
Font
createFont(int format, InputStream stream)
Creates a font, reading the glyph definitions from a stream.
protected FramePeer
createFrame(Frame target)
Image
createImage(byte[] data, int offset, int len)
Image
createImage(ImageProducer producer)
Image
createImage(String filename)
Image
createImage(URL url)
protected LabelPeer
createLabel(Label target)
protected ListPeer
createList(List target)
protected MenuPeer
createMenu(Menu target)
protected MenuBarPeer
createMenuBar(MenuBar target)
protected MenuItemPeer
createMenuItem(MenuItem target)
protected PanelPeer
createPanel(Panel target)
protected PopupMenuPeer
createPopupMenu(PopupMenu target)
RobotPeer
createRobot(GraphicsDevice screen)
Creates a RobotPeer on a given GraphicsDevice.
protected ScrollPanePeer
createScrollPane(ScrollPane target)
protected ScrollbarPeer
createScrollbar(Scrollbar target)
protected TextAreaPeer
createTextArea(TextArea target)
protected TextFieldPeer
createTextField(TextField target)
protected WindowPeer
createWindow(Window target)
ClasspathFontPeer
getClasspathFontPeer(String name, Map<K,V> attrs)
ColorModel
getColorModel()
String[]
getFontList()
FontMetrics
getFontMetrics(Font name)
protected FontPeer
getFontPeer(String name, int style)
Image
getImage(String name)
Image
getImage(URL url)
GraphicsEnvironment
getLocalGraphicsEnvironment()
Returns a shared instance of the local, platform-specific graphics environment.
PrintJob
getPrintJob(Frame frame, String title, Properties props)
int
getScreenResolution()
Dimension
getScreenSize()
Clipboard
getSystemClipboard()
protected EventQueue
getSystemEventQueueImpl()
Map<K,V>
mapInputMethodHighlight(InputMethodHighlight highlight)
boolean
prepareImage(Image image, int width, int height, ImageObserver observer)
void
sync()

Methods inherited from class gnu.java.awt.ClasspathToolkit

createDesktopPeer, createEmbeddedWindow, createFont, createRobot, getClasspathFontPeer, getFont, getLocalGraphicsEnvironment, getMouseNumberOfButtons, registerImageIOSpis

Methods inherited from class java.awt.Toolkit

addAWTEventListener, addPropertyChangeListener, beep, checkImage, createButton, createCanvas, createCheckbox, createCheckboxMenuItem, createChoice, createComponent, createCustomCursor, createDesktopPeer, createDialog, createDragSourceContextPeer, createFileDialog, createFrame, createImage, createImage, createImage, createImage, createImage, createLabel, createList, createMenu, createMenuBar, createMenuItem, createPanel, createPopupMenu, createScrollPane, createScrollbar, createTextArea, createTextField, createWindow, extends DragGestureRecognizer> T createDragGestureRecognizer, getAWTEventListeners, getAWTEventListeners, getBestCursorSize, getColorModel, getDefaultToolkit, getDesktopProperty, getFontList, getFontMetrics, getFontPeer, getImage, getImage, getLockingKeyState, getMaximumCursorColors, getMenuShortcutKeyMask, getMouseInfoPeer, getNativeContainer, getPrintJob, getPrintJob, getProperty, getPropertyChangeListeners, getPropertyChangeListeners, getScreenInsets, getScreenResolution, getScreenSize, getSystemClipboard, getSystemEventQueue, getSystemEventQueueImpl, getSystemSelection, initializeDesktopProperties, isDynamicLayoutActive, isDynamicLayoutSet, isFrameStateSupported, isModalExclusionTypeSupported, isModalityTypeSupported, lazilyLoadDesktopProperty, loadSystemColors, mapInputMethodHighlight, prepareImage, removeAWTEventListener, removePropertyChangeListener, setDesktopProperty, setDynamicLayout, setLockingKeyState, sync

Methods inherited from class java.lang.Object

clone, equals, extends Object> getClass, finalize, hashCode, notify, notifyAll, toString, wait, wait, wait

Method Details

beep

public void beep()
Overrides:
beep in interface Toolkit

boolean isModalExclusionTypeSupported

public @Override boolean isModalExclusionTypeSupported(Dialog.ModalExclusionType modalExclusionType)

boolean isModalityTypeSupported

public @Override boolean isModalityTypeSupported(Dialog.ModalityType modalityType)

checkImage

public int checkImage(Image image,
                      int width,
                      int height,
                      ImageObserver observer)
Overrides:
checkImage in interface Toolkit

createButton

protected ButtonPeer createButton(Button target)
Overrides:
createButton in interface Toolkit

createCanvas

protected CanvasPeer createCanvas(Canvas target)
Overrides:
createCanvas in interface Toolkit

createCheckbox

protected CheckboxPeer createCheckbox(Checkbox target)
Overrides:
createCheckbox in interface Toolkit

createCheckboxMenuItem

protected CheckboxMenuItemPeer createCheckboxMenuItem(CheckboxMenuItem target)
Overrides:
createCheckboxMenuItem in interface Toolkit

createChoice

protected ChoicePeer createChoice(Choice target)
Overrides:
createChoice in interface Toolkit

createDialog

protected DialogPeer createDialog(Dialog target)
Overrides:
createDialog in interface Toolkit

createDragSourceContextPeer

public DragSourceContextPeer createDragSourceContextPeer(DragGestureEvent e)
Overrides:
createDragSourceContextPeer in interface Toolkit

createEmbeddedWindow

public EmbeddedWindowPeer createEmbeddedWindow(EmbeddedWindow w)
Creates an embedded window peer, and associates it with an EmbeddedWindow object.
Overrides:
createEmbeddedWindow in interface ClasspathToolkit
Parameters:
w - The embedded window with which to associate a peer.

createFileDialog

protected FileDialogPeer createFileDialog(FileDialog target)
Overrides:
createFileDialog in interface Toolkit

createFont

public Font createFont(int format,
                       InputStream stream)
Creates a font, reading the glyph definitions from a stream.

This method provides the platform-specific implementation for the static factory method Font.createFont(int,InputStream).

Overrides:
createFont in interface ClasspathToolkit
Parameters:
format - the format of the font data, such as Font.TRUETYPE_FONT. An implementation may ignore this argument if it is able to automatically recognize the font format from the provided data.
stream - an input stream from where the font data is read in. The stream will be advanced to the position after the font data, but not closed.
Throws:
IllegalArgumentException - if format is not supported.

createFrame

protected FramePeer createFrame(Frame target)
Overrides:
createFrame in interface Toolkit

createImage

public Image createImage(byte[] data,
                         int offset,
                         int len)
Overrides:
createImage in interface Toolkit

createImage

public Image createImage(ImageProducer producer)
Overrides:
createImage in interface Toolkit

createImage

public Image createImage(String filename)
Overrides:
createImage in interface Toolkit

createImage

public Image createImage(URL url)
Overrides:
createImage in interface Toolkit

createLabel

protected LabelPeer createLabel(Label target)
Overrides:
createLabel in interface Toolkit

createList

protected ListPeer createList(List target)
Overrides:
createList in interface Toolkit

createMenu

protected MenuPeer createMenu(Menu target)
Overrides:
createMenu in interface Toolkit

createMenuBar

protected MenuBarPeer createMenuBar(MenuBar target)
Overrides:
createMenuBar in interface Toolkit

createMenuItem

protected MenuItemPeer createMenuItem(MenuItem target)
Overrides:
createMenuItem in interface Toolkit

createPanel

protected PanelPeer createPanel(Panel target)
Overrides:
createPanel in interface Toolkit

createPopupMenu

protected PopupMenuPeer createPopupMenu(PopupMenu target)
Overrides:
createPopupMenu in interface Toolkit

createRobot

public RobotPeer createRobot(GraphicsDevice screen)
            throws AWTException
Creates a RobotPeer on a given GraphicsDevice.
Overrides:
createRobot in interface ClasspathToolkit

createScrollPane

protected ScrollPanePeer createScrollPane(ScrollPane target)
Overrides:
createScrollPane in interface Toolkit

createScrollbar

protected ScrollbarPeer createScrollbar(Scrollbar target)
Overrides:
createScrollbar in interface Toolkit

createTextArea

protected TextAreaPeer createTextArea(TextArea target)
Overrides:
createTextArea in interface Toolkit

createTextField

protected TextFieldPeer createTextField(TextField target)
Overrides:
createTextField in interface Toolkit

createWindow

protected WindowPeer createWindow(Window target)
Overrides:
createWindow in interface Toolkit

getClasspathFontPeer

public ClasspathFontPeer getClasspathFontPeer(String name,
                                              Map<K,V> attrs)

getColorModel

public ColorModel getColorModel()
Overrides:
getColorModel in interface Toolkit

getFontList

public String[] getFontList()
Overrides:
getFontList in interface Toolkit

getFontMetrics

public FontMetrics getFontMetrics(Font name)
Overrides:
getFontMetrics in interface Toolkit

getFontPeer

protected FontPeer getFontPeer(String name,
                               int style)
Overrides:
getFontPeer in interface Toolkit

getImage

public Image getImage(String name)
Overrides:
getImage in interface Toolkit

getImage

public Image getImage(URL url)
Overrides:
getImage in interface Toolkit

getLocalGraphicsEnvironment

public GraphicsEnvironment getLocalGraphicsEnvironment()
Returns a shared instance of the local, platform-specific graphics environment.

This method is specific to GNU Classpath. It gets called by the Classpath implementation of GraphicsEnvironment.getLocalGraphcisEnvironment().

Overrides:
getLocalGraphicsEnvironment in interface ClasspathToolkit

getPrintJob

public PrintJob getPrintJob(Frame frame,
                            String title,
                            Properties props)
Overrides:
getPrintJob in interface Toolkit

getScreenResolution

public int getScreenResolution()
Overrides:
getScreenResolution in interface Toolkit

getScreenSize

public Dimension getScreenSize()
Overrides:
getScreenSize in interface Toolkit

getSystemClipboard

public Clipboard getSystemClipboard()
Overrides:
getSystemClipboard in interface Toolkit

getSystemEventQueueImpl

protected EventQueue getSystemEventQueueImpl()
Overrides:
getSystemEventQueueImpl in interface Toolkit

mapInputMethodHighlight

public Map<K,V> mapInputMethodHighlight(InputMethodHighlight highlight)
Overrides:
mapInputMethodHighlight in interface Toolkit

prepareImage

public boolean prepareImage(Image image,
                            int width,
                            int height,
                            ImageObserver observer)
Overrides:
prepareImage in interface Toolkit

sync

public void sync()
Overrides:
sync in interface Toolkit

HeadlessToolkit.java -- A toolkit for headless mode Copyright (C) 2006 Free Software Foundation, Inc. This file is part of GNU Classpath. GNU Classpath is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. GNU Classpath is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with GNU Classpath; see the file COPYING. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Linking this library statically or dynamically with other modules is making a combined work based on this library. Thus, the terms and conditions of the GNU General Public License cover the whole combination. As a special exception, the copyright holders of this library give you permission to link this library with independent modules to produce an executable, regardless of the license terms of these independent modules, and to copy and distribute the resulting executable under terms of your choice, provided that you also meet, for each linked independent module, the terms and conditions of the license of that module. An independent module is a module which is not derived from or based on this library. If you modify this library, you may extend this exception to your version of the library, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version.