cmake buildsystem

This commit is contained in:
taipanromania
2008-09-18 14:44:52 +00:00
parent b6c5e74476
commit f4d73b209a
8 changed files with 133 additions and 4 deletions

View File

@ -0,0 +1,17 @@
# (c) 2008 by BogDan Vatra < bogdan@licentia.eu >
project(QZint_frontend)
include_directories(BEFORE ../backend ../backend_qt4)
set(QZint_frontend_SRCS barcodeitem.cpp main.cpp mainwindow.cpp)
QT4_WRAP_CPP(QZint_frontend_SRCS barcodeitem.h mainwindow.h)
QT4_WRAP_UI(QZint_frontend_SRCS mainWindow.ui)
add_executable(QZint_frontend ${QZint_frontend_SRCS})
add_dependencies(QZint_frontend QZint zint)
link_directories( "../backend" "../backend_qt4" )
target_link_libraries(QZint_frontend zint QZint ${QT_QTGUI_LIBRARY}
${QT_QTCORE_LIBRARY} )

View File

@ -37,7 +37,7 @@ QRectF BarcodeItem::boundingRect() const
void BarcodeItem::paint(QPainter * painter, const QStyleOptionGraphicsItem * /*option*/, QWidget * /*widget*/)
{
bc.render(*painter,boundingRect(),Zint::BareCode::IgnoreAspectRatio,scaleFactor);
bc.render(*painter,boundingRect(),Zint::QZint::IgnoreAspectRatio,scaleFactor);
}

View File

@ -18,7 +18,7 @@
#define BARCODEITEM_H
#include <QGraphicsItem>
#include <barcoderender.h>
#include <qzint.h>
/**
@author BogDan Vatra <taipan@licentia.eu>
@ -33,7 +33,7 @@ public:
void paint(QPainter * painter, const QStyleOptionGraphicsItem * option, QWidget * widget = 0);
public:
mutable Zint::BareCode bc;
mutable Zint::QZint bc;
int scaleFactor;
int w,h;
};

View File

@ -75,7 +75,7 @@ void MainWindow::on_generate_clicked()
m_bc.bc.setPrimaryMessage(primary->text());
m_bc.bc.setSymbol(metaObject()->enumerator(0).value(stype->currentIndex()));
m_bc.bc.setBorderType((Zint::BareCode::BorderType)btype->currentIndex());
m_bc.bc.setBorderType((Zint::QZint::BorderType)btype->currentIndex());
m_bc.bc.setBorderWidth(bwidth->value());
m_bc.bc.setHeight(heightb->value());
m_bc.bc.setWidth(widthb->value());