Getting (maximal) size of wxToolbook
Volker Bartheld
dr_versaeg at freenet.de
Wed Sep 26 01:22:58 PDT 2007
> By comparing my code with the notebook sample, I came up with a slightly different
> solution [1] that changed close to nothing, because it still didn't return a
> usable height. In the sample, I added
>
> wxSize
> s0=currBook->GetSize(),
> s1=currBook->GetMinSize(),
> s2=currBook->GetMaxSize();
>
> MyFrame::OnAddPageNoSelect() but wasn't able to make it tell me the size or
> auto-resize to fit the toolbook [2]
Forgot:
[2]
void MyFrame::OnAddPageNoSelect(wxCommandEvent& WXUNUSED(event))
{
wxBookCtrlBase *currBook = GetCurrentBook();
if ( currBook )
{
// [...original code...]
wxSize
s0=currBook->GetSize(),
s1=currBook->GetMinSize(),
s2=currBook->GetMaxSize();
m_sizerFrame->Show(currBook);
m_sizerFrame->Layout();
Layout();
Fit();
}
}
--
mailto: V B A R T H E L D at G M X dot D E
More information about the wx-users
mailing list