| java.lang.Object org.eclipse.pde.internal.ui.util.SWTUtil
SWTUtil | public class SWTUtil (Code) | | Utility class to simplify access to some SWT resources.
|
Method Summary | |
public static int | getButtonWidthHint(Button button) Returns a width hint for a button control. | public static Shell | getShell(Widget widget) Returns the shell for the given widget. | public static Display | getStandardDisplay() Returns the standard display to be used. | public static void | setButtonDimensionHint(Button button) Sets width and height hint for the button control. | public static void | setDialogSize(Dialog dialog, int width, int height) |
getButtonWidthHint | public static int getButtonWidthHint(Button button)(Code) | | Returns a width hint for a button control.
|
getShell | public static Shell getShell(Widget widget)(Code) | | Returns the shell for the given widget. If the widget doesn't represent
a SWT object that manage a shell, null is returned.
the shell for the given widget |
getStandardDisplay | public static Display getStandardDisplay()(Code) | | Returns the standard display to be used. The method first checks, if
the thread calling this method has an associated disaply. If so, this
display is returned. Otherwise the method returns the default display.
|
setButtonDimensionHint | public static void setButtonDimensionHint(Button button)(Code) | | Sets width and height hint for the button control.
Note: This is a NOP if the button's layout data is not
an instance of GridData .
Parameters: the - button for which to set the dimension hint |
setDialogSize | public static void setDialogSize(Dialog dialog, int width, int height)(Code) | | |
|
|