View License

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from

5.0 | 2 ratings Rate this file 4 Downloads (last 30 days) File Size: 9.18 KB File ID: #28841 Version: 1.0
image thumbnail




Splits a container into two resizable sub-containers (panes).

| Watch this File

File Information

uisplitter divides a container into two sub-containers with a movable splitter. The container to split can be either a figure or a uipanel with no children. Depending on orientation, the splitter is either a vertical bar that separates a left and right pane (for horizontal orientation), or a horizontal bar that separates a bottom and top pane (for vertical orientation). If no container is specified, the figure returned by gcf is assumed as the parent container. Once the container is split, sub-containers may be freely populated with MatLab components. The relative size of the sub-containers may be adjusted interactively using the mouse, or programmatically from code.

This submission resembles UISplitPane by Yair Altman but uses fully documented MatLab functionality only. Usage is mostly compatible, and a wrapper function uisplitpane is available to exhibit a similar interface as UISplitPane. However, this submission is not meant to replicate Yair Altman's excellent submission: not all functionality may be available from UISplitPane.


[panel1,panel2,splitter] = uisplitpane(parent, key, value, key, value, ...);
[panel1,panel2,splitter] = uisplitpane(key, value, key, value, ...);


% create a uisplitpane with default horizontal orientation
[left,right] = uisplitpane;

% create a uisplitpane with vertical orientation
[bottom,top] = uisplitpane('Orientation','vertical');

% create a uisplitpane explicitly specifying the parent container
fig = figure;
[bottom,top] = uisplitpane(fig,'Orientation','ver');

% create a pane where the left part is one third of the right.
[left,right] = uisplitpane('DividerLocation',0.25);


Ui Split Pane Split A Container (Figure/Frame/Uipanel) Into Two Resizable Sub Containers inspired this file.

This file inspired Mplot: Multiple Plots In A Single Figure With List Box Selection.

MATLAB release MATLAB 7.10 (R2010a)
Other requirements The submission should be compatible with MatLab 2008a and later with few or no changes.
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (4)
29 Apr 2015 Saair Quaderi

This breaks in 2014b as a result of the validateattributes checks. Graphics handles are no longer doubles, but objects from 2014b onwards.

Comment only
22 Dec 2014 cece

cece (view profile)

Thank you so much for writing this. It has helped me to call some Java from MATLAB R2013b. I used it in combination with Yair Altman's "uicomponent" code and did the following to make one of the panes a Java JPanel:
newPanel = uicomponent('Parent', right, 'Style', 'JPanel');
then was able to successfully generate a Java JTable in newPanel.

Comment only
22 Dec 2014 cece

cece (view profile)

28 Feb 2012 SSOI SS

Very well written codes, stable and useful.

Contact us