Function_reference |

## 2.4: uix.VBoxFlex

Arrange elements vertically with draggable dividers

`obj``= uix.VBoxFlex(``)`
  creates a new vertical box layout with draggable dividers and with all properties set to defaults. The output is a new layout object that can be used as the parent for other user-interface components.
`obj``= uix.VBoxFlex(``prop``,``value``,``...``)`
  also sets one or more property values from the list below.

### uix.VBoxFlex properties

Property | Value | Description
--- | --- | ---
`BackgroundColor` | `colorspec` | Color to use for exposed areas of the layout background. This can be an RGB triple (e.g. [0 0 1]) or a colour name (e.g. 'b').
`BeingDeleted` | on | off | Deletion status.
`Contents` | empty GraphicsPlaceholder array | array of graphics objects | Children within this layout, regardless of HandleVisibility. Note that this can only be set to permutations of itself.
`DeleteFcn` | `function_handle` | Function to call when the layout is being deleted.
`DividerMarkings` | on | off | Show markings on the draggable dividers (default 'on').
`Heights` | double vector | Height of each of the children. Positive entries indicate fixed sizes in pixels, negative values indicate relative weights for resizing. The size of this vector must always match the size of Contents.
`MinimumHeights` | double vector | Minimum height in pixels of each of the children. The size of this vector must match the size of Contents.
`Padding` | positive integer | Number of pixels of extra space around the outside of the layout.
`Parent` | empty GraphicsPlaceholder array | figure | container | Parent of the layout.
`Position` | [x y w h] | Position (x,y) and size (w,h) within figure or container.
`Spacing` | positive integer | Number of pixels of extra space to leave between elements in the layout (default 5).
`Tag` | string | Tag to associate with layout.
`Type` | string | Type of graphics object.
`Units` | inches | centimeters | normalized | points | pixels | characters | Position units.
`Visible` | on | off | Visibility.

### For example:

    f = figure( 'Name', 'uix.VBoxFlex example' );
    b = uix.VBoxFlex( 'Parent', f );
    uicontrol( 'Parent', b, 'Background', 'r' )
    uicontrol( 'Parent', b, 'Background', 'b' )
    uicontrol( 'Parent', b, 'Background', 'g' )
    uicontrol( 'Parent', b, 'Background', 'y' )
    set( b, 'Heights', [-1 100 -2 -1], 'Spacing', 5 );

See also:

- `uix.VBox` - for creating a vertical arrangement
- `uix.HBoxFlex` - for creating a horizontal arrangement with draggable dividers

© 2019 The MathWorks Ltd `•` Terms of Use `•` Patents `•` Trademarks