missing methods
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42582 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1752,16 +1752,24 @@ void * wxMacCoreGraphicsContext::GetNativeContext()
|
|||||||
// concatenates this transform with the current transform of this context
|
// concatenates this transform with the current transform of this context
|
||||||
void wxMacCoreGraphicsContext::ConcatTransform( const wxGraphicsMatrix& matrix )
|
void wxMacCoreGraphicsContext::ConcatTransform( const wxGraphicsMatrix& matrix )
|
||||||
{
|
{
|
||||||
|
CGContextConcatCTM( m_cgContext, *(CGAffineTransform*) matrix.GetNativeMatrix());
|
||||||
}
|
}
|
||||||
|
|
||||||
// sets the transform of this context
|
// sets the transform of this context
|
||||||
void wxMacCoreGraphicsContext::SetTransform( const wxGraphicsMatrix& matrix )
|
void wxMacCoreGraphicsContext::SetTransform( const wxGraphicsMatrix& matrix )
|
||||||
{
|
{
|
||||||
|
CGAffineTransform transform = CGContextGetCTM( m_cgContext );
|
||||||
|
transform = CGAffineTransformInvert( transform ) ;
|
||||||
|
CGContextConcatCTM( m_cgContext, transform);
|
||||||
|
CGContextConcatCTM( m_cgContext, *(CGAffineTransform*) matrix.GetNativeMatrix());
|
||||||
}
|
}
|
||||||
|
|
||||||
// gets the matrix of this context
|
// gets the matrix of this context
|
||||||
wxGraphicsMatrix wxMacCoreGraphicsContext::GetTransform() const
|
wxGraphicsMatrix wxMacCoreGraphicsContext::GetTransform() const
|
||||||
{
|
{
|
||||||
|
wxGraphicsMatrix m = CreateMatrix();
|
||||||
|
*((CGAffineTransform*) m.GetNativeMatrix()) = CGContextGetCTM( m_cgContext );
|
||||||
|
return m;
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
Reference in New Issue
Block a user