21 #ifndef CAPTIONGRAPHICSITEM_H
22 #define CAPTIONGRAPHICSITEM_H
25 #include <QtGui/QGraphicsItemGroup>
27 #include <QtGui/QPushButton>
28 #include <QtGui/QGraphicsSceneMouseEvent>
29 #include <QtOpenGL/QGLFramebufferObject>
30 #include <tulip/View.h>
31 #include <tulip/Color.h>
32 #include "tulip/CaptionGraphicsSubItems.h"
40 class CaptionGraphicsItem :
public QObject {
46 CaptionGraphicsItem(View *view);
47 ~CaptionGraphicsItem();
49 void setType(
unsigned int type);
51 void loadConfiguration();
53 void generateColorCaption(
const QGradient &activeGradient,
const QGradient &hideGradient,
const std::string &propertyName,
double minValue,
double maxValue);
55 void generateSizeCaption(
const std::vector< std::pair <double,float> > &metricToSizeFilteredList,
const std::string &propertyName,
double minValue,
double maxValue);
57 CaptionGraphicsBackgroundItem *getCaptionItem()
const {
58 return _rondedRectItem;
61 std::string usedProperty();
65 void filterChanged(
float begin,
float end);
66 void selectedPropertyChanged(std::string propertyName);
70 void filterChangedSlot(
float begin,
float end);
71 void selectPropertyButtonClicked();
72 void propertySelectedSlot();
76 QString wrappedPropName(
const QString& originalName)
const;
78 void constructConfigWidget();
82 CaptionGraphicsBackgroundItem *_rondedRectItem;
84 QGraphicsProxyWidget *_confPropertySelectionItem;
85 QGraphicsSimpleTextItem *_nodesEdgesTextItem;
87 QPushButton* _confPropertySelectionWidget;
92 #endif // CAPTIONGRAPHICSITEM_H