summaryrefslogtreecommitdiff
path: root/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2016-03-26 14:36:11 +0000
committerManolo Gouy <Manolo>2016-03-26 14:36:11 +0000
commit915d6c643a8b4e31ea79fdad81761d26b42530f5 (patch)
tree8756c72f988596beb8e55382f40ff04142816057 /src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
parente86e4a6ab0e3ad8ccbb694909383f5d72b9b4c92 (diff)
Isolate the definition of the 3 public, OS-dependent types (Fl_Offscreen, Fl_Region, Fl_Bitmask).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11432 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H')
-rw-r--r--src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
index 94bbf000c..7530c331f 100644
--- a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
+++ b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
@@ -26,12 +26,7 @@
#define FL_QUARTZ_GRAPHICS_DRIVER_H
#include <FL/Fl_Graphics_Driver.H>
-
-// typedef what the x,y fields in a point are:
-// FIXME: this is still defined in Fl_Device.H, but should be invisible to the user
-//typedef float COORD_T;
-//typedef struct { float x; float y; } QPoint;
-
+#include <ApplicationServices/ApplicationServices.h>
/**
\brief The Mac OS X-specific graphics class.
@@ -41,7 +36,12 @@
class Fl_Quartz_Graphics_Driver : public Fl_Graphics_Driver {
protected:
CGContextRef gc_;
+ int p_size;
+ typedef struct { float x; float y; } XPOINT;
+ XPOINT *p;
public:
+ Fl_Quartz_Graphics_Driver() : Fl_Graphics_Driver(), gc_(NULL), p_size(0), p(NULL) {}
+ virtual ~Fl_Quartz_Graphics_Driver() { if (p) free(p); }
virtual int has_feature(driver_feature mask) { return mask & NATIVE; }
virtual void gc(void *ctxt) {if (ctxt != gc_) global_gc(); gc_ = (CGContextRef)ctxt; }
virtual void *gc() {return gc_;}
@@ -64,6 +64,8 @@ public:
void copy_offscreen(int x, int y, int w, int h, Fl_Offscreen pixmap, int srcx, int srcy);
void draw_CGImage(CGImageRef cgimg, int x, int y, int w, int h, int srcx, int srcy, int sw, int sh);
protected:
+ void transformed_vertex0(float x, float y);
+ void fixloop();
// --- implementation is in src/fl_rect.cxx which includes src/cfg_gfx/quartz_rect.cxx
void point(int x, int y);
void rect(int x, int y, int w, int h);
@@ -122,6 +124,8 @@ protected:
int descent();
};
+extern float fl_quartz_line_width_;
+
#endif // FL_QUARTZ_GRAPHICS_DRIVER_H
//