FileDocCategorySizeDatePackage
ControlUtils.javaAPI DocAzureus 3.0.3.42487Thu Feb 09 19:42:56 GMT 2006org.gudy.azureus2.ui.swt.components

ControlUtils

public final class ControlUtils extends Object
General utility methods for SWT controls and components
version
1.0
author
James Yeh
deprecated
JFace has higher-level classes and fields to cover this

Fields Summary
private static boolean
smallOSXControl
Constructors Summary
Methods Summary
public static intgetButtonMargin()

Gets the margin between buttons

The margin may vary between platforms, as specified by their guidelines

return
Margin


                           
       
    
        if(Constants.isOSX)
            return (smallOSXControl) ? 10 : 12;
        else if(Constants.isWindows)
            return 6;
        else
            return 6; // this is gnome's
    
public static intgetDialogButtonMinHeight()

Gets the minimum height of a button in a dialog (usually for alerts)

The size may vary between platforms, as specified by their guidelines

return
Height

        return 20;
    
public static intgetDialogButtonMinWidth()

Gets the minimum width of a button in a dialog (usually for alerts)

The size may vary between platforms, as specified by their guidelines

return
Width

        if(Constants.isOSX)
            return 90;
        else
            return 70;