Nevron Open Vision Documentation

The splitter is a widget that splits its content area into two resizable panes, which can be interactively resized with help of a thumb located in the middle.


The splitter provides the following properties:

Code Example

The following example demonstrates how to create a splitter and set the minimum sizes of its planes. The planes have borders and a solid background, so that you can easily distinguish them:

Splitter Example
Copy Code
NSplitter splitter = new NSplitter();
splitter.Pane1.Content = new NLabel("Pane1 Min Width/Height = 100");
splitter.Pane1.Background = new NBackground(NColor.LightGreen);
splitter.Pane1.Border = NBorder.CreateFilledBorder(NColor.Black);
splitter.Pane1.BorderThickness = new NMargins(1);
splitter.Pane1.MinWidth = 100;
splitter.Pane1.MinHeight = 100;
splitter.Pane2.Content = new NLabel("Pane2 Min Width/Height = 200");
splitter.Pane2.Background = new NBackground(NColor.LightBlue);
splitter.Pane2.Border = NBorder.CreateFilledBorder(NColor.Black);
splitter.Pane2.BorderThickness = new NMargins(1);
splitter.Pane2.MinWidth = 200;
splitter.Pane2.MinHeight = 200;
splitter.ResizeStep = 20;

The result of this piece of code will be:

Because of the set minimum size constraints, the splitter will not allow you to move its thumb so that there are less than 100 dips on left side of the splitter or less than 200 dips on its right side.

Send Feedback