28 #include "../propertybrowser/AbstractPropertyManager.h" 36 m_editAction(editScale),
41 QtTreePropertyBrowser* pb =
new QtTreePropertyBrowser(w);
42 pb->setPropertiesWithoutValueMarked(
true);
43 pb->setResizeMode(QtTreePropertyBrowser::ResizeToContents);
47 QGridLayout* lay =
new QGridLayout(w);
54 setAttribute(Qt::WA_DeleteOnClose,
true);
75 QStringList ics_names;
78 units << tr(
"Degrees")
97 header_prop->addSubProperty(visAll_prop);
102 header_prop->addSubProperty(hfont_prop);
107 header_prop->addSubProperty(hcolor_prop);
116 ruler_prop->addSubProperty(width_prop);
122 ruler_prop->addSubProperty(intervals_prop);
128 ruler_prop->addSubProperty(unitsPerGap_prop);
133 ruler_prop->addSubProperty(rulerColor_prop);
140 ruler_prop->addSubProperty(type_prop);
148 footer_prop->addSubProperty(num_vis_prop);
153 footer_prop->addSubProperty(ffont_prop);
158 footer_prop->addSubProperty(fcolor_prop);
166 scale_prop->addSubProperty(unit_prop);
167 scale_prop->addSubProperty(header_prop);
168 scale_prop->addSubProperty(ruler_prop);
169 scale_prop->addSubProperty(footer_prop);
171 addProperty(scale_prop, tr(
"Scale"), QColor(175, 255, 175));
173 wid->connect(
this, SIGNAL(
interactHandleChanged(
const bool&)), SLOT(setInteractionHandle(
const bool&)));
175 wid->connect(
this, SIGNAL(
headerColorChanged(
const QColor&)), SLOT(setHeaderColor(
const QColor&)));
176 wid->connect(
this, SIGNAL(
rulerColorChanged(
const QColor&)), SLOT(setRulerColor(
const QColor&)));
177 wid->connect(
this, SIGNAL(
footerColorChanged(
const QColor&)), SLOT(setFooterColor(
const QColor&)));
179 wid->connect(
this, SIGNAL(
headerFontChanged(
const QFont&)), SLOT(setHeaderFont(
const QFont&)));
180 wid->connect(
this, SIGNAL(
footerFontChanged(
const QFont&)), SLOT(setFooterFont(
const QFont&)));
182 wid->connect(
this, SIGNAL(
scaleTypeChanged(
const int&)), SLOT(setScaleType(
const int&)));
184 wid->connect(
this, SIGNAL(
unitChanged(
const QString&)), SLOT(setUnit(
const QString&)));
187 wid->connect(
this, SIGNAL(
rulerHeightChanged(
const int&)), SLOT(setRulerHeightMM(
const int&)));
189 wid->connect(
this, SIGNAL(
unitsPerGapChanged(
const int&)), SLOT(setUnitsPerGap(
const int&)));
196 if (p->propertyName() == tr(
"Interaction enabled"))
198 else if (p->propertyName() == tr(
"Intermediary values visible"))
206 if (p->propertyName() == tr(
"Header color"))
208 else if (p->propertyName() == tr(
"Ruler color"))
216 if (p->propertyName() == tr(
"Header font"))
224 if (p->propertyName() == tr(
"Unit"))
226 else if (p->propertyName() == tr(
"Height in millimeters"))
228 else if (p->propertyName() == tr(
"Number of intervals"))
230 else if (p->propertyName() == tr(
"Units per gap"))
static AbstractPropertyManager & getInstance()
It returns a reference to the singleton instance.