mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
Add GS1data support to QR Code in zint-qt
This commit is contained in:
parent
06cc245516
commit
ca824684ac
@ -6,7 +6,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>441</width>
|
||||
<height>171</height>
|
||||
<height>208</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle" >
|
||||
@ -273,15 +273,69 @@
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0" >
|
||||
<widget class="QCheckBox" name="chkQRHIBC" >
|
||||
<property name="text" >
|
||||
<string>&HIBC QR Code</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="grpAztecMode" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>70</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="title" >
|
||||
<string>Data Encoding</string>
|
||||
</property>
|
||||
<widget class="QRadioButton" name="radQRStand" >
|
||||
<property name="geometry" >
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>17</y>
|
||||
<width>102</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text" >
|
||||
<string>S&tandard</string>
|
||||
</property>
|
||||
<property name="checked" >
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QRadioButton" name="radQRHIBC" >
|
||||
<property name="geometry" >
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>14</y>
|
||||
<width>142</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text" >
|
||||
<string>&HIBC QR Code</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QRadioButton" name="radQRGS1" >
|
||||
<property name="geometry" >
|
||||
<rect>
|
||||
<x>9</x>
|
||||
<y>41</y>
|
||||
<width>151</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text" >
|
||||
<string>&GS-1 Data Mode</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer" >
|
||||
<property name="orientation" >
|
||||
|
@ -365,7 +365,9 @@ void MainWindow::change_options()
|
||||
connect(m_optionWidget->findChild<QObject*>("radQRECC"), SIGNAL(clicked( bool )), SLOT(update_preview()));
|
||||
connect(m_optionWidget->findChild<QObject*>("cmbQRSize"), SIGNAL(currentIndexChanged( int )), SLOT(update_preview()));
|
||||
connect(m_optionWidget->findChild<QObject*>("cmbQRECC"), SIGNAL(currentIndexChanged( int )), SLOT(update_preview()));
|
||||
connect(m_optionWidget->findChild<QObject*>("chkQRHIBC"), SIGNAL(stateChanged( int )), SLOT(update_preview()));
|
||||
connect(m_optionWidget->findChild<QObject*>("radQRStand"), SIGNAL(clicked( bool )), SLOT(update_preview()));
|
||||
connect(m_optionWidget->findChild<QObject*>("radQRGS1"), SIGNAL(clicked( bool )), SLOT(update_preview()));
|
||||
connect(m_optionWidget->findChild<QObject*>("radQRHIBC"), SIGNAL(clicked( bool )), SLOT(update_preview()));
|
||||
}
|
||||
|
||||
if(metaObject()->enumerator(0).value(bstyle->currentIndex()) == BARCODE_MICROQR)
|
||||
@ -705,11 +707,14 @@ void MainWindow::update_preview()
|
||||
break;
|
||||
|
||||
case BARCODE_QRCODE:
|
||||
if(m_optionWidget->findChild<QCheckBox*>("chkQRHIBC")->isChecked())
|
||||
if(m_optionWidget->findChild<QRadioButton*>("radQRHIBC")->isChecked())
|
||||
m_bc.bc.setSymbol(BARCODE_HIBC_QR);
|
||||
else
|
||||
m_bc.bc.setSymbol(BARCODE_QRCODE);
|
||||
|
||||
if(m_optionWidget->findChild<QRadioButton*>("radQRGS1")->isChecked())
|
||||
m_bc.bc.setInputMode(GS1_MODE);
|
||||
|
||||
if(m_optionWidget->findChild<QRadioButton*>("radQRSize")->isChecked())
|
||||
m_bc.bc.setWidth(m_optionWidget->findChild<QComboBox*>("cmbQRSize")->currentIndex() + 1);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user