#include "wx/log.h"
#include "wx/region.h"
#include "wx/image.h"
+ #include "wx/icon.h"
#endif
#include "wx/mac/uma.h"
#pragma mark -
#pragma mark wxMacCoreGraphicsPattern, ImagePattern, HatchPattern classes
+OSStatus wxMacDrawCGImage(
+ CGContextRef inContext,
+ const HIRect * inBounds,
+ CGImageRef inImage)
+{
+#ifdef __LP64__
+ // todo flip
+ CGContextDrawImage(inContext, *inBounds, inImage );
+#else
+ HIViewDrawCGImage( inContext, inBounds, inImage );
+#endif
+}
+
// CGPattern wrapper class: always allocate on heap, never call destructor
class wxMacCoreGraphicsPattern
virtual void Render( CGContextRef ctxRef )
{
if (m_image != NULL)
- HIViewDrawCGImage( ctxRef, &m_imageBounds, m_image );
+ wxMacDrawCGImage( ctxRef, &m_imageBounds, m_image );
}
protected :
// we need the scale here ...
Fixed atsuSize = IntToFixed( int( 1 * font.MacGetFontSize()) );
- RGBColor atsuColor = MAC_WXCOLORREF( col.GetPixel() );
+ RGBColor atsuColor ;
+ col.GetRGBColor( &atsuColor );
ATSUAttributeTag atsuTags[] =
{
kATSUSizeTag ,
else
{
((wxMacCoreGraphicsBrushData*)m_brush.GetRefData())->Apply(this);
- HIViewDrawCGImage( m_cgContext , &r , image );
+ wxMacDrawCGImage( m_cgContext , &r , image );
}
}
}
else
{
- HIViewDrawCGImage( m_cgContext , &r , image );
+ wxMacDrawCGImage( m_cgContext , &r , image );
}
CGImageRelease( image );
}