]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/cocoa/dc.h
added wxConvFileName which is a variable, not define as wxConvFile; added comments...
[wxWidgets.git] / include / wx / cocoa / dc.h
index ccf45da7984895b1e2a532c2f00e3cbd7a7a1517..c9cc2250429866d13616dcb05dfd273e32df8595 100644 (file)
@@ -12,6 +12,8 @@
 #ifndef __WX_COCOA_DC_H__
 #define __WX_COCOA_DC_H__
 
 #ifndef __WX_COCOA_DC_H__
 #define __WX_COCOA_DC_H__
 
+DECLARE_WXCOCOA_OBJC_CLASS(NSAffineTransform);
+
 class WXDLLEXPORT wxDC;
 WX_DECLARE_LIST(wxDC, wxCocoaDCStack);
 
 class WXDLLEXPORT wxDC;
 WX_DECLARE_LIST(wxDC, wxCocoaDCStack);
 
@@ -38,6 +40,8 @@ public:
     static WX_NSTextStorage sm_cocoaNSTextStorage;
     static WX_NSLayoutManager sm_cocoaNSLayoutManager;
     static WX_NSTextContainer sm_cocoaNSTextContainer;
     static WX_NSTextStorage sm_cocoaNSTextStorage;
     static WX_NSLayoutManager sm_cocoaNSLayoutManager;
     static WX_NSTextContainer sm_cocoaNSTextContainer;
+    // Create a simple Wx to Bounds transform (just flip the coordinate system)
+    static WX_NSAffineTransform CocoaGetWxToBoundsTransform(bool isFlipped, float height);
 protected:
 // DC stack
     static wxCocoaDCStack sm_cocoaDCStack;
 protected:
 // DC stack
     static wxCocoaDCStack sm_cocoaDCStack;
@@ -54,8 +58,12 @@ protected:
     void CocoaUnwindStackAndLoseFocus();
 // DC flipping/transformation
     void CocoaApplyTransformations();
     void CocoaUnwindStackAndLoseFocus();
 // DC flipping/transformation
     void CocoaApplyTransformations();
-    float m_cocoaHeight;
-    bool m_cocoaFlipped;
+    void CocoaUnapplyTransformations();
+    WX_NSAffineTransform m_cocoaWxToBoundsTransform;
+// Get bounds rect (for Clear())
+    // note: we use void * to mean NSRect * so that we can avoid
+    // putting NSRect in the headers.
+    virtual bool CocoaGetBounds(void *rectData);
 // Blitting
     virtual bool CocoaDoBlitOnFocusedDC(wxCoord xdest, wxCoord ydest,
         wxCoord width, wxCoord height, wxCoord xsrc, wxCoord ysrc,
 // Blitting
     virtual bool CocoaDoBlitOnFocusedDC(wxCoord xdest, wxCoord ydest,
         wxCoord width, wxCoord height, wxCoord xsrc, wxCoord ysrc,