From d1af991f497a5e95d8f8ab15a4e4a4a4c375928f Mon Sep 17 00:00:00 2001 From: Robert Roebling Date: Sun, 11 Jul 1999 15:56:57 +0000 Subject: [PATCH] A few compile things. Changed resizing of multi-line text ctrl. Augmented beta version to 8. Distribution things. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2981 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- distrib/gtk/copy_src | 18 ++++++++++++- distrib/motif/copy_src | 16 ++++++++++++ distrib/wine/copy_src | 16 ++++++++++++ include/wx/busyinfo.h | 14 +++------- include/wx/html/Makefile.am | 4 +-- include/wx/log.h | 1 + include/wx/version.h | 2 +- include/wx/zipstream.h | 12 ++++++--- src/common/valtext.cpp | 4 --- src/common/wfstream.cpp | 8 ++---- src/common/zipstream.cpp | 51 ++++++++++++++++++++----------------- src/common/zstream.cpp | 14 ++++++---- src/generic/busyinfo.cpp | 40 +++++++++++------------------ src/gtk/bmpbuttn.cpp | 12 ++++----- src/gtk/notebook.cpp | 6 ++--- src/gtk/win_gtk.c | 5 +++- src/gtk1/bmpbuttn.cpp | 12 ++++----- src/gtk1/notebook.cpp | 6 ++--- src/gtk1/win_gtk.c | 5 +++- 19 files changed, 144 insertions(+), 102 deletions(-) diff --git a/distrib/gtk/copy_src b/distrib/gtk/copy_src index 67c68fa076..10d0e2562e 100755 --- a/distrib/gtk/copy_src +++ b/distrib/gtk/copy_src @@ -68,6 +68,13 @@ cp Makefile.am ~/wxgtk_dist/wxGTK/include/wx/generic cp Makefile.in ~/wxgtk_dist/wxGTK/include/wx/generic cd .. +mkdir ~/wxgtk_dist/wxGTK/include/wx/html +cd html +cp *.h ~/wxgtk_dist/wxGTK/include/wx/html +cp Makefile.am ~/wxgtk_dist/wxGTK/include/wx/html +cp Makefile.in ~/wxgtk_dist/wxGTK/include/wx/html +cd .. + mkdir ~/wxgtk_dist/wxGTK/include/wx/unix cd unix cp *.h ~/wxgtk_dist/wxGTK/include/wx/unix @@ -154,6 +161,15 @@ mkdir ~/wxgtk_dist/wxGTK/src/unix cp *.cpp ~/wxgtk_dist/wxGTK/src/unix cd .. +cd html +mkdir ~/wxgtk_dist/wxGTK/src/html +cp *.cpp ~/wxgtk_dist/wxGTK/src/html +cp *.h ~/wxgtk_dist/wxGTK/src/html +cd bitmaps +mkdir ~/wxgtk_dist/wxGTK/src/html/bitmaps +cp *.xpm ~/wxgtk_dist/wxGTK/src/html/bitmaps +cd ../.. + cd generic mkdir ~/wxgtk_dist/wxGTK/src/generic cp *.cpp ~/wxgtk_dist/wxGTK/src/generic @@ -776,4 +792,4 @@ cp README.txt ~/wxgtk_dist/wxGTK/utils/wxPython cp Setup ~/wxgtk_dist/wxGTK/utils/wxPython/src cd ~/wxgtk_dist -tar ch wxGTK | gzip -f9 > wxGTK-2.1.0-b7.tgz +tar ch wxGTK | gzip -f9 > wxGTK-2.1.0-b7b.tgz diff --git a/distrib/motif/copy_src b/distrib/motif/copy_src index 14714a56e9..5c4a488322 100755 --- a/distrib/motif/copy_src +++ b/distrib/motif/copy_src @@ -68,6 +68,13 @@ cp Makefile.am ~/wxmotif_dist/wxMotif/include/wx/generic cp Makefile.in ~/wxmotif_dist/wxMotif/include/wx/generic cd .. +mkdir ~/wxgtk_dist/wxGTK/include/wx/html +cd html +cp *.h ~/wxgtk_dist/wxGTK/include/wx/html +cp Makefile.am ~/wxgtk_dist/wxGTK/include/wx/html +cp Makefile.in ~/wxgtk_dist/wxGTK/include/wx/html +cd .. + mkdir ~/wxmotif_dist/wxMotif/include/wx/unix cd unix cp *.h ~/wxmotif_dist/wxMotif/include/wx/unix @@ -149,6 +156,15 @@ cp extended.c ~/wxmotif_dist/wxMotif/src/common cp *.cpp ~/wxmotif_dist/wxMotif/src/common cd .. +cd html +mkdir ~/wxgtk_dist/wxGTK/src/html +cp *.cpp ~/wxgtk_dist/wxGTK/src/html +cp *.h ~/wxgtk_dist/wxGTK/src/html +cd bitmaps +mkdir ~/wxgtk_dist/wxGTK/src/html/bitmaps +cp *.xpm ~/wxgtk_dist/wxGTK/src/html/bitmaps +cd ../.. + cd unix mkdir ~/wxmotif_dist/wxMotif/src/unix cp *.cpp ~/wxmotif_dist/wxMotif/src/unix diff --git a/distrib/wine/copy_src b/distrib/wine/copy_src index 3b599fce1e..6811a30617 100755 --- a/distrib/wine/copy_src +++ b/distrib/wine/copy_src @@ -68,6 +68,13 @@ cp Makefile.am ~/wxwine_dist/wxWINE/include/wx/generic cp Makefile.in ~/wxwine_dist/wxWINE/include/wx/generic cd .. +mkdir ~/wxgtk_dist/wxGTK/include/wx/html +cd html +cp *.h ~/wxgtk_dist/wxGTK/include/wx/html +cp Makefile.am ~/wxgtk_dist/wxGTK/include/wx/html +cp Makefile.in ~/wxgtk_dist/wxGTK/include/wx/html +cd .. + mkdir ~/wxwine_dist/wxWINE/include/wx/unix cd unix cp *.h ~/wxwine_dist/wxWINE/include/wx/unix @@ -149,6 +156,15 @@ cp extended.c ~/wxwine_dist/wxWINE/src/common cp *.cpp ~/wxwine_dist/wxWINE/src/common cd .. +cd html +mkdir ~/wxgtk_dist/wxGTK/src/html +cp *.cpp ~/wxgtk_dist/wxGTK/src/html +cp *.h ~/wxgtk_dist/wxGTK/src/html +cd bitmaps +mkdir ~/wxgtk_dist/wxGTK/src/html/bitmaps +cp *.xpm ~/wxgtk_dist/wxGTK/src/html/bitmaps +cd ../.. + cd unix mkdir ~/wxwine_dist/wxWINE/src/unix cp *.cpp ~/wxwine_dist/wxWINE/src/unix diff --git a/include/wx/busyinfo.h b/include/wx/busyinfo.h index 33e1882224..be907a80cd 100644 --- a/include/wx/busyinfo.h +++ b/include/wx/busyinfo.h @@ -3,6 +3,7 @@ // Purpose: Information window (when app is busy) // Author: Vaclav Slavik // Copyright: (c) 1999 Vaclav Slavik +// RCS-ID: $Id$ // Licence: wxWindows Licence ///////////////////////////////////////////////////////////////////////////// @@ -10,26 +11,19 @@ #define __INFOWIN_H__ #ifdef __GNUG__ -#pragma implementation +#pragma interface #endif -#include +#include "wx/wxprec.h" #ifdef __BORDLANDC__ #pragma hdrstop #endif -#ifndef WXPRECOMP -#include -#endif +#include "wx/frame.h" #if wxUSE_BUSYINFO -#include - - - - class wxInfoFrame : public wxFrame { public: diff --git a/include/wx/html/Makefile.am b/include/wx/html/Makefile.am index ed4023095d..3611382eb8 100644 --- a/include/wx/html/Makefile.am +++ b/include/wx/html/Makefile.am @@ -14,6 +14,4 @@ htmlparser.h \ htmltag.h \ htmlwin.h \ htmlwinparser.h \ -mod_templ.h \ -msw \ -version.h +mod_templ.h diff --git a/include/wx/log.h b/include/wx/log.h index 72f8d774fb..24292ae8d4 100644 --- a/include/wx/log.h +++ b/include/wx/log.h @@ -17,6 +17,7 @@ #endif #include "wx/setup.h" +#include "wx/string.h" // ---------------------------------------------------------------------------- // forward declarations diff --git a/include/wx/version.h b/include/wx/version.h index 27dc3a133d..6d3d427b2a 100644 --- a/include/wx/version.h +++ b/include/wx/version.h @@ -18,7 +18,7 @@ #define wxRELEASE_NUMBER 0 #define wxVERSION_STRING "wxWindows 2.1.0" #define wxVERSION_NUMBER (wxMAJOR_VERSION * 1000) + (wxMINOR_VERSION * 100) + wxRELEASE_NUMBER -#define wxBETA_NUMBER 7 +#define wxBETA_NUMBER 8 #define wxVERSION_FLOAT wxMAJOR_VERSION + (wxMINOR_VERSION/10.0) + (wxRELEASE_NUMBER/100.0) + (wxBETA_NUMBER/10000.0) #endif diff --git a/include/wx/zipstream.h b/include/wx/zipstream.h index 3e0d1ed06c..77074fa97b 100644 --- a/include/wx/zipstream.h +++ b/include/wx/zipstream.h @@ -13,9 +13,11 @@ #pragma interface #endif -#if wxUSE_ZLIB && wxUSE_STREAMS && wxUSE_ZIPSTREAM +#include "wx/defs.h" -#include +#if wxUSE_STREAMS && wxUSE_ZIPSTREAM && wxUSE_ZLIB + +#include "wx/stream.h" //-------------------------------------------------------------------------------- // wxZipInputStream @@ -48,9 +50,11 @@ class WXDLLEXPORT wxZipInputStream : public wxInputStream }; -#endif // +#endif + // wxUSE_STREAMS && wxUSE_ZIPSTREAM && wxUSE_ZLIB -#endif // __ZIPSTREAM_H__ +#endif + // __ZIPSTREAM_H__ diff --git a/src/common/valtext.cpp b/src/common/valtext.cpp index a3b027ea0a..f891889826 100644 --- a/src/common/valtext.cpp +++ b/src/common/valtext.cpp @@ -20,10 +20,6 @@ #pragma hdrstop #endif -#ifndef WX_PRECOMP - #include "wx/defs.h" -#endif - #if wxUSE_VALIDATORS #ifndef WX_PRECOMP diff --git a/src/common/wfstream.cpp b/src/common/wfstream.cpp index 4bae72adc7..599c2f2fad 100644 --- a/src/common/wfstream.cpp +++ b/src/common/wfstream.cpp @@ -20,15 +20,11 @@ #pragma hdrstop #endif -#ifndef WX_PRECOMP - #include "wx/defs.h" -#endif - #if wxUSE_STREAMS && wxUSE_FILE #include -#include -#include +#include "wx/stream.h" +#include "wx/wfstream.h" // ---------------------------------------------------------------------------- // wxFileInputStream diff --git a/src/common/zipstream.cpp b/src/common/zipstream.cpp index 7530f939f3..f117a8c9de 100644 --- a/src/common/zipstream.cpp +++ b/src/common/zipstream.cpp @@ -7,29 +7,25 @@ ///////////////////////////////////////////////////////////////////////////// #ifdef __GNUG__ -#pragma implementation +#pragma implementation "zipstream.h" #endif -#include +// For compilers that support precompilation, includes "wx.h". +#include "wx/wxprec.h" -#ifdef __BORDLANDC__ -#pragma hdrstop +#ifdef __BORLANDC__ + #pragma hdrstop #endif -#ifndef WXPRECOMP -#include -#endif - -#if wxUSE_ZLIB && wxUSE_STREAMS && wxUSE_ZIPSTREAM +#if wxUSE_STREAMS && wxUSE_ZIPSTREAM && wxUSE_ZLIB -#include -#include -#include +#include "wx/log.h" +#include "wx/intl.h" +#include "wx/stream.h" +#include "wx/wfstream.h" +#include "wx/zipstream.h" #include "unzip.h" - - - wxZipInputStream::wxZipInputStream(const wxString& archive, const wxString& file) : wxInputStream() { unz_file_info zinfo; @@ -37,17 +33,21 @@ wxZipInputStream::wxZipInputStream(const wxString& archive, const wxString& file m_Pos = 0; m_Size = 0; m_Archive = (void*) unzOpen(archive); - if (m_Archive == NULL) { + if (m_Archive == NULL) + { m_lasterror = wxStream_READ_ERR; return; } - if (unzLocateFile((unzFile)m_Archive, file, 0) != UNZ_OK) { + if (unzLocateFile((unzFile)m_Archive, file, 0) != UNZ_OK) + { m_lasterror = wxStream_READ_ERR; return; } - unzGetCurrentFileInfo((unzFile)m_Archive, &zinfo, NULL, 0, NULL, 0, NULL, 0); + + unzGetCurrentFileInfo((unzFile)m_Archive, &zinfo, (char*) NULL, 0, (void*) NULL, 0, (char*) NULL, 0); - if (unzOpenCurrentFile((unzFile)m_Archive) != UNZ_OK) { + if (unzOpenCurrentFile((unzFile)m_Archive) != UNZ_OK) + { m_lasterror = wxStream_READ_ERR; return; } @@ -58,7 +58,8 @@ wxZipInputStream::wxZipInputStream(const wxString& archive, const wxString& file wxZipInputStream::~wxZipInputStream() { - if (m_Archive) { + if (m_Archive) + { if (m_Size != 0) unzCloseCurrentFile((unzFile)m_Archive); unzClose((unzFile)m_Archive); @@ -82,7 +83,8 @@ off_t wxZipInputStream::OnSysSeek(off_t seek, wxSeekMode mode) off_t nextpos; void *buf; - switch (mode) { + switch (mode) + { case wxFromCurrent : nextpos = seek + m_Pos; break; case wxFromStart : nextpos = seek; break; case wxFromEnd : nextpos = m_Size - 1 + seek; break; @@ -90,14 +92,16 @@ off_t wxZipInputStream::OnSysSeek(off_t seek, wxSeekMode mode) } // cheated seeking : - if (nextpos > m_Pos) { + if (nextpos > m_Pos) + { buf = malloc(nextpos - m_Pos); unzReadCurrentFile((unzFile)m_Archive, buf, nextpos - m_Pos); free(buf); } else if (nextpos < m_Pos) { unzCloseCurrentFile((unzFile)m_Archive); - if (unzOpenCurrentFile((unzFile)m_Archive) != UNZ_OK) { + if (unzOpenCurrentFile((unzFile)m_Archive) != UNZ_OK) + { m_lasterror = wxStream_READ_ERR; return m_Pos; } @@ -111,3 +115,4 @@ off_t wxZipInputStream::OnSysSeek(off_t seek, wxSeekMode mode) } #endif + // wxUSE_STREAMS && wxUSE_ZIPSTREAM && wxUSE_ZLIB diff --git a/src/common/zstream.cpp b/src/common/zstream.cpp index c917e493a4..1ae27ad74c 100644 --- a/src/common/zstream.cpp +++ b/src/common/zstream.cpp @@ -20,17 +20,21 @@ #pragma hdrstop #endif -#ifndef WX_PRECOMP - #include "wx/defs.h" -#endif - #if wxUSE_ZLIB && wxUSE_STREAMS #include "wx/zstream.h" #include "wx/utils.h" #include "wx/intl.h" #include "wx/log.h" -#include "../zlib/zlib.h" + +// When using configure, the path must be "zlib.h" I don't know +// what other ports (wxMac, wxMotif without configure) need here. + +#ifdef __WXMSW__ + #include "..\zlib\zlib.h" +#else + #include "zlib.h" +#endif #define ZSTREAM_BUFFER_SIZE 1024 diff --git a/src/generic/busyinfo.cpp b/src/generic/busyinfo.cpp index 0b5893dd9f..d446750d64 100644 --- a/src/generic/busyinfo.cpp +++ b/src/generic/busyinfo.cpp @@ -7,58 +7,48 @@ ///////////////////////////////////////////////////////////////////////////// #ifdef __GNUG__ -#pragma implementation +#pragma implementation "busyinfo.h" #endif -#include +#include "wx/wxprec.h" #ifdef __BORDLANDC__ #pragma hdrstop #endif -#ifndef WXPRECOMP -#include -#endif - #if wxUSE_BUSYINFO #include "wx/busyinfo.h" - - - +#include "wx/stattext.h" +#include "wx/panel.h" +#include "wx/utils.h" wxInfoFrame::wxInfoFrame(wxWindow *parent, const wxString& message) : wxFrame(parent, -1, "", wxPoint(0, 0), wxSize(400, 80), wxTHICK_FRAME | wxSIMPLE_BORDER | wxFRAME_TOOL_WINDOW) { - wxPanel *p = new wxPanel(this); - wxStaticText *s = new wxStaticText(p, -1, message, wxPoint(20, 20), wxSize(360, 40), wxALIGN_CENTER); + wxPanel *p = new wxPanel( this ); + wxStaticText *s = new wxStaticText( p, -1, message, wxPoint(20, 20), wxSize(360, 40), wxALIGN_CENTER ); Centre(wxBOTH); - p -> SetCursor(*wxHOURGLASS_CURSOR); - s -> SetCursor(*wxHOURGLASS_CURSOR); + p->SetCursor(*wxHOURGLASS_CURSOR); + s->SetCursor(*wxHOURGLASS_CURSOR); } - - - wxBusyInfo::wxBusyInfo(const wxString& message) : wxObject() { - m_InfoFrame = new wxInfoFrame(NULL, message); - m_InfoFrame -> Show(TRUE); + m_InfoFrame = new wxInfoFrame( (wxWindow*) NULL, message); + m_InfoFrame->Show(TRUE); wxYield(); - m_InfoFrame -> Refresh(); + m_InfoFrame->Refresh(); wxYield(); } - - wxBusyInfo::~wxBusyInfo() { - m_InfoFrame -> Show(FALSE); - m_InfoFrame -> Close(); + m_InfoFrame->Show(FALSE); + m_InfoFrame->Close(); wxYield(); } - - #endif + // wxUSE_BUSYINFO \ No newline at end of file diff --git a/src/gtk/bmpbuttn.cpp b/src/gtk/bmpbuttn.cpp index 6661b99efd..7bfc477e35 100644 --- a/src/gtk/bmpbuttn.cpp +++ b/src/gtk/bmpbuttn.cpp @@ -148,14 +148,14 @@ bool wxBitmapButton::Create( wxWindow *parent, wxWindowID id, const wxBitmap &bi gtk_widget_show( pixmap ); gtk_container_add( GTK_CONTAINER(m_widget), pixmap ); + + int border = 10; + if (style & wxNO_BORDER) border = 4; + if (newSize.x == -1) newSize.x = m_bitmap.GetWidth()+border; + if (newSize.y == -1) newSize.y = m_bitmap.GetHeight()+border; + SetSize( newSize.x, newSize.y ); } - int border = 10; - if (style & wxNO_BORDER) border = 4; - if (newSize.x == -1) newSize.x = m_bitmap.GetWidth()+border; - if (newSize.y == -1) newSize.y = m_bitmap.GetHeight()+border; - SetSize( newSize.x, newSize.y ); - gtk_signal_connect( GTK_OBJECT(m_widget), "clicked", GTK_SIGNAL_FUNC(gtk_bmpbutton_clicked_callback), (gpointer*)this ); diff --git a/src/gtk/notebook.cpp b/src/gtk/notebook.cpp index 2ea952be80..6102168a49 100644 --- a/src/gtk/notebook.cpp +++ b/src/gtk/notebook.cpp @@ -515,6 +515,9 @@ bool wxNotebook::InsertPage( int position, wxWindow* win, const wxString& text, page->m_box = gtk_hbox_new( FALSE, 0 ); gtk_container_border_width( GTK_CONTAINER(page->m_box), 2 ); + gtk_signal_connect( GTK_OBJECT(win->m_widget), "size_allocate", + GTK_SIGNAL_FUNC(gtk_page_size_callback), (gpointer)win ); + if (position < 0) gtk_notebook_append_page( notebook, win->m_widget, page->m_box ); else @@ -522,9 +525,6 @@ bool wxNotebook::InsertPage( int position, wxWindow* win, const wxString& text, page->m_page = (GtkNotebookPage*) g_list_last(notebook->children)->data; - gtk_signal_connect( GTK_OBJECT(win->m_widget), "size_allocate", - GTK_SIGNAL_FUNC(gtk_page_size_callback), (gpointer)win ); - /* set the label image */ page->m_image = imageId; diff --git a/src/gtk/win_gtk.c b/src/gtk/win_gtk.c index 1c885094af..dcd694df3f 100644 --- a/src/gtk/win_gtk.c +++ b/src/gtk/win_gtk.c @@ -10,6 +10,7 @@ #include "wx/gtk/win_gtk.h" #include "gtk/gtksignal.h" #include "gtk/gtknotebook.h" +#include "gtk/gtktable.h" #ifdef __cplusplus extern "C" { @@ -327,7 +328,9 @@ gtk_myfixed_set_size (GtkMyFixed *myfixed, if (GTK_WIDGET_VISIBLE (widget) && GTK_WIDGET_VISIBLE (myfixed)) { - if ((child->width > 1) && (child->height > 1) && (GTK_WIDGET_REALIZED(widget))) + if ( ((child->width > 1) && (child->height > 1) && (GTK_WIDGET_REALIZED(widget))) || + /* I don't know why GtkTable is different */ + GTK_IS_TABLE(widget)) { child_allocation.x = child->x; child_allocation.y = child->y; diff --git a/src/gtk1/bmpbuttn.cpp b/src/gtk1/bmpbuttn.cpp index 6661b99efd..7bfc477e35 100644 --- a/src/gtk1/bmpbuttn.cpp +++ b/src/gtk1/bmpbuttn.cpp @@ -148,14 +148,14 @@ bool wxBitmapButton::Create( wxWindow *parent, wxWindowID id, const wxBitmap &bi gtk_widget_show( pixmap ); gtk_container_add( GTK_CONTAINER(m_widget), pixmap ); + + int border = 10; + if (style & wxNO_BORDER) border = 4; + if (newSize.x == -1) newSize.x = m_bitmap.GetWidth()+border; + if (newSize.y == -1) newSize.y = m_bitmap.GetHeight()+border; + SetSize( newSize.x, newSize.y ); } - int border = 10; - if (style & wxNO_BORDER) border = 4; - if (newSize.x == -1) newSize.x = m_bitmap.GetWidth()+border; - if (newSize.y == -1) newSize.y = m_bitmap.GetHeight()+border; - SetSize( newSize.x, newSize.y ); - gtk_signal_connect( GTK_OBJECT(m_widget), "clicked", GTK_SIGNAL_FUNC(gtk_bmpbutton_clicked_callback), (gpointer*)this ); diff --git a/src/gtk1/notebook.cpp b/src/gtk1/notebook.cpp index 2ea952be80..6102168a49 100644 --- a/src/gtk1/notebook.cpp +++ b/src/gtk1/notebook.cpp @@ -515,6 +515,9 @@ bool wxNotebook::InsertPage( int position, wxWindow* win, const wxString& text, page->m_box = gtk_hbox_new( FALSE, 0 ); gtk_container_border_width( GTK_CONTAINER(page->m_box), 2 ); + gtk_signal_connect( GTK_OBJECT(win->m_widget), "size_allocate", + GTK_SIGNAL_FUNC(gtk_page_size_callback), (gpointer)win ); + if (position < 0) gtk_notebook_append_page( notebook, win->m_widget, page->m_box ); else @@ -522,9 +525,6 @@ bool wxNotebook::InsertPage( int position, wxWindow* win, const wxString& text, page->m_page = (GtkNotebookPage*) g_list_last(notebook->children)->data; - gtk_signal_connect( GTK_OBJECT(win->m_widget), "size_allocate", - GTK_SIGNAL_FUNC(gtk_page_size_callback), (gpointer)win ); - /* set the label image */ page->m_image = imageId; diff --git a/src/gtk1/win_gtk.c b/src/gtk1/win_gtk.c index 1c885094af..dcd694df3f 100644 --- a/src/gtk1/win_gtk.c +++ b/src/gtk1/win_gtk.c @@ -10,6 +10,7 @@ #include "wx/gtk/win_gtk.h" #include "gtk/gtksignal.h" #include "gtk/gtknotebook.h" +#include "gtk/gtktable.h" #ifdef __cplusplus extern "C" { @@ -327,7 +328,9 @@ gtk_myfixed_set_size (GtkMyFixed *myfixed, if (GTK_WIDGET_VISIBLE (widget) && GTK_WIDGET_VISIBLE (myfixed)) { - if ((child->width > 1) && (child->height > 1) && (GTK_WIDGET_REALIZED(widget))) + if ( ((child->width > 1) && (child->height > 1) && (GTK_WIDGET_REALIZED(widget))) || + /* I don't know why GtkTable is different */ + GTK_IS_TABLE(widget)) { child_allocation.x = child->x; child_allocation.y = child->y; -- 2.47.2