diff options
author | joye <joye> | 2014-03-27 19:07:16 (GMT) |
---|---|---|
committer | joye <joye> | 2014-03-27 19:07:16 (GMT) |
commit | fd743f2c68c60ad0305457d1b1f8d56f75950820 (patch) | |
tree | 660b4fa1e6b4b797708077d604721080a5c0b4f4 | |
parent | 23dee42560257638a7cfc316f89fb29f16cec27b (diff) | |
download | blt-fd743f2c68c60ad0305457d1b1f8d56f75950820.zip blt-fd743f2c68c60ad0305457d1b1f8d56f75950820.tar.gz blt-fd743f2c68c60ad0305457d1b1f8d56f75950820.tar.bz2 |
*** empty log message ***
-rw-r--r-- | bltGrMarkerBitmap.C | 2 | ||||
-rw-r--r-- | bltGrMarkerBitmap.h | 4 | ||||
-rw-r--r-- | src/bltGrMarker.C | 6 | ||||
-rw-r--r-- | src/bltGrMarker.h | 27 | ||||
-rw-r--r-- | src/bltGrMarkerLine.C | 2 | ||||
-rw-r--r-- | src/bltGrMarkerLine.h | 3 | ||||
-rw-r--r-- | src/bltGrMarkerPolygon.C | 2 | ||||
-rw-r--r-- | src/bltGrMarkerPolygon.h | 4 | ||||
-rw-r--r-- | src/bltGrMarkerText.C | 6 | ||||
-rw-r--r-- | src/bltGrMarkerText.h | 4 | ||||
-rw-r--r-- | src/bltGraph.C | 2 |
11 files changed, 46 insertions, 16 deletions
diff --git a/bltGrMarkerBitmap.C b/bltGrMarkerBitmap.C index cfbf3d1..370e5c8 100644 --- a/bltGrMarkerBitmap.C +++ b/bltGrMarkerBitmap.C @@ -35,6 +35,8 @@ extern "C" { #include "bltGrMarkerBitmap.h" +using namespace Blt; + BitmapMarker::BitmapMarker() : BltMarker() { anchorPt.x =0; diff --git a/bltGrMarkerBitmap.h b/bltGrMarkerBitmap.h index 5e6b072..2341807 100644 --- a/bltGrMarkerBitmap.h +++ b/bltGrMarkerBitmap.h @@ -32,6 +32,8 @@ #include "bltGrMarker.h" +namespace Blt { + typedef struct { const char** tags; Coords* worldPts; @@ -64,4 +66,6 @@ class BitmapMarker : public BltMarker { virtual ~BitmapMarker(); }; +}; + #endif diff --git a/src/bltGrMarker.C b/src/bltGrMarker.C index da16388..dbe5529 100644 --- a/src/bltGrMarker.C +++ b/src/bltGrMarker.C @@ -39,6 +39,8 @@ extern "C" { #include "bltGrElem.h" #include "bltGrMarker.h" +using namespace Blt; + extern MarkerCreateProc Blt_CreateBitmapProc; extern MarkerCreateProc Blt_CreateLineProc; extern MarkerCreateProc Blt_CreatePolygonProc; @@ -65,7 +67,7 @@ BltMarker::BltMarker() */ } -BltMarker::~BltMarker() +Blt::BltMarker::~BltMarker() { } @@ -274,7 +276,7 @@ static int CreateMarker(Graph* graphPtr, Tcl_Interp* interp, } const char* type = Tcl_GetString(objv[3]); - BltMarker *markerPtr; + Blt::BltMarker* markerPtr; if (!strcmp(type, "text")) { markerPtr = Blt_CreateTextProc(graphPtr); Blt_GraphSetObjectClass(&markerPtr->obj, CID_MARKER_TEXT); diff --git a/src/bltGrMarker.h b/src/bltGrMarker.h index 7a72a2d..3304176 100644 --- a/src/bltGrMarker.h +++ b/src/bltGrMarker.h @@ -32,7 +32,8 @@ #define MAX_OUTLINE_POINTS 12 -class BltMarker; +namespace Blt { + class BltMarker; typedef BltMarker* (MarkerCreateProc)(Graph*); typedef void (MarkerDrawProc)(BltMarker* markerPtr, Drawable drawable); @@ -71,21 +72,23 @@ typedef struct { int yOffset; } MarkerOptions; -class BltMarker { + class BltMarker { public: - GraphObj obj; - MarkerClass *classPtr; - Tk_OptionTable optionTable; - Tcl_HashEntry* hashPtr; - Blt_ChainLink link; - int clipped; - unsigned int flags; + GraphObj obj; + MarkerClass *classPtr; + Tk_OptionTable optionTable; + Tcl_HashEntry* hashPtr; + Blt_ChainLink link; + int clipped; + unsigned int flags; - void* ops; + void* ops; public: - BltMarker(); - virtual ~BltMarker(); + BltMarker(); + virtual ~BltMarker(); + }; + }; Point2d Blt_MapPoint(Point2d *pointPtr, Axis2d *axesPtr); diff --git a/src/bltGrMarkerLine.C b/src/bltGrMarkerLine.C index 5dc7989..1cbfda5 100644 --- a/src/bltGrMarkerLine.C +++ b/src/bltGrMarkerLine.C @@ -35,6 +35,8 @@ extern "C" { #include "bltGrMarkerLine.h" +using namespace Blt; + LineMarker::LineMarker() : BltMarker() { /* diff --git a/src/bltGrMarkerLine.h b/src/bltGrMarkerLine.h index 14486b9..cfc3f35 100644 --- a/src/bltGrMarkerLine.h +++ b/src/bltGrMarkerLine.h @@ -32,6 +32,8 @@ #include "bltGrMarker.h" +namespace Blt { + typedef struct { const char** tags; Coords* worldPts; @@ -64,4 +66,5 @@ class LineMarker : public BltMarker { virtual ~LineMarker(); }; +}; #endif diff --git a/src/bltGrMarkerPolygon.C b/src/bltGrMarkerPolygon.C index 3cceee8..73a298f 100644 --- a/src/bltGrMarkerPolygon.C +++ b/src/bltGrMarkerPolygon.C @@ -35,6 +35,8 @@ extern "C" { #include "bltGrMarkerPolygon.h" +using namespace Blt; + PolygonMarker::PolygonMarker() : BltMarker() { screenPts =NULL; diff --git a/src/bltGrMarkerPolygon.h b/src/bltGrMarkerPolygon.h index 98be92b..151e8b6 100644 --- a/src/bltGrMarkerPolygon.h +++ b/src/bltGrMarkerPolygon.h @@ -32,6 +32,8 @@ #include "bltGrMarker.h" +namespace Blt { + typedef struct { const char** tags; Coords* worldPts; @@ -71,4 +73,6 @@ class PolygonMarker : public BltMarker { virtual ~PolygonMarker(); }; +}; + #endif diff --git a/src/bltGrMarkerText.C b/src/bltGrMarkerText.C index eb03e58..676ea55 100644 --- a/src/bltGrMarkerText.C +++ b/src/bltGrMarkerText.C @@ -36,6 +36,8 @@ extern "C" { #include "bltGrMarkerText.h" +using namespace Blt; + TextMarker::TextMarker() : BltMarker() { anchorPt.x =0; @@ -116,7 +118,7 @@ static MarkerClass textMarkerClass = { TextToPostscriptProc, }; -BltMarker* Blt_CreateTextProc(Graph* graphPtr) +Blt::BltMarker* Blt_CreateTextProc(Graph* graphPtr) { TextMarker* tmPtr = (TextMarker*)calloc(1, sizeof(TextMarker)); tmPtr->classPtr = &textMarkerClass; @@ -126,7 +128,7 @@ BltMarker* Blt_CreateTextProc(Graph* graphPtr) Blt_Ts_InitStyle(ops->style); tmPtr->optionTable = Tk_CreateOptionTable(graphPtr->interp, optionSpecs); - return (BltMarker*)tmPtr; + return (Blt::BltMarker*)tmPtr; } static int ConfigureTextProc(BltMarker* markerPtr) diff --git a/src/bltGrMarkerText.h b/src/bltGrMarkerText.h index ed52061..5e7ed68 100644 --- a/src/bltGrMarkerText.h +++ b/src/bltGrMarkerText.h @@ -32,6 +32,8 @@ #include "bltGrMarker.h" +namespace Blt { + typedef struct { const char** tags; Coords* worldPts; @@ -62,4 +64,6 @@ class TextMarker : public BltMarker { virtual ~TextMarker(); }; +}; + #endif diff --git a/src/bltGraph.C b/src/bltGraph.C index 6737684..46396f2 100644 --- a/src/bltGraph.C +++ b/src/bltGraph.C @@ -43,6 +43,8 @@ extern "C" { #include "bltGrElem.h" #include "bltGrMarker.h" +using namespace Blt; + #define MARKER_UNDER 1 /* Draw markers designated to lie underneath * elements, grids, legend, etc. */ #define MARKER_ABOVE 0 /* Draw markers designated to rest above |