| Modifier and Type | Field and Description |
|---|---|
| protected static final int | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| pack-priv Color | |
| protected static Device | |
| public static boolean | |
| pack-priv boolean | |
| protected static Runnable | |
| pack-priv static Device[] | |
| pack-priv long | |
| pack-priv volatile boolean | |
| pack-priv Point | |
| pack-priv long | |
| pack-priv Error[] | |
| pack-priv Callback | |
| pack-priv long | |
| pack-priv int[] | |
| pack-priv boolean | |
| pack-priv String[] | |
| pack-priv Callback | |
| pack-priv long | |
| pack-priv Object[] | |
| pack-priv long | |
| pack-priv Font | |
| pack-priv boolean | |
| pack-priv Object | |
| pack-priv int | |
| protected long | xDisplay
the handle to the X Display (Warning: This field is platform dependent) Important Note This field is not part of the SWT public API. |
| pack-priv static Callback | |
| pack-priv static long | |
| pack-priv static Callback | |
| pack-priv static long | |
| pack-priv static long | |
| pack-priv static long |
| Access | Constructor and Description |
|---|---|
| public | |
| public | Device(DeviceData
the DeviceData which describes the receiver data)Constructs a new instance of this class. |
| Modifier and Type | Method and Description |
|---|---|
| protected void | |
| protected void | create(DeviceData
the DeviceData which describes the receiver data)Creates the device in the operating system. |
| pack-priv static synchronized void | |
| protected void | |
| public void | |
| pack-priv void | |
| pack-priv static synchronized Device | |
| public Rectangle | Returns: the bounding rectangleReturns a rectangle describing the receiver's size and location. |
| private Rectangle | |
| public Rectangle | Returns: the client areaReturns a rectangle which describes the area of the receiver which is capable of displaying data. |
| public int | Returns: the depth of the screenReturns the bit depth of the screen, which is the number of bits it takes to represent the number of unique colors that the screen is currently capable of displaying. |
| pack-priv static synchronized Device | |
| public DeviceData | Returns: aDeviceData containing the device's data and attributesReturns a |
| protected int | Returns: zoom in percentageGets the scaling factor from the device and calculates the zoom level. |
| public Point | Returns: the horizontal and vertical DPIReturns a point whose x coordinate is the logical horizontal dots per inch of the display, and whose y coordinate is the logical vertical dots per inch of the display. |
| public FontData[] | Returns: the matching font datathe name of the font to look for, or null faceName, boolean if true only scalable fonts are returned, otherwise only non-scalable fonts are returned. scalable)Returns |
| pack-priv Point | |
| public Color | Returns: the matching colorthe color constant id)Returns the matching standard color for the given
constant, which should be one of the color constants
specified in class |
| public Font | |
| public boolean | Returns: trueif warnings are being handled, and false otherwiseReturns |
| protected void | |
| public abstract void | internal_dispose_GC(long
the platform specific GC handle hDC, GCData the platform specific GC data data)Redeclares org. |
| public abstract long | Returns: the platform specific GC handlethe platform specific GC data data)Redeclares org. |
| public boolean | Returns: true when the device is disposed and false otherwiseReturns |
| public boolean | |
| public boolean | |
| pack-priv long | |
| pack-priv void | |
| private void | overrideThemeValues()
For functionality & improved looks, we override some CSS theme values with custom values. |
| pack-priv static synchronized void | |
| protected void | release()
Releases any internal resources back to the operating system and clears all fields except the device handle. |
| public void | |
| public void | setWarnings(boolean
trueif warnings should be printed, and false otherwiseIf the underlying window system supports printing warning messages
to the console, setting warnings to |
| private void | |
| private void | |
| pack-priv static long | |
| pack-priv static long |
| CHANGE_SCALEFACTOR | back to summary |
|---|---|
protected static final int CHANGE_SCALEFACTOR
| |
| COLOR_BLACK | back to summary |
|---|---|
| pack-priv Color COLOR_BLACK | |
| COLOR_BLUE | back to summary |
|---|---|
| pack-priv Color COLOR_BLUE | |
| COLOR_CYAN | back to summary |
|---|---|
| pack-priv Color COLOR_CYAN | |
| COLOR_DARK_BLUE | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_BLUE | |
| COLOR_DARK_CYAN | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_CYAN | |
| COLOR_DARK_GRAY | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_GRAY | |
| COLOR_DARK_GREEN | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_GREEN | |
| COLOR_DARK_MAGENTA | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_MAGENTA | |
| COLOR_DARK_RED | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_RED | |
| COLOR_DARK_YELLOW | back to summary |
|---|---|
| pack-priv Color COLOR_DARK_YELLOW | |
| COLOR_GRAY | back to summary |
|---|---|
| pack-priv Color COLOR_GRAY | |
| COLOR_GREEN | back to summary |
|---|---|
| pack-priv Color COLOR_GREEN | |
| COLOR_MAGENTA | back to summary |
|---|---|
| pack-priv Color COLOR_MAGENTA | |
| COLOR_RED | back to summary |
|---|---|
| pack-priv Color COLOR_RED | |
| COLOR_TRANSPARENT | back to summary |
|---|---|
| pack-priv Color COLOR_TRANSPARENT | |
| COLOR_WHITE | back to summary |
|---|---|
| pack-priv Color COLOR_WHITE | |
| COLOR_YELLOW | back to summary |
|---|---|
| pack-priv Color COLOR_YELLOW | |
| CurrentDevice | back to summary |
|---|---|
| protected static Device CurrentDevice | |
| DEBUG | back to summary |
|---|---|
| public static boolean DEBUG | |
| debug | back to summary |
|---|---|
| pack-priv boolean debug | |
| DeviceFinder | back to summary |
|---|---|
| protected static Runnable DeviceFinder | |
| Devices | back to summary |
|---|---|
| pack-priv static Device[] Devices | |
| displaySettings | back to summary |
|---|---|
| pack-priv long displaySettings | |
| disposed | back to summary |
|---|---|
| pack-priv volatile boolean disposed | |
| dpi | back to summary |
|---|---|
| pack-priv Point dpi | |
| emptyTab | back to summary |
|---|---|
| pack-priv long emptyTab | |
| errors | back to summary |
|---|---|
| pack-priv Error[] errors | |
| gsettingsCallback | back to summary |
|---|---|
| pack-priv Callback gsettingsCallback | |
| gsettingsProc | back to summary |
|---|---|
| pack-priv long gsettingsProc | |
| handler_ids | back to summary |
|---|---|
| pack-priv int[] handler_ids | |
| isConnected | back to summary |
|---|---|
| pack-priv boolean isConnected | |
| log_domains | back to summary |
|---|---|
| pack-priv String[] log_domains | |
| logCallback | back to summary |
|---|---|
| pack-priv Callback logCallback | |
| logProc | back to summary |
|---|---|
| pack-priv long logProc | |
| objects | back to summary |
|---|---|
| pack-priv Object[] objects | |
| shellHandle | back to summary |
|---|---|
| pack-priv long shellHandle | |
| systemFont | back to summary |
|---|---|
| pack-priv Font systemFont | |
| tracking | back to summary |
|---|---|
| pack-priv boolean tracking | |
| trackingLock | back to summary |
|---|---|
| pack-priv Object trackingLock | |
| warningLevel | back to summary |
|---|---|
| pack-priv int warningLevel | |
| xDisplay | back to summary |
|---|---|
| protected long xDisplay the handle to the X Display (Warning: This field is platform dependent) Important Note This field is not part of the SWT public API. It is marked protected only so that it can be shared within the packages provided by SWT. It is not available on all platforms and should never be accessed from application code. | |
| XErrorCallback | back to summary |
|---|---|
| pack-priv static Callback XErrorCallback | |
| XErrorProc | back to summary |
|---|---|
| pack-priv static long XErrorProc | |
| XIOErrorCallback | back to summary |
|---|---|
| pack-priv static Callback XIOErrorCallback | |
| XIOErrorProc | back to summary |
|---|---|
| pack-priv static long XIOErrorProc | |
| XNullErrorProc | back to summary |
|---|---|
| pack-priv static long XNullErrorProc | |
| XNullIOErrorProc | back to summary |
|---|---|
| pack-priv static long XNullIOErrorProc | |
| Device | back to summary |
|---|---|
| public Device() Constructs a new instance of this class. You must dispose the device when it is no longer required. | |
| Device | back to summary |
|---|---|
| public Device(DeviceData data) Constructs a new instance of this class. You must dispose the device when it is no longer required.
| |
| checkDevice | back to summary |
|---|---|
| protected void checkDevice() Throws an
Currently, it is an error to invoke any method (other than
In future releases of SWT, there may be more or fewer error checks and exceptions may be thrown for different reasons.
| |
| create | back to summary |
|---|---|
| protected void create(DeviceData data) Creates the device in the operating system. If the device does not have a handle, this method may do nothing depending on the device.
This method is called before
Subclasses are supposed to reimplement this method and not
call the
| |
| deregister | back to summary |
|---|---|
| pack-priv static synchronized void deregister(Device device) | |
| destroy | back to summary |
|---|---|
| protected void destroy() Destroys the device in the operating system and releases the device's handle. If the device does not have a handle, this method may do nothing depending on the device.
This method is called after
Subclasses are supposed to reimplement this method and not
call the | |
| dispose | back to summary |
|---|---|
| public void dispose() Disposes of the operating system resources associated with
the receiver. After this method has been invoked, the receiver
will answer
| |
| dispose_Object | back to summary |
|---|---|
| pack-priv void dispose_Object(Object object) | |
| findDevice | back to summary |
|---|---|
| pack-priv static synchronized Device findDevice(long xDisplay) | |
| getBounds | back to summary |
|---|---|
| public Rectangle getBounds() Returns a rectangle describing the receiver's size and location.
| |
| getBoundsInPixels | back to summary |
|---|---|
| private Rectangle getBoundsInPixels() | |
| getClientArea | back to summary |
|---|---|
| public Rectangle getClientArea() Returns a rectangle which describes the area of the receiver which is capable of displaying data.
| |
| getDepth | back to summary |
|---|---|
| public int getDepth() Returns the bit depth of the screen, which is the number of bits it takes to represent the number of unique colors that the screen is currently capable of displaying. This number will typically be one of 1, 8, 15, 16, 24 or 32.
| |
| getDevice | back to summary |
|---|---|
| pack-priv static synchronized Device getDevice() | |
| getDeviceData | back to summary |
|---|---|
| public DeviceData getDeviceData() Returns a
| |
| getDeviceZoom | back to summary |
|---|---|
| protected int getDeviceZoom() Gets the scaling factor from the device and calculates the zoom level.
| |
| getDPI | back to summary |
|---|---|
| public Point getDPI() Returns a point whose x coordinate is the logical horizontal dots per inch of the display, and whose y coordinate is the logical vertical dots per inch of the display.
| |
| getFontList | back to summary |
|---|---|
| public FontData[] getFontList(String faceName, boolean scalable) Returns
| |
| getScreenDPI | back to summary |
|---|---|
| pack-priv Point getScreenDPI() | |
| getSystemColor | back to summary |
|---|---|
| public Color getSystemColor(int id) Returns the matching standard color for the given
constant, which should be one of the color constants
specified in class
| |
| getSystemFont | back to summary |
|---|---|
| public Font getSystemFont() Returns a reasonable font for applications to use. On some platforms, this will match the "default font" or "system font" if such can be found. This font should not be freed because it was allocated by the system, not the application. Typically, applications which want the default look should simply not set the font on the widgets they create. Widgets are always created with the correct default font for the class of user-interface component they represent.
| |
| getWarnings | back to summary |
|---|---|
| public boolean getWarnings() Returns
| |
| init | back to summary |
|---|---|
| protected void init() Initializes any internal resources needed by the device.
This method is called after
If subclasses reimplement this method, they must
call the
| |
| internal_dispose_GC | back to summary |
|---|---|
| public abstract void internal_dispose_GC(long hDC, GCData data) Redeclares org. Invokes platform specific functionality to dispose a GC handle. Important Note This method is not part of the public
API for | |
| internal_new_GC | back to summary |
|---|---|
| public abstract long internal_new_GC(GCData data) Redeclares org. Invokes platform specific functionality to allocate a new GC handle. Important Note This method is not part of the public
API for | |
| isDisposed | back to summary |
|---|---|
| public boolean isDisposed() Returns This method gets the dispose state for the device. When a device has been disposed, it is an error to invoke any other method using the device.
| |
| isTracking | back to summary |
|---|---|
public boolean isTracking()
| |
| loadFont | back to summary |
|---|---|
| public boolean loadFont(String path) Loads the font specified by a file. The font will be present in the list of fonts available to the application.
| |
| logProc | back to summary |
|---|---|
| pack-priv long logProc(long log_domain, long log_level, long message, long user_data) | |
| new_Object | back to summary |
|---|---|
| pack-priv void new_Object(Object object) | |
| overrideThemeValues | back to summary |
|---|---|
| private void overrideThemeValues() For functionality & improved looks, we override some CSS theme values with custom values. Note about theme load mechanism: - This method is reached early at start of SWT initialization. Later, platform.ui will call OS.setDarkThemePreferred(true), which tells Gtk to use dark theme. This has the implication that the system theme can be 'Adwaita' (light), but later be 'darkened' by platform.ui. This means that there should not be any color-specific overrides in Adwaita theming because 'Adwaita' is used for both light and dark theme. Note about light/dark system theme: - If the System theme is Adwaita (light), eclipse can be forced to be dark with setDarkThemePreferred(true). But if the System theme is Adwaita-dark, eclipse cannot be made 'light'. Note that much of eclipse 'dark theme' is done by platform.ui's CSS engine, not by SWT. | |
| register | back to summary |
|---|---|
| pack-priv static synchronized void register(Device device) | |
| release | back to summary |
|---|---|
| protected void release() Releases any internal resources back to the operating system and clears all fields except the device handle.
When a device is destroyed, resources that were acquired
on behalf of the programmer need to be returned to the
operating system. For example, if the device allocated a
font to be used as the system font, this font would be
freed in destroy.
If subclasses reimplement this method, they must
call the | |
| setTracking | back to summary |
|---|---|
public void setTracking(boolean tracking)
| |
| setWarnings | back to summary |
|---|---|
| public void setWarnings(boolean warnings) If the underlying window system supports printing warning messages
to the console, setting warnings to
| |
| startTracking | back to summary |
|---|---|
| private void startTracking() | |
| stopTracking | back to summary |
|---|---|
| private void stopTracking() | |
| XErrorProc | back to summary |
|---|---|
| pack-priv static long XErrorProc(long xDisplay, long xErrorEvent) | |
| XIOErrorProc | back to summary |
|---|---|
| pack-priv static long XIOErrorProc(long xDisplay) | |