wxPanel *panel = new wxPanel( m_notebook, -1 );
(void)new wxButton( panel, -1, "Button", wxPoint( 10,10 ), wxSize(-1,-1) );
m_notebook->AddPage( panel, "Added" );
- m_notebook->SetSelection( m_notebook->GetPageCount()-1 );
+// m_notebook->SetSelection( m_notebook->GetPageCount()-1 );
}
void MyFrame::OnDeletePage(wxCommandEvent& WXUNUSED(event))
ke.SetEventObject( parent );
if (parent->GetEventHandler()->ProcessEvent( ke )) return;
+ if (event.KeyCode() == WXK_TAB)
+ {
+ wxNavigationKeyEvent nevent;
+ nevent.SetDirection( !event.ShiftDown() );
+ nevent.SetCurrentFocus( m_parent );
+ if (m_parent->GetEventHandler()->ProcessEvent( nevent )) return;
+ }
+
/* no item -> nothing to do */
if (!m_current)
{
gtk_text_set_editable( GTK_TEXT(m_text), 1 );
}
- SetBackgroundColour( parent->GetBackgroundColour() );
+ SetBackgroundColour( wxSystemSettings::GetSystemColour(wxSYS_COLOUR_WINDOW) );
SetForegroundColour( parent->GetForegroundColour() );
Show( TRUE );
if ((m_maxHeight != -1) && (m_height > m_maxHeight)) m_height = m_maxHeight;
int border = 0;
+ int bottom_border = 0;
if (GTK_WIDGET_CAN_DEFAULT(m_widget))
{
/* the default button has a border around it */
- border = 5;
+ border = 6;
+ bottom_border = 5;
}
/* this is the result of hours of debugging: the following code
m_x-border,
m_y-border,
m_width+2*border,
- m_height+2*border );
+ m_height+border+bottom_border );
}
m_sizeSet = TRUE;
gtk_text_set_editable( GTK_TEXT(m_text), 1 );
}
- SetBackgroundColour( parent->GetBackgroundColour() );
+ SetBackgroundColour( wxSystemSettings::GetSystemColour(wxSYS_COLOUR_WINDOW) );
SetForegroundColour( parent->GetForegroundColour() );
Show( TRUE );
if ((m_maxHeight != -1) && (m_height > m_maxHeight)) m_height = m_maxHeight;
int border = 0;
+ int bottom_border = 0;
if (GTK_WIDGET_CAN_DEFAULT(m_widget))
{
/* the default button has a border around it */
- border = 5;
+ border = 6;
+ bottom_border = 5;
}
/* this is the result of hours of debugging: the following code
m_x-border,
m_y-border,
m_width+2*border,
- m_height+2*border );
+ m_height+border+bottom_border );
}
m_sizeSet = TRUE;