Looks like the frame does not get created when we go into wxAuiFloatingFrame::SetPaneWindow() thus we get garbage from GetSize(). But when we call SetSize(), this garbage gets remembered in the pane from wxAuiManager::OnFloatingPaneResized().