diff --git a/frontend_qt4/mainWindow.ui b/frontend_qt4/mainWindow.ui index df9856f8..871bc917 100644 --- a/frontend_qt4/mainWindow.ui +++ b/frontend_qt4/mainWindow.ui @@ -16,7 +16,7 @@ - + @@ -29,7 +29,7 @@ - + @@ -63,7 +63,31 @@ - + + + + + + Height: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + 300 + + + 50 + + + + + + @@ -93,48 +117,7 @@ - - - - - - Height: - - - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter - - - - - - - 300 - - - 50 - - - - - - - - - - - Primary - - - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter - - - - - - - - - + @@ -158,32 +141,24 @@ - - + + - + - Data + Primary + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter - - - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> -p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">123456</p></body></html> - - - false - - + - + @@ -210,7 +185,32 @@ p, li { white-space: pre-wrap; } - + + + + + + Data + + + + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'DejaVu Sans'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif'; font-size:10pt;">123456</p></body></html> + + + false + + + + + + @@ -237,7 +237,7 @@ p, li { white-space: pre-wrap; } - + @@ -264,7 +264,7 @@ p, li { white-space: pre-wrap; } - + @@ -297,7 +297,7 @@ p, li { white-space: pre-wrap; } - + @@ -324,7 +324,78 @@ p, li { white-space: pre-wrap; } - + + + + + + MSI PLESSEY: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + + MSI_PLESSEY + + + + + MSI_10 + + + + + MSI_10_10 + + + + + MSI_11 + + + + + MSI_11_10 + + + + + + + + + + + + (Ex)CODE39: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + + (EX)CODE39 + + + + + (EX)CODE39_43 + + + + + + + @@ -342,7 +413,7 @@ p, li { white-space: pre-wrap; } - + diff --git a/frontend_qt4/mainwindow.cpp b/frontend_qt4/mainwindow.cpp index d97e6a11..c1b6759c 100644 --- a/frontend_qt4/mainwindow.cpp +++ b/frontend_qt4/mainwindow.cpp @@ -31,10 +31,10 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags fl) m_fgcolor=qRgb(0,0,0); m_bgcolor=qRgb(0xff,0xff,0xff); for (int i=0;ienumerator(0).keyCount();i++) - stype->addItem(metaObject()->enumerator(0).key(i)); + bstyle->addItem(metaObject()->enumerator(0).key(i)); on_generate_clicked(); view->scene()->addItem(&m_bc); - connect(stype, SIGNAL(currentIndexChanged( int )), SLOT(on_generate_clicked())); + connect(bstyle, SIGNAL(currentIndexChanged( int )), SLOT(on_generate_clicked())); connect(heightb, SIGNAL(valueChanged( int )), SLOT(on_generate_clicked())); connect(widthb, SIGNAL(valueChanged( int )), SLOT(on_generate_clicked())); connect(security, SIGNAL(valueChanged( int )), SLOT(on_generate_clicked())); @@ -73,8 +73,19 @@ void MainWindow::on_generate_clicked() m_bc.h=iheight->value(); m_bc.bc.setText(text->toPlainText()); m_bc.bc.setPrimaryMessage(primary->text()); - m_bc.bc.setSymbol(metaObject()->enumerator(0).value(stype->currentIndex())); - + m_bc.bc.setSymbol(metaObject()->enumerator(0).value(bstyle->currentIndex())); + switch(m_bc.bc.symbol()) + { + case BARCODE_MSI_PLESSEY: + m_bc.bc.setMsiExtraSymbology(msiPlessey->currentIndex()); + break; + case BARCODE_CODE39: + m_bc.bc.setCode39ExtraSymbology(code39->currentIndex()); + break; + case BARCODE_EXCODE39: + m_bc.bc.setExcode39ExtraSymbology(code39->currentIndex()); + break; + } m_bc.bc.setBorderType((Zint::QZint::BorderType)btype->currentIndex()); m_bc.bc.setBorderWidth(bwidth->value()); m_bc.bc.setHeight(heightb->value()); diff --git a/frontend_qt4/mainwindow.h b/frontend_qt4/mainwindow.h index a94b3d42..1c20acc9 100644 --- a/frontend_qt4/mainwindow.h +++ b/frontend_qt4/mainwindow.h @@ -32,78 +32,81 @@ class MainWindow : public QWidget, private Ui::mainWindow public: enum BarcodeTypes { - CODE11 = 1, - C25MATRIX = 2, - C25INTER = 3, - C25IATA = 4, - C25LOGIC = 6, - C25IND = 7, - CODE39 = 8, - EXCODE39 = 9, - EANX = 13, - EAN128 = 16, - CODABAR = 18, - CODE128 = 20, - DPLEIT = 21, - DPIDENT = 22, - CODE16K = 23, - CODE93 = 25, - FLAT = 28, - RSS14 = 29, - RSS_LTD = 30, - RSS_EXP = 31, - TELEPEN = 32, - UPCA = 34, - UPCE = 37, - POSTNET = 40, - MSI_PLESSEY = 47, - FIM = 49, - LOGMARS = 50, - PHARMA = 51, - PZN = 52, - PHARMA_TWO = 53, - PDF417 = 55, - PDF417TRUNC = 56, - MAXICODE = 57, - QRCODE = 58, - CODE128B = 60, - AUSPOST = 63, - AUSREPLY = 66, - AUSROUTE = 67, - AUSREDIRECT = 68, - ISBNX = 69, - RM4SCC = 70, - DATAMATRIX = 71, - ITF14 = 72, - NVE18 = 75, - KOREAPOST = 77, - RSS14STACK = 79, - RSS14STACK_OMNI = 80, - RSS_EXPSTACK = 81, - PLANET = 82, - MICROPDF417 = 84, - ONECODE = 85, - PLESSEY = 86, - TELEPEN_NUM = 100, - MSI_10 = 101, - MSI_10_10 = 102, - MSI_11 = 103, - MSI_11_10 = 104, - CODE39_43 = 105, - EXCODE39_43 = 106, - AZTEC = 107, - SUPER = 108, - ULTRA = 109, - EANX_CC = 110, - EAN128_CC = 111, - RSS14_CC = 112, - RSS_LTD_CC = 113, - RSS_EXP_CC = 114, - UPCA_CC = 115, - UPCE_CC = 116, - RSS14STACK_CC = 117, - RSS14_OMNI_CC = 118, - RSS_EXPSTACK_CC = 119, + CODE11 =1, + C25MATRIX =2, + C25INTER =3, + C25IATA =4, + C25LOGIC =6, + C25IND =7, + CODE39 =8, + EXCODE39 =9, + EANX =13, + EAN128 =16, + CODABAR =18, + CODE128 =20, + DPLEIT =21, + DPIDENT =22, + CODE16K =23, + CODE93 =25, + FLAT =28, + RSS14 =29, + RSS_LTD =30, + RSS_EXP =31, + TELEPEN =32, + UPCA =34, + UPCE =37, + POSTNET =40, + MSI_PLESSEY =47, + FIM =49, + LOGMARS =50, + PHARMA =51, + PZN =52, + PHARMA_TWO =53, + PDF417 =55, + PDF417TRUNC =56, + MAXICODE =57, + QRCODE =58, + CODE128B =60, + AUSPOST =63, + AUSREPLY =66, + AUSROUTE =67, + AUSREDIRECT =68, + ISBNX =69, + RM4SCC =70, + DATAMATRIX =71, + ITF14 =72, + CODABLOCKF =74, + NVE18 =75, + KOREAPOST =77, + RSS14STACK =79, + RSS14STACK_OMNI =80, + RSS_EXPSTACK =81, + PLANET =82, + MICROPDF417 =84, + ONECODE =85, + PLESSEY =86, + + /* Tbarcode 8 codes */ + KIX =90, + AZTEC =92, + DAFT =93, + ITALYPOST =94, + DPD =96, + MICROQR =97, + + /* Zint specific */ + TELEPEN_NUM =128, + CODE32 =129, + EANX_CC =130, + EAN128_CC =131, + RSS14_CC =132, + RSS_LTD_CC =133, + RSS_EXP_CC =134, + UPCA_CC =135, + UPCE_CC =136, + RSS14STACK_CC =137, + RSS14_OMNI_CC =138, + RSS_EXPSTACK_CC =139 }; public: