problem double clicking on a splitter

hello,

I've a rather complex application with a number of splitters and some of these splitters have a
weird behavior,
doubleclicking on the spitterbar (sash), enlarges to left panel to full size and reduces the right
panel to zero.
After this happens, there is no way to get the splitter back.

I finally discovered what was special about these splitters, I use minimum panesize of zero
(because I want to hide the left pane with an accelerator key)

    self.App_Splitter.SetMinimumPaneSize ( 0 )

Changing the minimum Pane size to 1, solves the problem.

Is this the correct way, are there better ways ?

Is this a bug or a feature of the splitter window ?

thanks,
Stef Mientki

It's a feature. The double-click is used to allow the user to unsplit a splitter. If you want to disable it then you can catch the EVT_SPLITTER_DCLICK event and call event.Veto() in the handler.

···

On 9/7/10 12:18 PM, Stef Mientki wrote:

  hello,

I've a rather complex application with a number of splitters and some of these splitters have a
weird behavior,
doubleclicking on the spitterbar (sash), enlarges to left panel to full size and reduces the right
panel to zero.
After this happens, there is no way to get the splitter back.

I finally discovered what was special about these splitters, I use minimum panesize of zero
(because I want to hide the left pane with an accelerator key)

     self.App_Splitter.SetMinimumPaneSize ( 0 )

Changing the minimum Pane size to 1, solves the problem.

Is this the correct way, are there better ways ?

Is this a bug or a feature of the splitter window ?

--
Robin Dunn
Software Craftsman

Isn’t this the sort of ‘feature’ that should be enabled explicitly by the programmer, rather than blind-siding people with what seems to be a ‘bug’?

···

On Tuesday, September 7, 2010 1:49:35 PM UTC-7, Robin Dunn wrote:

It’s a feature. The double-click is used to allow the user to unsplit a
splitter. If you want to disable it then you can catch the
EVT_SPLITTER_DCLICK event and call event.Veto() in the handler.


Robin Dunn
Software Craftsman
http://wxPython.org

On 9/7/10 12:18 PM, Stef Mientki wrote:

hello,

I’ve a rather complex application with a number of splitters and some of these splitters have a
weird behavior,
doubleclicking on the spitterbar (sash), enlarges to left panel to full size and reduces the right
panel to zero.
After this happens, there is no way to get the splitter back.

I finally discovered what was special about these splitters, I use minimum panesize of zero
(because I want to hide the left pane with an accelerator key)

 self.App_Splitter.SetMinimumPaneSize  ( 0 )

Changing the minimum Pane size to 1, solves the problem.

Is this the correct way, are there better ways ?

Is this a bug or a feature of the splitter window ?