Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

sxy_task_mvpoint.h

Go to the documentation of this file.
00001 
00002 #ifndef task_mvpoint_h
00003 #define task_mvpoint_h
00004 
00005 // =======================================================================
00006 
00007 #include <xy.h>
00008 
00009 #include "sxy_graph.h"
00010 #include "sxy_task.h"
00011 
00012 // =======================================================================
00013 
00014 class SXYGraph;
00015 class SXYChart;
00016 class SXYCurve;
00017 
00018 // ----------------------------------------------------------------------
00019 //* Define uma tarefa de movimentação de um ponto em um gráfico
00020 
00021 class SXYTaskMovePoint : public SXYTask {
00023    unsigned int button;
00024 
00026    unsigned int is_moving;
00027 
00029    int ref_x;
00030 
00032    int ref_y;
00033 
00035    int shift_x;
00036 
00038    int shift_y;
00039 
00041    unsigned int lock_x;
00042 
00044    unsigned int lock_y;
00045 
00047    double original_xvalue;
00048 
00050    double original_yvalue;
00051 
00053    SXYChart*  user_chart;
00054 
00056    SXYCurve*  user_curve;
00057 
00059    unsigned int user_mask;
00060 
00062    unsigned int user_series;
00063 
00065    unsigned int user_point;
00066 
00067  private:
00068 
00069    void resetAttributes(void);
00070    void drawCoordinate(void);
00071 
00072  public:
00073 
00074   void lockHorizontal( unsigned int l );
00075   void lockVertical( unsigned int l );
00076   unsigned int  isHorizontallyLocked( void );
00077   unsigned int  isVerticallyLocked( void );
00078 
00079   SXYTaskReturn mouseEnter(SXYGraph* graph);
00080   SXYTaskReturn mouseLeave(SXYGraph* graph);
00081   SXYTaskReturn mouseClick(SXYGraph* graph, 
00082         int b, int x, int y, int sft, int ctr);
00083   SXYTaskReturn mouseUnclick(SXYGraph* graph, 
00084         int b, int x, int y, int sft, int ctr);
00085   SXYTaskReturn mouseMotion(SXYGraph* graph, 
00086         int x, int y, int sft, int ctr);
00087 
00088 
00089   SXYTaskMovePoint(unsigned int button=1);
00090   virtual ~SXYTaskMovePoint();
00091 };
00092 
00093 #endif
00094 

SXY
Tecgraf / PUC-Rio - Computer Graphics Technology Group