]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/gdicmn.cpp
return the index of the inserted/appended item
[wxWidgets.git] / src / common / gdicmn.cpp
index 20450b557e11dd12a355e1dad5b8fd324d1716d9..69ddd2098684ffe8a2bf32ec3000ca666c6aefc5 100644 (file)
@@ -9,7 +9,7 @@
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
-#ifdef __GNUG__
+#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
 #pragma implementation "gdicmn.h"
 #endif
 
 #pragma implementation "gdicmn.h"
 #endif
 
 #include "wx/mac/private.h"
 #include "wx/mac/uma.h"
 #endif
 #include "wx/mac/private.h"
 #include "wx/mac/uma.h"
 #endif
-//IMPLEMENT_CLASS(wxColourDatabase, wxList)
-//IMPLEMENT_DYNAMIC_CLASS(wxFontList, wxList)
-//IMPLEMENT_DYNAMIC_CLASS(wxPenList, wxList)
-//IMPLEMENT_DYNAMIC_CLASS(wxBrushList, wxList)
-//IMPLEMENT_DYNAMIC_CLASS(wxBitmapList, wxList)
-//IMPLEMENT_DYNAMIC_CLASS(wxResourceCache, wxList)
+
+#if wxUSE_EXTENDED_RTTI
+
+// wxPoint
+
+template<> void wxStringReadValue(const wxString &s , wxPoint &data )
+{
+       wxSscanf(s, wxT("%d,%d"), &data.x , &data.y ) ;
+}
+
+template<> void wxStringWriteValue(wxString &s , const wxPoint &data )
+{
+       s = wxString::Format(wxT("%d,%d"), data.x , data.y ) ;
+}
+
+WX_CUSTOM_TYPE_INFO(wxPoint, wxToStringConverter<wxPoint> , wxFromStringConverter<wxPoint>)
+
+template<> void wxStringReadValue(const wxString &s , wxSize &data )
+{
+       wxSscanf(s, wxT("%d,%d"), &data.x , &data.y ) ;
+}
+
+template<> void wxStringWriteValue(wxString &s , const wxSize &data )
+{
+       s = wxString::Format(wxT("%d,%d"), data.x , data.y ) ;
+}
+
+WX_CUSTOM_TYPE_INFO(wxSize, wxToStringConverter<wxSize> , wxFromStringConverter<wxSize>)
+
+#endif
 
 IMPLEMENT_ABSTRACT_CLASS(wxDCBase, wxObject)
 
 
 IMPLEMENT_ABSTRACT_CLASS(wxDCBase, wxObject)