diff options
Diffstat (limited to 'cad/fritzing/files/patch-src_items_resistor.cpp')
| -rw-r--r-- | cad/fritzing/files/patch-src_items_resistor.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/cad/fritzing/files/patch-src_items_resistor.cpp b/cad/fritzing/files/patch-src_items_resistor.cpp new file mode 100644 index 000000000000..b7c9c8a1b67d --- /dev/null +++ b/cad/fritzing/files/patch-src_items_resistor.cpp @@ -0,0 +1,11 @@ +--- src/items/resistor.cpp.orig 2025-04-02 10:33:24 UTC ++++ src/items/resistor.cpp +@@ -260,7 +260,7 @@ bool Resistor::collectExtraInfo(QWidget * parent, cons + validator->setSymbol(OhmSymbol); + validator->setConverter(TextUtils::convertFromPowerPrefix); + validator->setBounds(MIN_RESISTANCE, MAX_RESISTANCE); +- validator->setRegularExpression(QRegularExpression(QString("((\\d{1,10})|(\\d{1,10}\\.)|(\\d{1,10}\\.\\d{1,5}))[\\x%1umkMG]{0,1}[\\x03A9]{0,1}").arg(TextUtils::MicroSymbolCode, 4, 16, QChar('0')))); ++ validator->setRegularExpression(QRegularExpression(QString("((\\d{1,10})|(\\d{1,10}\\.)|(\\d{1,10}\\.\\d{1,5}))[\\x%1umkMG]{0,1}[\\x03A9]{0,1}").arg(static_cast<int>(TextUtils::MicroSymbolCode), 4, 16, QChar('0')))); + focusOutComboBox->setValidator(validator); + connect(focusOutComboBox->validator(), SIGNAL(sendState(QValidator::State)), this, SLOT(textModified(QValidator::State))); + connect(focusOutComboBox, SIGNAL(currentIndexChanged(int)), this, SLOT(resistanceEntry(int))); |
