resize mdi and notebook client

bitmap resizing (used in imagelist)
draw spline bug


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@262 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
1998-07-13 23:30:59 +00:00
parent d29d303b1c
commit 33d0b396b2
18 changed files with 193 additions and 36 deletions

View File

@@ -18,6 +18,21 @@
// wxMDIParentFrame
//-----------------------------------------------------------------------------
static void gtk_page_size_callback( GtkWidget *WXUNUSED(widget), GtkAllocation* alloc, wxWindow *win )
{
if ((win->m_x == alloc->x) &&
(win->m_y == alloc->y) &&
(win->m_width == alloc->width) &&
(win->m_height == alloc->height))
{
return;
};
win->SetSize( alloc->x, alloc->y, alloc->width, alloc->height );
};
//-----------------------------------------------------------------------------
IMPLEMENT_DYNAMIC_CLASS(wxMDIParentFrame,wxFrame)
wxMDIParentFrame::wxMDIParentFrame(void)
@@ -113,10 +128,10 @@ wxMDIChildFrame::wxMDIChildFrame(void)
wxMDIChildFrame::wxMDIChildFrame( wxMDIParentFrame *parent,
wxWindowID id, const wxString& title,
const wxPoint& pos, const wxSize& size,
const wxPoint& WXUNUSED(pos), const wxSize& size,
long style, const wxString& name )
{
Create( parent, id, title, pos, size, style, name );
Create( parent, id, title, wxDefaultPosition, size, style, name );
};
wxMDIChildFrame::~wxMDIChildFrame(void)
@@ -125,11 +140,11 @@ wxMDIChildFrame::~wxMDIChildFrame(void)
bool wxMDIChildFrame::Create( wxMDIParentFrame *parent,
wxWindowID id, const wxString& title,
const wxPoint& pos, const wxSize& size,
const wxPoint& WXUNUSED(pos), const wxSize& size,
long style, const wxString& name )
{
m_title = title;
return wxPanel::Create( parent->GetClientWindow(), id, pos, size, style, name );
return wxPanel::Create( parent->GetClientWindow(), id, wxDefaultPosition, size, style, name );
};
void wxMDIChildFrame::SetMenuBar( wxMenuBar *WXUNUSED(menu_bar) )
@@ -191,6 +206,9 @@ void wxMDIClientWindow::AddChild( wxWindow *child )
GtkWidget *label_widget;
label_widget = gtk_label_new( s );
gtk_misc_set_alignment( GTK_MISC(label_widget), 0.0, 0.5 );
gtk_signal_connect( GTK_OBJECT(child->m_widget), "size_allocate",
GTK_SIGNAL_FUNC(gtk_page_size_callback), (gpointer)child );
gtk_notebook_append_page( GTK_NOTEBOOK(m_widget), child->m_widget, label_widget );
};