RE: 4 pane SplitContainer

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



The existing controls do not do this as they are separate controls. You can
create a custom control that combines the splitters into a single control and
handles the SplitterMoving event for both containers. If the
MouseCursorX/MouseCursorY happens to be around the intersection of the
containers then you could for a split of the second container. The biggest
issue is that while the first container is being split the second container
has to mimic this by continually resizing. If the split is cancelled then
the second container has to be undone. The performance could be slow. I'd
almost recommend not using the splitters during the split operation. Instead
simply keep drawing a vertical and horizontal line from the current mouse
position to the edge of the client area. This would give the illusion of a
splitter without the overhead of a continual redraw. When the split is
finished then notify each container to adjust it's size. The biggest issue
here is getting the splitters to disappear without their contents. Perhaps
you could temporarily make them transparent or something. Then again maybe
showing the original position is not that bad either. As a final note
perhaps the TableLayoutPanel or one of its ilk may work better in this case.
I don't know if they are resizable by the user or not. Finally I'd like to
say that this feature might not be commonly used and therefore may not be
worth the effort needed to implement it. Most splitters are used in 2 or 3
panel views.

Hope this helps,
Michael Taylor - 9/19/05

"shu" wrote:

> The SplitContainer divides the space in two, either horizontally or
> vertically.
> I'd like to divide the space in four. By adding more splitters, the
> problem is that they don't keep in synch automatically. It'd be nice if
> when the mouse hovers in the center of the four regions a cross
> movement icon is displayed, and movement in the two axis is allowed.
> With the solution of adding more splitters the user is forced to first
> move in one direction and then in the other one.
>
> What do you recommend to achieve this?
>
> Thanks.
>
>
.



Relevant Pages

  • Do you like the SplitterContainer?
    ... I had a form with 6 panels separated by 5 splitters. ... The first container replace the first panel. ... Supposed the original were not panels but, say, pictureboxes. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Do you like the SplitterContainer?
    ... The first container replace the first panel. ... Supposed the original were not panels but, say, pictureboxes. ... splitters and 6 pictureboxes. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Do you like the SplitterContainer?
    ... of the split containers inside some of the panels from other containers. ... container in the top and bottom. ... splitters and 6 pictureboxes. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Hide/Show controls and Z-Order
    ... There are also 4 splitters. ... When the controls are hidden and then shown ... However, I think the basic issue is that any time you change the hidden/shown state of any control, you should simply do the whole layout all over again. ... This will avoid the complications of the different permutations, ...
    (microsoft.public.dotnet.languages.csharp)
  • Docking of multiple controls within a parent control
    ... I want to be abe to maintain minimum sizes of all child controls. ... Each of the child controls (except splitters) validates it's ...
    (microsoft.public.dotnet.framework.windowsforms.controls)