Package VASSAL.tools

Class ComponentSplitter

java.lang.Object
VASSAL.tools.ComponentSplitter

@Deprecated(since="2020-11-07", forRemoval=true) public class ComponentSplitter extends Object
Deprecated, for removal: This API element is subject to removal in a future version.
Use SplitPane instead.
Provides support for hidden panels. Use the split methods to create an instance of ComponentSplitter.SplitPane, which can then be manipulated to show and hide the panel
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    Deprecated, for removal: This API element is subject to removal in a future version.
    Contains methods to automatically show/hide one of its components (the "hideable" component) while the other (the "base" component) remains always visible.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated, for removal: This API element is subject to removal in a future version.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    getSplitAncestor​(Component c, int index)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Search the containment hierarchy for the index-th ComponentSplitter.SplitPane ancestor of a target component
    static void
    main​(String[] args)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    split​(Component base, Component newComponent, int hideablePosition, boolean resize)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Create a new hideable panel beside the base component.
    static Component
    splitAncestorOf​(Component c, int index)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Search the containment hierarchy for the ith ComponentSplitter.SplitPane ancestor of a target component
    splitBottom​(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Create a new hideable panel to the bottom of the base component.
    splitLeft​(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Create a new hideable panel to the left of the base component.
    splitRight​(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Create a new hideable panel to the right of the base component.
    splitTop​(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Create a new hideable panel to the top of the base component.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ComponentSplitter

      public ComponentSplitter()
      Deprecated, for removal: This API element is subject to removal in a future version.
  • Method Details

    • splitRight

      public ComponentSplitter.SplitPane splitRight(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Create a new hideable panel to the right of the base component. The base component is replaced by a ComponentSplitter.SplitPane
      Parameters:
      base - the base component
      hideableComponent - the hideable component
      resizeOnVisibilityChange - If true, the containing window will expand or shrink to an appropriate size when the hideable component is shown or hidden
      Returns:
      the ComponentSplitter.SplitPane containing the two components
    • splitLeft

      public ComponentSplitter.SplitPane splitLeft(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Create a new hideable panel to the left of the base component. The base component is replaced by a ComponentSplitter.SplitPane
      Parameters:
      base - the base component
      hideableComponent - the hideable component
      resizeOnVisibilityChange - If true, the containing window will expand or shrink to an appropriate size when the hideable component is shown or hidden
      Returns:
      the ComponentSplitter.SplitPane containing the two components
    • splitBottom

      public ComponentSplitter.SplitPane splitBottom(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Create a new hideable panel to the bottom of the base component. The base component is replaced by a ComponentSplitter.SplitPane
      Parameters:
      base - the base component
      hideableComponent - the hideable component
      resizeOnVisibilityChange - If true, the containing window will expand or shrink to an appropriate size when the hideable component is shown or hidden
      Returns:
      the ComponentSplitter.SplitPane containing the two components
    • splitTop

      public ComponentSplitter.SplitPane splitTop(Component base, Component hideableComponent, boolean resizeOnVisibilityChange)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Create a new hideable panel to the top of the base component. The base component is replaced by a ComponentSplitter.SplitPane
      Parameters:
      base - the base component
      hideableComponent - the hideable component
      resizeOnVisibilityChange - If true, the containing window will expand or shrink to an appropriate size when the hideable component is shown or hidden
      Returns:
      the ComponentSplitter.SplitPane containing the two components
    • getSplitAncestor

      public Component getSplitAncestor(Component c, int index)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Search the containment hierarchy for the index-th ComponentSplitter.SplitPane ancestor of a target component
      Parameters:
      c - the target component
      index - If -1, return the last ComponentSplitter.SplitPane ancestor
      Returns:
      the ComponentSplitter.SplitPane ancestor, or the original component if none is found
    • splitAncestorOf

      public static Component splitAncestorOf(Component c, int index)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Search the containment hierarchy for the ith ComponentSplitter.SplitPane ancestor of a target component
      Parameters:
      c - the target component
      index - If -1, return the last ComponentSplitter.SplitPane ancestor
      Returns:
      the ComponentSplitter.SplitPane ancestor, or the original component if none is found
    • split

      public static ComponentSplitter.SplitPane split(Component base, Component newComponent, int hideablePosition, boolean resize)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Create a new hideable panel beside the base component. The base component is replaced by a ComponentSplitter.SplitPane
      Parameters:
      base - the base component
      newComponent - the hideable component, one of ComponentSplitter.SplitPane.HIDE_TOP, ComponentSplitter.SplitPane.HIDE_RIGHT, ComponentSplitter.SplitPane.HIDE_BOTTOM, ComponentSplitter.SplitPane.HIDE_LEFT
      hideablePosition - the position of the hideable component
      resize - If true, the containing window will expand or shrink to an appropriate size when the hideable component is shown or hidden
      Returns:
      the ComponentSplitter.SplitPane containing the two components
    • main

      public static void main(String[] args)
      Deprecated, for removal: This API element is subject to removal in a future version.