com.vlsolutions.swing.docking
Class DockingPreferences

java.lang.Object
  extended by com.vlsolutions.swing.docking.DockingPreferences

public class DockingPreferences
extends java.lang.Object

This is the centralized settings repository for managing docking look and feel.

It acts as a facade for installing common settings.

This class contains only high-level settings, like the heavyweight components support or the global desktop style (shadowed or flat). To access low-level properties, use the DockingUISettings class instead.

Since:
1.1
See Also:
DockingUISettings

Method Summary
static AutoHidePolicy getAutoHidePolicy()
           
static void initHeavyWeightUsage()
          Facade method used to allow mixing of lightweight and heavyweight components in the desktop.
static void initHeavyWeightUsage(boolean isSingleHeavyWeightComponent)
          Facade method used to allow mixing of lightweight and heavyweight components in the desktop.
static boolean isLightWeightUsageEnabled()
           
static boolean isSingleHeavyWeightComponent()
           
static void setCustomSplitDesktopStyle(java.awt.image.BufferedImage horizontalTile, java.awt.image.BufferedImage verticalTile)
          Another docking style with custom tiles between dockables.
static void setDottedDesktopStyle()
          Another docking style with ligh dots between dockables.
static void setFlatDesktopStyle()
          Convenience method to use the VLDocking 2.0 layout and border style.
static void setLightweigthComponentEnabled(boolean lightweight)
          A simple utility method to configure the docking framework to work properly with heavyweight component.
static void setShadowDesktopStyle()
          Convenience method to use the VLDocking 1.0 layout and border style (with shadows around dockables)
static void setSingleHeavyWeightComponent(boolean single)
          Notifies the framework that there is only one dockable that is heavyweight.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getAutoHidePolicy

public static final AutoHidePolicy getAutoHidePolicy()

setLightweigthComponentEnabled

public static void setLightweigthComponentEnabled(boolean lightweight)
A simple utility method to configure the docking framework to work properly with heavyweight component.

Don't forget to invoke also the following general swing methods :

      ToolTipManager.sharedInstance().setLightWeightPopupEnabled(false);
      JPopupMenu.setDefaultLightWeightPopupEnabled(false);        

If you are sure you will always use heavyweight component, you can replace this method invocation by initHeavyWeightUsage(), which will do all the work for you (even the general swing methods invocation).


isLightWeightUsageEnabled

public static boolean isLightWeightUsageEnabled()

setSingleHeavyWeightComponent

public static void setSingleHeavyWeightComponent(boolean single)
Notifies the framework that there is only one dockable that is heavyweight.

This allows optimizations and workarounds (for properly using the JDIC WebBrowser for example).


isSingleHeavyWeightComponent

public static boolean isSingleHeavyWeightComponent()

initHeavyWeightUsage

public static void initHeavyWeightUsage()
Facade method used to allow mixing of lightweight and heavyweight components in the desktop.

This method is a shortcut for :

        ToolTipManager.sharedInstance().setLightWeightPopupEnabled(false);
        JPopupMenu.setDefaultLightWeightPopupEnabled(false);        
        setLightweigthComponentEnabled(false);
        getAutoHidePolicy().setExpansionDuration(0);
 


initHeavyWeightUsage

public static void initHeavyWeightUsage(boolean isSingleHeavyWeightComponent)
Facade method used to allow mixing of lightweight and heavyweight components in the desktop.


setShadowDesktopStyle

public static void setShadowDesktopStyle()
Convenience method to use the VLDocking 1.0 layout and border style (with shadows around dockables)


setFlatDesktopStyle

public static void setFlatDesktopStyle()
Convenience method to use the VLDocking 2.0 layout and border style.

The new "flat style" uses light borders around dockables and top tab placements.

This style is the new default one, so there is no need to call this method unless you want to swap dynamically between desktop styles.


setDottedDesktopStyle

public static void setDottedDesktopStyle()
Another docking style with ligh dots between dockables.


setCustomSplitDesktopStyle

public static void setCustomSplitDesktopStyle(java.awt.image.BufferedImage horizontalTile,
                                              java.awt.image.BufferedImage verticalTile)
Another docking style with custom tiles between dockables.



© Copyright 2004-2007 VLSolutions. All Rights Reserved.
www.vlsolutions.com : Java Components - Smart Client Applications