Esempio n. 1
0
caNumeric::caNumeric(QWidget *parent) : ENumeric(parent)
{
     setAccessW(true);
     setPrecisionMode(Channel);
     setLimitsMode(Channel);
     thisMaximum = 100000.0;
     thisMinimum = -100000.0;
     setDigitsFontScaleEnabled(true);
     setForeground(Qt::black);
     setBackground(QColor(230,230,230));
}
caApplyNumeric::caApplyNumeric(QWidget *parent) : EApplyNumeric(parent)
{
    setAccessW(true);
    setPrecisionMode(Channel);
    setLimitsMode(Channel);
    thisMaximum = 100000.0;
    thisMinimum = -100000.0;
    setDigitsFontScaleEnabled(true);
    setForeground(Qt::black);
    setBackground(QColor(230,230,230));
    thisFixedFormat = false;
    installEventFilter(this);
}
Esempio n. 3
0
int ENumeric::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QFrame::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMethod) {
        if (_id < 8)
            qt_static_metacall(this, _c, _id, _a);
        _id -= 8;
    }
#ifndef QT_NO_PROPERTIES
      else if (_c == QMetaObject::ReadProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 0: *reinterpret_cast< int*>(_v) = intDigits(); break;
        case 1: *reinterpret_cast< int*>(_v) = decDigits(); break;
        case 2: *reinterpret_cast< double*>(_v) = value(); break;
        case 3: *reinterpret_cast< double*>(_v) = maximum(); break;
        case 4: *reinterpret_cast< double*>(_v) = minimum(); break;
        case 5: *reinterpret_cast< bool*>(_v) = digitsFontScaleEnabled(); break;
        }
        _id -= 6;
    } else if (_c == QMetaObject::WriteProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 0: setIntDigits(*reinterpret_cast< int*>(_v)); break;
        case 1: setDecDigits(*reinterpret_cast< int*>(_v)); break;
        case 2: setValue(*reinterpret_cast< double*>(_v)); break;
        case 3: setMaximum(*reinterpret_cast< double*>(_v)); break;
        case 4: setMinimum(*reinterpret_cast< double*>(_v)); break;
        case 5: setDigitsFontScaleEnabled(*reinterpret_cast< bool*>(_v)); break;
        }
        _id -= 6;
    } else if (_c == QMetaObject::ResetProperty) {
        _id -= 6;
    } else if (_c == QMetaObject::QueryPropertyDesignable) {
        _id -= 6;
    } else if (_c == QMetaObject::QueryPropertyScriptable) {
        _id -= 6;
    } else if (_c == QMetaObject::QueryPropertyStored) {
        _id -= 6;
    } else if (_c == QMetaObject::QueryPropertyEditable) {
        _id -= 6;
    } else if (_c == QMetaObject::QueryPropertyUser) {
        _id -= 6;
    }
#endif // QT_NO_PROPERTIES
    return _id;
}
Esempio n. 4
0
caNumeric::caNumeric(QWidget *parent) : ENumeric(parent)
{
     setStyleSheet("");

     setAccessW(true);
     setPrecisionMode(Channel);
     setLimitsMode(Channel);
     setMaxValue(100000.0);
     setMinValue(-100000.0);
     thisFixedFormat = false;
     thisColorMode = Static;
     setDigitsFontScaleEnabled(true);
     setForeground(Qt::black);

     renewStyleSheet = true;
     setBackground(QColor(230,230,230));
     setElevation(on_top);
}