1 #ifndef GPMG_RuleGraphDrawPanel_H
2 #define GPMG_RuleGraphDrawPanel_H
27 SP::CORE_Color mPatternGraphColor;
28 SP::CORE_Color mTransformGraphColor;
29 SP::CORE_Color mDeletedGraphElementColor;
30 SP::CORE_Color mKeptGraphElementColor;
31 SP::CORE_Color mPTEdgeColor;
36 SP::GPM_ModelFunction mRule;
63 static inline SP::GPMG_RuleGraphDrawPanel
New() {
65 GPMG_RuleGraphDrawPanel::Delete());
101 const int& x,
const int& y);
105 virtual GUI_AlonePopupMenu*
getPopupMenu(
const int& x,
const int& y,GUI2D_Item* item);
133 virtual void computeVertexBounds(
double& xMin,
double& yMin,
double& xMax,
double& yMax)
const;
168 void drawVertices(
const tReal& xmin,
174 void drawEdges(
const tReal& xmin,
182 virtual SP::GPM_Edge
addEdge(SP::GPM_Vertex source,SP::GPM_Vertex target);
virtual void objectIsClickedOn(SP::CORE_Object item)
method called when the object is double clicked on
Definition: GPMG_RuleGraphDrawPanel.cpp:852
virtual void loadFromUIClass(const UI_Class &mclass)
how to load the object from a Meta Model class
Definition: GPMG_RuleGraphDrawPanel.cpp:1100
virtual ~GPMG_RuleGraphDrawPanel(void)
destroy a GPMG_RuleGraphDrawPanel
Definition: GPMG_RuleGraphDrawPanel.cpp:28
virtual void computeVertexBounds(double &xMin, double &yMin, double &xMax, double &yMax) const
recompute the vertex bounds
Definition: GPMG_RuleGraphDrawPanel.cpp:48
virtual void saveToUIClass(UI_Class &mclass) const
how to save the object from a mate model class
Definition: GPMG_RuleGraphDrawPanel.cpp:1119
void showRule(GPM_ModelFunction &function)
show the rule
Definition: GPMG_RuleGraphDrawPanel.cpp:127
virtual tFlag getGraphType(const GPM_Graph *graph) const
return the graph type of the graph
Definition: GPMG_RuleGraphDrawPanel.cpp:220
this class describes a Graph Draw Panel.
Definition: GPMG_DrawPanel.h:15
virtual void initAttributes()
init attributes of the draw panel
Definition: GPMG_RuleGraphDrawPanel.cpp:33
this class describes a Rule Graphs Draw Panel.
Definition: GPMG_RuleGraphDrawPanel.h:15
virtual SP::GPM_Edge addEdge(SP::GPM_Vertex source, SP::GPM_Vertex target)
add edge between vertices source & target
Definition: GPMG_RuleGraphDrawPanel.cpp:1035
#define tBoolean
Definition: types.h:35
virtual void computePortsScale()=0
compute the port scale
virtual void computePortsScale()
compute the port scale
Definition: GPMG_RuleGraphDrawPanel.h:145
This class describes a node.
Definition: GPM_Vertex.h:16
virtual tBoolean paintElements()
paint the element in the drawing area
Definition: GPMG_RuleGraphDrawPanel.cpp:238
void clearGraphs()
clear the graphs of the rules
Definition: GPMG_RuleGraphDrawPanel.cpp:227
#define REAL_INFINITY
Definition: types.h:57
This class describes a edge.
Definition: GPM_Edge.h:15
virtual void popupMenuClicked(const tString &name, const int &x, const int &y)
method called when ab item of a popup menu is clicked on component
Definition: GPMG_RuleGraphDrawPanel.cpp:876
virtual void computeEdgesScale()
compute the edge scale
Definition: GPMG_RuleGraphDrawPanel.h:153
virtual void computeNodesScale()
compute the node scale
Definition: GPMG_RuleGraphDrawPanel.h:137
virtual void deleteEdge(GPM_Edge &edge)
delete an edge
Definition: GPMG_RuleGraphDrawPanel.cpp:1025
#define tString
Definition: types.h:36
virtual void computeNodesScale()=0
compute the node scale
virtual void computeEdgesScale()=0
compute the edges scale
GPMG_RuleGraphDrawPanel()
build a GPMG_RuleGraphDrawPanel
Definition: GPMG_RuleGraphDrawPanel.cpp:20
virtual void deleteVertex(GPM_Vertex &vertex)
delete a vertex
Definition: GPMG_RuleGraphDrawPanel.cpp:1012
This class describes a pattern function.
Definition: GPM_ModelFunction.h:23
virtual void createPopupMenus()
create popup menus
Definition: GPMG_RuleGraphDrawPanel.cpp:635
virtual GUI_AlonePopupMenu * getPopupMenu(const int &x, const int &y, GUI2D_Item *item)
get the popup menu
Definition: GPMG_RuleGraphDrawPanel.cpp:723
DEFINE_SPTR(GPMG_RuleGraphDrawPanel)
This class describes a graph which is a list of nodes & ports.
Definition: GPM_Graph.h:19
#define tReal
Definition: types.h:18
#define tFlag
Definition: types.h:14
static SP::GPMG_RuleGraphDrawPanel New()
create a 2D plotter panel
Definition: GPMG_RuleGraphDrawPanel.h:63