git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67761
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
if ( m_cgContext )
{
CGContextSaveGState( m_cgContext );
if ( m_cgContext )
{
CGContextSaveGState( m_cgContext );
- CGContextConcatCTM( m_cgContext, m_windowTransform );
- CGContextSetTextMatrix( m_cgContext, CGAffineTransformIdentity );
- m_contextSynthesized = true;
#if wxOSX_USE_COCOA_OR_CARBON
if ( m_clipRgn.get() )
{
#if wxOSX_USE_COCOA_OR_CARBON
if ( m_clipRgn.get() )
{
- // the clip region is in device coordinates, so we convert this again to user coordinates
wxCFRef<HIMutableShapeRef> hishape( HIShapeCreateMutableCopy( m_clipRgn ) );
wxCFRef<HIMutableShapeRef> hishape( HIShapeCreateMutableCopy( m_clipRgn ) );
- CGPoint transformedOrigin = CGPointApplyAffineTransform( CGPointZero,m_windowTransform);
- HIShapeOffset( hishape, -transformedOrigin.x, -transformedOrigin.y );
// if the shape is empty, HIShapeReplacePathInCGContext doesn't work
if ( HIShapeIsEmpty(hishape))
{
// if the shape is empty, HIShapeReplacePathInCGContext doesn't work
if ( HIShapeIsEmpty(hishape))
{
+ CGContextConcatCTM( m_cgContext, m_windowTransform );
+ CGContextSetTextMatrix( m_cgContext, CGAffineTransformIdentity );
+ m_contextSynthesized = true;
CGContextSaveGState( m_cgContext );
#if 0 // turn on for debugging of clientdc
CGContextSaveGState( m_cgContext );
#if 0 // turn on for debugging of clientdc
// the clipping itself must be stored as device coordinates, otherwise
// we cannot apply it back correctly
r.origin= CGPointApplyAffineTransform( r.origin, m_windowTransform );
// the clipping itself must be stored as device coordinates, otherwise
// we cannot apply it back correctly
r.origin= CGPointApplyAffineTransform( r.origin, m_windowTransform );
+ r.size= CGSizeApplyAffineTransform(r.size, m_windowTransform);
m_clipRgn.reset(HIShapeCreateWithRect(&r));
#else
// allow usage as measuring context
m_clipRgn.reset(HIShapeCreateWithRect(&r));
#else
// allow usage as measuring context