Java Doc for X11Toolkit.java in  » 6.0-JDK-Modules » j2me » java » awt » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » j2me » java.awt 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   java.awt.Toolkit
      java.awt.X11Toolkit

X11Toolkit
class X11Toolkit extends Toolkit (Code)
The toolkit used by this AWT implementation based on the X11 library.
version:
   1.14, 08/19/02



Constructor Summary
public  X11Toolkit()
    

Method Summary
native public  voidbeep()
     Emits an audio beep.
public  intcheckImage(Image image, int width, int height, ImageObserver observer)
     Indicates the construction status of a specified image that is being prepared for display.

If the values of the width and height arguments are both -1, this method returns the construction status of a screen representation of the specified image in this toolkit. Otherwise, this method returns the construction status of a scaled representation of the image at the specified width and height.

This method does not cause the image to begin loading. An application must call prepareImage to force the loading of an image.

This method is called by the component's checkImage methods.

Information on the flags returned by this method can be found with the definition of the ImageObserver interface.
Parameters:
  image - the image whose status is being checked.
Parameters:
  width - the width of the scaled version whose status isbeing checked, or -1.
Parameters:
  height - the height of the scaled version whose statusis being checked, or -1.
Parameters:
  observer - the ImageObserver object to benotified as the image is being prepared.

public  ImagecreateImage(String filename)
     Returns an image which gets pixel data from the specified file. The returned Image is a new object which will not be shared with any other caller of this method or its getImage variant.
Parameters:
  filename - the name of a file containing pixel datain a recognized file format.
public  ImagecreateImage(URL url)
     Returns an image which gets pixel data from the specified URL. The returned Image is a new object which will not be shared with any other caller of this method or its getImage variant.
Parameters:
  url - the URL to use in fetching the pixel data.
public  ImagecreateImage(ImageProducer producer)
     Creates an image with the specified image producer.
Parameters:
  producer - the image producer to be used.
public  ImagecreateImage(byte[] imagedata, int imageoffset, int imagelength)
     Creates an image which decodes the image stored in the specified byte array, and at the specified offset and length. The data must be in some image format, such as GIF or JPEG, that is supported by this toolkit.
Parameters:
  imagedata - an array of bytes, representingimage data in a supported image format.
Parameters:
  imageoffset - the offset of the beginningof the data in the array.
Parameters:
  imagelength - the length of the data in the array.
public  ColorModelgetColorModel()
     Determines the color model of this toolkit's screen.
public  String[]getFontList()
     Returns the names of the available fonts in this toolkit.

For 1.1, the following font names are deprecated (the replacement name follows):

  • TimesRoman (use Serif)
  • Helvetica (use SansSerif)
  • Courier (use Monospaced)

The ZapfDingbats font is also deprecated in 1.1, but only as a separate fontname.

public  FontMetricsgetFontMetrics(Font font)
     Gets the screen metrics of the font.
Parameters:
  font - a font.
public  ImagegetImage(String filename)
     Returns an image which gets pixel data from the specified file. The underlying toolkit attempts to resolve multiple requests with the same filename to the same returned Image. Since the mechanism required to facilitate this sharing of Image objects may continue to hold onto images that are no longer of use for an indefinite period of time, developers are encouraged to implement their own caching of images by using the createImage variant wherever available.

Compatibility

PersonalJava does not require support of the PNG image file format.
Parameters:
  filename - Filename must reference an image format thatis recognized by this toolkit.
public  ImagegetImage(URL url)
     Returns an image which gets pixel data from the specified URL. The underlying toolkit attempts to resolve multiple requests with the same URL to the same returned Image. Since the mechanism required to facilitate this sharing of Image objects may continue to hold onto images that are no longer of use for an indefinite period of time, developers are encouraged to implement their own caching of images by using the createImage variant wherever available.

Compatibility

PersonalJava does not require support of the PNG image file format.
Parameters:
  url - URL must reference an image format thatis recognized by this toolkit.
public  PrintJobgetPrintJob(Frame frame, String jobtitle, Properties props)
     This method creates and returns a new PrintJob instance which is the result of initiating a print operation on the toolkit's platform.
native public  intgetScreenResolution()
     Returns the screen resolution in dots-per-inch.
public  DimensiongetScreenSize()
     Gets the size of the screen.
public  ClipboardgetSystemClipboard()
     Gets an instance of the system clipboard which interfaces with clipboard facilities provided by the native platform.
protected  EventQueuegetSystemEventQueueImpl()
    
native static  voidpopModal(int xwindow)
     Pops the specified dialog off the modal stack.
public  booleanprepareImage(Image image, int width, int height, ImageObserver observer)
     Prepares an image for rendering.

If the values of the width and height arguments are both -1, this method prepares the image for rendering on the default screen; otherwise, this method prepares an image for rendering on the default screen at the specified width and height.

The image data is downloaded asynchronously in another thread, and an appropriately scaled screen representation of the image is generated.

This method is called by components prepareImage methods.

Information on the flags returned by this method can be found with the definition of the ImageObserver interface.
Parameters:
  image - the image for which to prepare ascreen representation.
Parameters:
  width - the width of the desired screenrepresentation, or -1.
Parameters:
  height - the height of the desired screenrepresentation, or -1.
Parameters:
  observer - the ImageObserverobject to be notified as theimage is being prepared.

native static  voidpushModal(int xwindow)
     Pushes a new modal dislog onto the modal dialog stack.
native public  voidsync()
     Synchronizes this toolkit's graphics state.


Constructor Detail
X11Toolkit
public X11Toolkit()(Code)




Method Detail
beep
native public void beep()(Code)
Emits an audio beep.
since:
   JDK1.1



checkImage
public int checkImage(Image image, int width, int height, ImageObserver observer)(Code)
Indicates the construction status of a specified image that is being prepared for display.

If the values of the width and height arguments are both -1, this method returns the construction status of a screen representation of the specified image in this toolkit. Otherwise, this method returns the construction status of a scaled representation of the image at the specified width and height.

This method does not cause the image to begin loading. An application must call prepareImage to force the loading of an image.

This method is called by the component's checkImage methods.

Information on the flags returned by this method can be found with the definition of the ImageObserver interface.
Parameters:
  image - the image whose status is being checked.
Parameters:
  width - the width of the scaled version whose status isbeing checked, or -1.
Parameters:
  height - the height of the scaled version whose statusis being checked, or -1.
Parameters:
  observer - the ImageObserver object to benotified as the image is being prepared. the bitwise inclusive OR of theImageObserver flags for theimage data that is currently available.
See Also:   java.awt.Toolkit.prepareImage(java.awt.Imageintintjava.awt.image.ImageObserver)
See Also:   java.awt.Component.checkImage(java.awt.Imagejava.awt.image.ImageObserver)
See Also:   java.awt.Component.checkImage(java.awt.Imageintintjava.awt.image.ImageObserver)
See Also:   java.awt.image.ImageObserver
since:
   JDK1.0




createImage
public Image createImage(String filename)(Code)
Returns an image which gets pixel data from the specified file. The returned Image is a new object which will not be shared with any other caller of this method or its getImage variant.
Parameters:
  filename - the name of a file containing pixel datain a recognized file format. an image which gets its pixel data fromthe specified file.
See Also:   java.awt.Toolkit.getImage(java.lang.String)



createImage
public Image createImage(URL url)(Code)
Returns an image which gets pixel data from the specified URL. The returned Image is a new object which will not be shared with any other caller of this method or its getImage variant.
Parameters:
  url - the URL to use in fetching the pixel data. an image which gets its pixel data fromthe specified URL.
See Also:   java.awt.Toolkit.getImage(java.net.URL)



createImage
public Image createImage(ImageProducer producer)(Code)
Creates an image with the specified image producer.
Parameters:
  producer - the image producer to be used. an image with the specified image producer.
See Also:   java.awt.Image
See Also:   java.awt.image.ImageProducer
See Also:   java.awt.Component.createImage(java.awt.image.ImageProducer)
since:
   JDK1.0



createImage
public Image createImage(byte[] imagedata, int imageoffset, int imagelength)(Code)
Creates an image which decodes the image stored in the specified byte array, and at the specified offset and length. The data must be in some image format, such as GIF or JPEG, that is supported by this toolkit.
Parameters:
  imagedata - an array of bytes, representingimage data in a supported image format.
Parameters:
  imageoffset - the offset of the beginningof the data in the array.
Parameters:
  imagelength - the length of the data in the array. an image.
since:
   JDK1.1



getColorModel
public ColorModel getColorModel()(Code)
Determines the color model of this toolkit's screen.

ColorModel is an class that encapsulates the ability to translate between the pixel values of an image and its red, green, blue, and alpha components.

This toolkit method is called by the getColorModel method of the Component class. the color model of this toolkit's screen.
See Also:   java.awt.image.ColorModel
See Also:   java.awt.Component.getColorModel
since:
   JDK1.0




getFontList
public String[] getFontList()(Code)
Returns the names of the available fonts in this toolkit.

For 1.1, the following font names are deprecated (the replacement name follows):

  • TimesRoman (use Serif)
  • Helvetica (use SansSerif)
  • Courier (use Monospaced)

The ZapfDingbats font is also deprecated in 1.1, but only as a separate fontname. Unicode defines the ZapfDingbat characters starting at \u2700, and as of 1.1 Java supports those characters. the names of the available fonts in this toolkit.
since:
   JDK1.0




getFontMetrics
public FontMetrics getFontMetrics(Font font)(Code)
Gets the screen metrics of the font.
Parameters:
  font - a font. the screen metrics of the specified font in this toolkit.
since:
   JDK1.0



getImage
public Image getImage(String filename)(Code)
Returns an image which gets pixel data from the specified file. The underlying toolkit attempts to resolve multiple requests with the same filename to the same returned Image. Since the mechanism required to facilitate this sharing of Image objects may continue to hold onto images that are no longer of use for an indefinite period of time, developers are encouraged to implement their own caching of images by using the createImage variant wherever available.

Compatibility

PersonalJava does not require support of the PNG image file format.
Parameters:
  filename - Filename must reference an image format thatis recognized by this toolkit. The toolkit must be ableto create images from the following image file formats:GIF, JPEG(JFIF), XBM, and PNG. an image which gets its pixel data fromthe specified file.
See Also:   java.awt.Image
See Also:   java.awt.Toolkit.createImage(java.lang.String)



getImage
public Image getImage(URL url)(Code)
Returns an image which gets pixel data from the specified URL. The underlying toolkit attempts to resolve multiple requests with the same URL to the same returned Image. Since the mechanism required to facilitate this sharing of Image objects may continue to hold onto images that are no longer of use for an indefinite period of time, developers are encouraged to implement their own caching of images by using the createImage variant wherever available.

Compatibility

PersonalJava does not require support of the PNG image file format.
Parameters:
  url - URL must reference an image format thatis recognized by this toolkit. The toolkit must beable to create images from the following image file formats:GIF, JPEG(JFIF), XBM, and PNG. an image which gets its pixel data fromthe specified URL.
See Also:   java.awt.Image
See Also:   java.awt.Toolkit.createImage(java.net.URL)



getPrintJob
public PrintJob getPrintJob(Frame frame, String jobtitle, Properties props)(Code)
This method creates and returns a new PrintJob instance which is the result of initiating a print operation on the toolkit's platform.

Compatibility

In Both PersonalJava and Personal Profile, the PrintJob class is optional If the platform does not support printing, an UnsupportedOperationException is thrown. a PrintJob object, ornull if the usercancelled the print job.
exception:
  UnsupportedOperationException - if the implementation does not support printing.
See Also:   java.awt.PrintJob
since:
   JDK1.1



getScreenResolution
native public int getScreenResolution()(Code)
Returns the screen resolution in dots-per-inch. this toolkit's screen resolution, in dots-per-inch.
since:
   JDK1.0



getScreenSize
public Dimension getScreenSize()(Code)
Gets the size of the screen. the size of this toolkit's screen, in pixels.
since:
   JDK1.0



getSystemClipboard
public Clipboard getSystemClipboard()(Code)
Gets an instance of the system clipboard which interfaces with clipboard facilities provided by the native platform.

This clipboard enables data transfer between Java programs and native applications which use native clipboard facilities. an instance of the system clipboard.
See Also:   java.awt.datatransfer.Clipboard
since:
   JDK1.1




getSystemEventQueueImpl
protected EventQueue getSystemEventQueueImpl()(Code)



popModal
native static void popModal(int xwindow)(Code)
Pops the specified dialog off the modal stack.



prepareImage
public boolean prepareImage(Image image, int width, int height, ImageObserver observer)(Code)
Prepares an image for rendering.

If the values of the width and height arguments are both -1, this method prepares the image for rendering on the default screen; otherwise, this method prepares an image for rendering on the default screen at the specified width and height.

The image data is downloaded asynchronously in another thread, and an appropriately scaled screen representation of the image is generated.

This method is called by components prepareImage methods.

Information on the flags returned by this method can be found with the definition of the ImageObserver interface.
Parameters:
  image - the image for which to prepare ascreen representation.
Parameters:
  width - the width of the desired screenrepresentation, or -1.
Parameters:
  height - the height of the desired screenrepresentation, or -1.
Parameters:
  observer - the ImageObserverobject to be notified as theimage is being prepared. true if the image has already beenfully prepared; false otherwise.
See Also:   java.awt.Component.prepareImage(java.awt.Imagejava.awt.image.ImageObserver)
See Also:   java.awt.Component.prepareImage(java.awt.Imageintintjava.awt.image.ImageObserver)
See Also:   java.awt.image.ImageObserver
since:
   JDK1.0




pushModal
native static void pushModal(int xwindow)(Code)
Pushes a new modal dislog onto the modal dialog stack. If events go to a window that does not belong to the modal dialog on the top of the stack then we just beep.



sync
native public void sync()(Code)
Synchronizes this toolkit's graphics state. Some window systems may do buffering of graphics events.

This method ensures that the display is up-to-date. It is useful for animation.
since:
   JDK1.0




Methods inherited from java.awt.Toolkit
public void addAWTEventListener(AWTEventListener listener, long eventMask)(Code)(Java Doc)
abstract public void beep()(Code)(Java Doc)
abstract public int checkImage(Image image, int width, int height, ImageObserver observer)(Code)(Java Doc)
abstract public Image createImage(String filename)(Code)(Java Doc)
abstract public Image createImage(URL url)(Code)(Java Doc)
abstract public Image createImage(ImageProducer producer)(Code)(Java Doc)
public Image createImage(byte[] imagedata)(Code)(Java Doc)
abstract public Image createImage(byte[] imagedata, int imageoffset, int imagelength)(Code)(Java Doc)
public AWTEventListener[] getAWTEventListeners()(Code)(Java Doc)
public AWTEventListener[] getAWTEventListeners(long eventMask)(Code)(Java Doc)
abstract public ColorModel getColorModel()(Code)(Java Doc)
public static Toolkit getDefaultToolkit()(Code)(Java Doc)
static EventQueue getEventQueue()(Code)(Java Doc)
abstract public String[] getFontList()(Code)(Java Doc)
abstract public FontMetrics getFontMetrics(Font font)(Code)(Java Doc)
Graphics getGraphics(Window window)(Code)(Java Doc)
abstract public Image getImage(String filename)(Code)(Java Doc)
abstract public Image getImage(URL url)(Code)(Java Doc)
GraphicsEnvironment getLocalGraphicsEnvironment()(Code)(Java Doc)
public int getMenuShortcutKeyMask()(Code)(Java Doc)
public static String getProperty(String key, String defaultValue)(Code)(Java Doc)
public Insets getScreenInsets(GraphicsConfiguration gc) throws HeadlessException(Code)(Java Doc)
abstract public int getScreenResolution()(Code)(Java Doc)
abstract public Dimension getScreenSize()(Code)(Java Doc)
abstract public Clipboard getSystemClipboard()(Code)(Java Doc)
final public EventQueue getSystemEventQueue()(Code)(Java Doc)
abstract protected EventQueue getSystemEventQueueImpl()(Code)(Java Doc)
public boolean isFrameStateSupported(int state) throws HeadlessException(Code)(Java Doc)
protected void loadSystemColors(int[] systemColors)(Code)(Java Doc)
void notifyAWTEventListeners(AWTEvent theEvent)(Code)(Java Doc)
abstract public boolean prepareImage(Image image, int width, int height, ImageObserver observer)(Code)(Java Doc)
public void removeAWTEventListener(AWTEventListener listener)(Code)(Java Doc)
abstract public void sync()(Code)(Java Doc)

Methods inherited from java.lang.Object
public boolean equals(Object obj)(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.