diff options
| author | Markus Engel <markus.engel@tum.de> | 2013-07-30 21:17:21 +0000 |
|---|---|---|
| committer | Markus Engel <markus.engel@tum.de> | 2013-07-30 21:17:21 +0000 |
| commit | b2dd3583e7372d23d18bbc6e861f4f645ec3dc37 (patch) | |
| tree | 659f5549fc533cebec5326615b6e385ffdde5453 /src/common-context.h | |
| parent | Merge from trunk (r12439). (diff) | |
| download | inkscape-b2dd3583e7372d23d18bbc6e861f4f645ec3dc37.tar.gz inkscape-b2dd3583e7372d23d18bbc6e861f4f645ec3dc37.zip | |
Further refactoring of EventContexts.
(bzr r11608.1.109)
Diffstat (limited to 'src/common-context.h')
| -rw-r--r-- | src/common-context.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/common-context.h b/src/common-context.h index ffcf8de38..dc4c82251 100644 --- a/src/common-context.h +++ b/src/common-context.h @@ -23,9 +23,6 @@ #include "display/curve.h" #include <2geom/point.h> -#define SP_COMMON_CONTEXT(obj) ((SPCommonContext*)obj) -#define SP_IS_COMMON_CONTEXT(obj) (dynamic_cast<const SPCommonContext*>((const SPEventContext*)obj)) - #define SAMPLING_SIZE 8 /* fixme: ?? */ class SPCommonContext : public SPEventContext { @@ -33,6 +30,9 @@ public: SPCommonContext(); virtual ~SPCommonContext(); + virtual void set(const Inkscape::Preferences::Entry& val); + +protected: /** accumulated shape which ultimately goes in svg:path */ SPCurve *accumulated; @@ -89,14 +89,15 @@ public: double tremor; double cap_rounding; - Inkscape::MessageContext *_message_context; + //Inkscape::MessageContext *_message_context; bool is_drawing; /** uses absolute width independent of zoom */ bool abs_width; - virtual void set(const Inkscape::Preferences::Entry& val); + Geom::Point getViewPoint(Geom::Point n) const; + Geom::Point getNormalizedPoint(Geom::Point v) const; }; #endif // COMMON_CONTEXT_H_SEEN |
