Loading [MathJax]/extensions/tex2jax.js
 |
ATLAS Offline Software
|
Go to the documentation of this file.
25 #include <Inventor/nodes/SoMaterial.h>
29 #include <QDataStream>
35 #include <QDoubleSpinBox>
39 #include <QRadioButton>
63 +QString(
w->metaObject()->className())
64 +
", name="+
w->objectName());
104 message(
"WARNING: warnUnsaved(..) was never called!");
138 messageDebug(
"VP1Serialise::save(QCheckBox) - name: " + cb->objectName());
141 save(cb->isChecked());
148 messageDebug(
"VP1Serialise::save(QGroupBox) - name: " + gb->objectName());
150 if (!gb->isCheckable())
151 message(
"WARNING: Asked to handled GroupBox which is not checkable: "+gb->objectName());
153 save(gb->isChecked());
160 messageDebug(
"VP1Serialise::save(QComboBox) - name: " + cb->objectName());
163 save( cb->count() > 0 ? cb->currentText() : QString() );
170 messageDebug(
"\nVP1Serialise::save(QLineEdit) - name: " + le->objectName());
180 messageDebug(
"\nVP1Serialise::save(QDoubleSpinBox) - name: " +
sb->objectName());
190 messageDebug(
"\nVP1Serialise::save(QSpinBox) - name: " +
sb->objectName());
200 messageDebug(
"\nVP1Serialise::save(QSlider) - name: " +
s->objectName());
255 messageDebug(
"\nVP1Serialise::save(QToolBox) - name: " +
tb->objectName());
258 save(
tb &&
tb->count() > 0 ?
tb->currentIndex() : -1 );
265 messageDebug(
"\nVP1Serialise::save(QToolBox) - name: " +
tb->objectName());
268 int i =
tb ?
tb->currentIndex() : -1;
291 messageDebug(
"\nVP1Serialise::save(VP1MaterialButton) - name: " +
mb->objectName());
294 QList<SoMaterial*> mats =
mb ?
mb->handledMaterials() : QList<SoMaterial*>();
295 save(mats.isEmpty() ? 0 : mats.at(0));
302 messageDebug(
"\nVP1Serialise::save(QColor) - name: " +
c.name());
314 messageDebug(
"\nVP1Serialise::save(VP1ColorSelectButton) - name: " + cb->objectName());
324 messageDebug(
"\nVP1Serialise::save(PhiSectionWidget) - name: " +
phi->objectName());
345 QList<QRadioButton *>
l;
346 l << rb0 << rb1 << rb2 << rb3 << rb4 << rb5 << rb6 << rb7 << rb8 << rb9;
347 for (qint32
i = 0;
i <
l.count(); ++
i) {
350 messageDebug(
"\nVP1Serialise::save(QRadioButton) - name: " +
l.at(
i)->objectName());
356 for (qint32
i = 0;
i <
l.count(); ++
i) {
357 if (
l.at(
i)&&
l.at(
i)->isChecked()) {
369 messageDebug(
"\nVP1Serialise::save(VP1CollectionWidget) - name: " + cw->objectName());
370 messageDebug(
"VP1Serialise::save(VP1CollectionWidget)- start...");
376 buffer.open(QIODevice::WriteOnly);
383 messageDebug(
"VP1Serialise::save(VP1CollectionWidget)- end.");
398 messageDebug(
"\nVP1Serialise::save(VP1CollectionSettingsButtonBase) - name: " + jcb->objectName());
399 messageDebug(
"VP1Serialise::save(VP1CollectionSettingsButtonBase)- start...");
405 messageDebug(
"VP1Serialise::save(VP1CollectionSettingsButtonBase)- end.");
414 messageDebug(
"\nVP1Serialise::save(VP1EtaPhiCutWidget) - name: " +
w->objectName());
418 save(
w ?
w->saveState() : QByteArray());
425 messageDebug(
"\nVP1Serialise::save(VP1DrawOptionsWidget) - name: " +
w->objectName());
429 save(
w ?
w->state() : QByteArray());
436 messageDebug(
"\nVP1Serialise::ignoreWidget(QWidget) - name: " +
w->objectName());
457 if (
w->inherits(
"QGroupBox"))
458 return static_cast<const QGroupBox*
>(
w)->isCheckable();
460 return w->inherits(
"QCheckBox")
461 ||
w->inherits(
"QRadioButton")
462 ||
w->inherits(
"QComboBox")
463 ||
w->inherits(
"QAbstractSpinBox")
464 ||
w->inherits(
"QSlider")
465 ||
w->inherits(
"QToolBox")
466 ||
w->inherits(
"PhiSectionWidget")
467 ||
w->inherits(
"VP1EtaPhiCutWidget")
468 ||
w->inherits(
"VP1DrawOptionsWidget")
469 ||
w->inherits(
"QLineEdit")
470 ||
w->inherits(
"VP1ColorSelectButton")
471 ||
w->inherits(
"VP1MaterialButton");
494 if (
object->isWidgetType()&&!
object->objectName().startsWith(
"qt_")) {
495 const QWidget * wid =
static_cast<const QWidget*
>(
object);
497 QString
s(
"WARNING Unsaved widget of type: "+QString(wid->metaObject()->className())+
" and object name = "+wid->objectName());
507 for (
const QObject* o :
object->children())
Scalar phi() const
phi method
void messageVerbose(const QString &) const
static void decrementNumberOfInstantiations()
void warnUnsaved(const QObject *)
void widgetHandled(const QWidget *)
void handle(const QWidget *w)
static QString str(const QString &s)
void messageDebug(const QString &) const
static unsigned numberOfInstantiations()
QSet< const QWidget * > handledWidgets
static QByteArray serialiseSoMaterial(SoMaterial *)
static unsigned numberOfInstantiations
VP1Serialise(qint32 version, IVP1System *sys=0)
QSet< const QWidget * > ignoredWidgets
void saveByTitle(QToolBox *)
void ignoreWidget(const QWidget *)
void disableUnsavedChecks()
const double mb
1mb to cm2
const PlainObject unit() const
This is a plugin that makes Eigen look like CLHEP & defines some convenience methods.
bool expectsPersistification(const QWidget *w)
void message(const QString &) const
const QByteArray & result()