CloseButton(False) useless with Float Panel in wx.aui?

Hi All

I made a simple test, a floating pane in a frame. the pane is not dockable.

I set CloseButton(False), but the closebutton is still there(can not be clicked)

Why the CloseButton still can be seen?

my platform is WinXP+wxPython2.8, python2.6

the testing code:

···

import wx
import wx.aui

class myApp(wx.App):
def OnInit(self):
frame = wx.Frame(None,-1,“Test”,wx.DefaultPosition,size=(550,400))

self.auiMgr = wx.aui.AuiManager()
self.auiMgr.SetManagedWindow(frame)

self.pane = wx.Panel(frame,-1,size=(120,300))
self.auiMgr.AddPane(self.pane,wx.aui.AuiPaneInfo().Floatable(True).
Resizable(False).FloatingPosition((300,300)).
Float().Dockable(False).CloseButton(False))
self.auiMgr.Update()

    frame.Show()
    self.SetTopWindow(frame)
    return True

if name == “main”:
app = myApp()
app.MainLoop()


Thank you.

Hi,

2010/1/12 Kevin W:

Hi All
I made a simple test, a floating pane in a frame. the pane is not dockable.
I set CloseButton(False), but the closebutton is still there(can not be
clicked)

Why the CloseButton still can be seen?
my platform is WinXP+wxPython2.8, python2.6

This is by design: on Windows, even if wxAUI does not pass a
"wx.CLOSE_BOX" style to the floating frame, the close button can still
be seen but not clicked. This is a Windows quirk, not a wxPython one.

Andrea.

"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.alice.it/infinity77/

Then, no way to hide the “closebutton”?

···

On Tue, Jan 12, 2010 at 4:42 PM, Andrea Gavana andrea.gavana@gmail.com wrote:

Hi,

2010/1/12 Kevin W:

Hi All
I made a simple test, a floating pane in a frame. the pane is not dockable.
I set CloseButton(False), but the closebutton is still there(can not be
clicked)

Why the CloseButton still can be seen?
my platform is WinXP+wxPython2.8, python2.6

This is by design: on Windows, even if wxAUI does not pass a
“wx.CLOSE_BOX” style to the floating frame, the close button can still

be seen but not clicked. This is a Windows quirk, not a wxPython one.

Andrea.

“Imagination Is The Only Weapon In The War Against Reality.”
http://xoomer.alice.it/infinity77/

http://thedoomedcity.blogspot.com/


To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com

or visit http://groups.google.com/group/wxPython-users?hl=en