| 22 | */ |
| 23 | |
| 24 | BinaryOptionsWidget::BinaryOptionsWidget(QWidget* parent) |
| 25 | : QWidget(parent) { |
| 26 | ui.setupUi(parent); |
| 27 | |
| 28 | ui.cbDataType->addItems(BinaryFilter::dataTypes()); |
| 29 | ui.cbByteOrder->addItem(i18n("Little endian"), QDataStream::LittleEndian); |
| 30 | ui.cbByteOrder->addItem(i18n("Big endian"), QDataStream::BigEndian); |
| 31 | |
| 32 | const QString textDataTypeShort = i18n("This option determines the data type that the imported data while converting to numbers."); |
| 33 | |
| 34 | ui.lDataType->setToolTip(textDataTypeShort); |
| 35 | ui.lDataType->setWhatsThis(textDataTypeShort); |
| 36 | ui.cbDataType->setToolTip(textDataTypeShort); |
| 37 | ui.cbDataType->setWhatsThis(textDataTypeShort); |
| 38 | |
| 39 | const QString textByteOrderShort = i18n("This option determines the byte order of the imported data when converting to numbers."); |
| 40 | const QString textByteOrder = textByteOrderShort + QStringLiteral("<br><br>") |
| 41 | + i18n("<table>" |
| 42 | "<tr><td>little endian</td><td>typical byte order (endianness) on Intel x86 processors.</td></tr>" |
| 43 | "<tr><td>big endian</td><td>typical byte order on Mainframes (IBM) and SPARC/PowerPC/Motorola processors.</td></tr>" |
| 44 | "</table>"); |
| 45 | |
| 46 | ui.lByteOrder->setToolTip(textByteOrderShort); |
| 47 | ui.lByteOrder->setWhatsThis(textByteOrder); |
| 48 | ui.cbByteOrder->setToolTip(textByteOrderShort); |
| 49 | ui.cbByteOrder->setWhatsThis(textByteOrder); |
| 50 | } |
| 51 | |
| 52 | void BinaryOptionsWidget::applyFilterSettings(BinaryFilter* filter) const { |
| 53 | Q_ASSERT(filter); |
nothing calls this directly
no test coverage detected