Kirix Support Forums

Problem with 'non-resizable' panes.

Please post all general questions, comments, bug reports, and any other wxAUI feedback here.

Problem with 'non-resizable' panes.

Postby funkyboy on Mon Nov 06, 2006 10:36 am

Hi:

I'm testing this library and it's an amazing add-on to the wxWidgets lib.

I have a problem with non-resizable panes.

I have some code like this:

m_FrameManager.GetPane("rete").MinSize(50, 50);
m_FrameManager.GetPane("rete").FloatingSize(50, 50);
m_FrameManager.GetPane("rete").Resizable(false);

When I undock the pane, the size of the pane in the X direction is right but on the Y direction it's as big as the screen. If I change the Resizable property to true, it works without any problem, but then the pane could be resized when floating. I want the panes cannot be reized when they're floating

Also I have found that when the pane is floating if I move the pane outside the window, sometimes the pane is docked 'outside the window'. If you resize the main window, you will see the window docked in a fixed position inside the window, but it's not in the edge but inside the window. This only happens when the pane is not-resizable.

Any ideas?

Thanks
funkyboy
Registered User
 
Posts: 5
Joined: Mon Nov 06, 2006 10:18 am

Postby funkyboy on Mon Nov 06, 2006 11:27 am

I have found that it's very esay to reproduce the dock outside the window problem.

1.- Create a pane with the resizable property set to false.
2.- Undock the pane.
3.- Move the pane and move the mouse pointer near the right-bottom end of the window, outside the window, and drop thw pane.
4.- The pane will dissapear and if you resize the main window you will see the pane docked at the end of the window.

btw: I'm using the latest code available in the CVS.
funkyboy
Registered User
 
Posts: 5
Joined: Mon Nov 06, 2006 10:18 am

Postby Ben on Mon Nov 06, 2006 11:56 am

Hi,

Can you try setting BestSize(x,y) and let me know if that solves the problem?

Thanks,
Ben
User avatar
Ben
Kirix Support Team
 
Posts: 522
Joined: Mon Dec 19, 2005 6:29 am

Postby Ben on Mon Nov 06, 2006 12:10 pm

funkyboy wrote:I have found that it's very esay to reproduce the dock outside the window problem.


Ok. I'll try this out.

Thanks,
Ben
User avatar
Ben
Kirix Support Team
 
Posts: 522
Joined: Mon Dec 19, 2005 6:29 am

Postby funkyboy on Tue Nov 07, 2006 6:18 am

BestSize doesn't solve the problem.

The pane that I'm undocking is a panel with a sizer that contains some controls.

I have follow the code and the problem is in this piece of code in the ::SetPaneWindow function:

if (pane.min_size.IsFullySpecified())
{
// because SetSizeHints() calls Fit() too (which sets the window
// size to its minimum allowed), we keep the size before calling
// SetSizeHints() and reset it afterwards...
wxSize tmp = GetSize();
GetSizer()->SetSizeHints(this);
SetSize(tmp);
}

When the function SetSizeHints is called it returns a very large height. It seems that the window or the window's sizer is not created correctly when the pane is not resizable.
funkyboy
Registered User
 
Posts: 5
Joined: Mon Nov 06, 2006 10:18 am

Postby Ben on Tue Nov 07, 2006 7:30 am

Which platform are you running this on? This info will help me debug it more effectively.

Thanks,
Ben
User avatar
Ben
Kirix Support Team
 
Posts: 522
Joined: Mon Dec 19, 2005 6:29 am

Postby funkyboy on Tue Nov 07, 2006 6:10 pm

I'm sorry.... I'm using windows (wxmsw).
funkyboy
Registered User
 
Posts: 5
Joined: Mon Nov 06, 2006 10:18 am

Postby funkyboy on Fri Nov 10, 2006 3:28 am

I've just downloaded 2.7.2 version and the problems are still there.
funkyboy
Registered User
 
Posts: 5
Joined: Mon Nov 06, 2006 10:18 am

Postby Ben on Fri Nov 10, 2006 8:25 am

Hi,

Can you post the Create() call you made when creating the window? Right now I still need a bit more information so I can put a test case together.

Thanks for any help,
Ben
User avatar
Ben
Kirix Support Team
 
Posts: 522
Joined: Mon Dec 19, 2005 6:29 am

Return to wxAUI Questions, Thoughts & Feedback