template<> void wxStringReadValue(const wxString &s , wxPoint &data )
{
- wxSscanf(s, _T("%d,%d"), &data.x , &data.y ) ;
+ wxSscanf(s, wxT("%d,%d"), &data.x , &data.y ) ;
}
template<> void wxStringWriteValue(wxString &s , const wxPoint &data )
{
- s = wxString::Format("%d,%d", data.x , data.y ) ;
+ s = wxString::Format(wxT("%d,%d"), data.x , data.y ) ;
}
-template<> void wxStringReadValue(const wxString & , wxPoint* & )
-{
- assert(0) ;
-}
-
-template<> void wxStringWriteValue(wxString & , wxPoint* const & )
-{
- assert(0) ;
-}
-
-WX_CUSTOM_TYPE_INFO(wxPoint, wxToStringConverter<wxPoint> , wxFromStringConverter<wxPoint>)
+wxCUSTOM_TYPE_INFO(wxPoint, wxToStringConverter<wxPoint> , wxFromStringConverter<wxPoint>)
template<> void wxStringReadValue(const wxString &s , wxSize &data )
{
- wxSscanf(s, _T("%d,%d"), &data.x , &data.y ) ;
+ wxSscanf(s, wxT("%d,%d"), &data.x , &data.y ) ;
}
template<> void wxStringWriteValue(wxString &s , const wxSize &data )
{
- s = wxString::Format("%d,%d", data.x , data.y ) ;
-}
-
-template<> void wxStringReadValue(const wxString & , wxSize* & )
-{
- assert(0) ;
-}
-
-template<> void wxStringWriteValue(wxString & , wxSize * const & )
-{
- assert(0) ;
+ s = wxString::Format(wxT("%d,%d"), data.x , data.y ) ;
}
-WX_CUSTOM_TYPE_INFO(wxSize, wxToStringConverter<wxSize> , wxFromStringConverter<wxSize>)
+wxCUSTOM_TYPE_INFO(wxSize, wxToStringConverter<wxSize> , wxFromStringConverter<wxSize>)
#endif
IMPLEMENT_ABSTRACT_CLASS(wxDCBase, wxObject)
-wxRect::wxRect(const wxPoint& topLeft, const wxPoint& bottomRight)
+wxRect::wxRect(const wxPoint& point1, const wxPoint& point2)
{
- x = topLeft.x;
- y = topLeft.y;
- width = bottomRight.x - topLeft.x + 1;
- height = bottomRight.y - topLeft.y + 1;
+ x = point1.x;
+ y = point1.y;
+ width = point2.x - point1.x;
+ height = point2.y - point1.y;
if (width < 0)
{
width = -width;
- x -= width;
+ x = point2.x;
}
+ width++;
if (height < 0)
{
height = -height;
- y -= height;
+ y = point2.y;
}
+ height++;
}
wxRect::wxRect(const wxPoint& point, const wxSize& size)
GetThemeFont(kThemeSystemFont , GetApplicationScript() , fontName , &fontSize , &fontStyle ) ;
sizeFont = fontSize ;
- wxSWISS_FONT = new wxFont (fontSize, wxSWISS, wxNORMAL, wxNORMAL , false , wxMacMakeStringFromPascal(fontName) );
+ wxNORMAL_FONT = new wxFont (fontSize, wxMODERN, wxNORMAL, wxNORMAL , false , wxMacMakeStringFromPascal(fontName) );
#elif defined(__WXPM__)
static const int sizeFont = 12;
#else
wxITALIC_FONT = new wxFont (sizeFont, wxROMAN, wxITALIC, wxNORMAL);
wxSWISS_FONT = new wxFont (sizeFont, wxSWISS, wxNORMAL, wxNORMAL); /* Helv */
#elif defined(__WXMAC__)
- wxNORMAL_FONT = new wxFont (sizeFont, wxMODERN, wxNORMAL, wxNORMAL);
+ wxSWISS_FONT = new wxFont (sizeFont, wxSWISS, wxNORMAL, wxNORMAL); /* Helv */
wxITALIC_FONT = new wxFont (sizeFont, wxROMAN, wxITALIC, wxNORMAL);
GetThemeFont(kThemeSmallSystemFont , GetApplicationScript() , fontName , &fontSize , &fontStyle ) ;
wxSMALL_FONT = new wxFont (fontSize, wxSWISS, wxNORMAL, wxNORMAL , false , wxMacMakeStringFromPascal( fontName ) );