-
- // Static methods -- thunk to the instance /////////////////////////////////////////////////////////////////////////
-
- /** if true, org.xwt.Surface should generate Click messages automatically when a Release happens after a Press and the mouse has not moved much */
- public static boolean needsAutoClick() { return platform._needsAutoClick(); }
-
- /** if true, org.xwt.Surface should generate DoubleClick messages automatically when needed */
- public static boolean needsAutoDoubleClick() { return platform._needsAutoDoubleClick(); }
-
- /** should return true if it is safe to supress full-surface dirties immediately after a window resize */
- public static String getDefaultFont() { return platform._getDefaultFont(); }
-
- /** should return true if it is safe to supress full-surface dirties immediately after a window resize */
- public static boolean supressDirtyOnResize() { return platform._supressDirtyOnResize(); }
-
- /** returns the width of a string in a platform-specific font */
- public static int stringWidth(String font, String text) { return platform._stringWidth(font, text); }
-
- /** returns the maximum ascent of all glyphs in a given platform-specific font */
- public static int getMaxAscent(String font) { return platform._getMaxAscent(font); }
-
- /** returns the maximum descent of all glyphs in a given platform-specific font. Three pixel minimum ensures space for underline. */
- public static int getMaxDescent(String font) { return Math.max(3, platform._getMaxDescent(font)); }
-
- /** returns the maximum number of threads that the XWT engine can create without adversely affecting the host OS */
- public static int maxThreads() { return platform._maxThreads(); }
-
- /** returns a list of all platform-specific fonts available */
- public static String[] listFonts() { return platform._listFonts(); }
-
- /** creates a weak reference */
- public static org.xwt.Weak getWeak(Object o) { return platform._getWeak(o); }
-
- /** opens a connection to the resource identified by URL u, and returns an InputStream */
- public static InputStream urlToInputStream(URL u) throws IOException { return platform._urlToInputStream(u); }
-
- /** returns the contents of the clipboard */
- public static Object getClipBoard() { return clipboardReadEnabled ? platform._getClipBoard() : null; }
-
- /** sets the contents of the clipboard */
- public static void setClipBoard(String s) { platform._setClipBoard(s); }
-
- /** creates a socket object, with or without ssl encryption */
- public static Socket getSocket(String host, int port, boolean ssl, boolean negotiate) throws IOException {
- return platform._getSocket(host, port, ssl, negotiate);