// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
-// ============================================================================
-// declarations
-// ============================================================================
-
-// ---------------------------------------------------------------------------
-// headers
-// ---------------------------------------------------------------------------
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#pragma hdrstop
#endif
+#if wxUSE_GRAPHICS_CONTEXT
+
#include "wx/graphics.h"
#ifndef WX_PRECOMP
#include "wx/icon.h"
#include "wx/bitmap.h"
#include "wx/dcmemory.h"
+ #include "wx/region.h"
#endif
-#if wxUSE_GRAPHICS_CONTEXT
-
#if !defined(wxMAC_USE_CORE_GRAPHICS_BLEND_MODES)
#define wxMAC_USE_CORE_GRAPHICS_BLEND_MODES 0
#endif
// constants
//-----------------------------------------------------------------------------
-const double RAD2DEG = 180.0 / M_PI;
-const short kEmulatedMode = -1;
-const short kUnsupportedMode = -2;
+static const double RAD2DEG = 180.0 / M_PI;
//-----------------------------------------------------------------------------
// Local functions
//-----------------------------------------------------------------------------
-static inline double dmin(double a, double b)
-{
- return a < b ? a : b;
-}
-static inline double dmax(double a, double b)
-{
- return a > b ? a : b;
-}
-
static inline double DegToRad(double deg)
{
return (deg * M_PI) / 180.0;
}
-static inline double RadToDeg(double deg)
-{
- return (deg * 180.0) / M_PI;
-}
+//-----------------------------------------------------------------------------
wxPoint2DDouble wxGraphicsPath::GetCurrentPoint()
{
}
-extern bool wxDoFloodFill(wxDC *dc, wxCoord x, wxCoord y,
- const wxColour & col, int style);
-
bool wxGCDC::DoFloodFill(wxCoord WXUNUSED(x), wxCoord WXUNUSED(y),
const wxColour& WXUNUSED(col), int WXUNUSED(style))
{
m_graphicContext->StrokePath( path );
delete path;
}
-#endif
+#endif // wxUSE_SPLINES
void wxGCDC::DoDrawPolygon( int n, wxPoint points[],
wxCoord xoffset, wxCoord yoffset,
{
wxCHECK_RET( Ok(), wxT("wxGCDC(cg)::DoGetTextExtent - invalid DC") );
- wxFont formerFont = m_font;
if ( theFont )
{
m_graphicContext->SetFont( *theFont );
wxDCBase::DoDrawCheckMark(x,y,width,height);
}
-#endif
-
+#endif // wxUSE_GRAPHICS_CONTEXT