├── .gitignore ├── Doc └── pro.png ├── Exmaple ├── Exmaple.pro ├── demo │ ├── CreateProjectFileForm.cpp │ ├── CreateProjectFileForm.h │ ├── CreateProjectFileForm.ui │ ├── demo.pri │ ├── demo_airspeedwidget.cpp │ ├── demo_airspeedwidget.h │ ├── demo_airspeedwidget.ui │ ├── demo_attitudemeter.cpp │ ├── demo_attitudemeter.h │ ├── demo_attitudemeter.ui │ ├── demo_colorprogressbar.cpp │ ├── demo_colorprogressbar.h │ ├── demo_colorprogressbar.ui │ ├── demo_compasswidget.cpp │ ├── demo_compasswidget.h │ ├── demo_compasswidget.ui │ ├── demo_customcombox.cpp │ ├── demo_customcombox.h │ ├── demo_customcombox.ui │ ├── demo_drawprogressbar.cpp │ ├── demo_drawprogressbar.h │ ├── demo_drawprogressbar.ui │ ├── demo_imagebrowser.cpp │ ├── demo_imagebrowser.h │ ├── demo_imagebrowser.ui │ ├── demo_ipaddresswidget.cpp │ ├── demo_ipaddresswidget.h │ ├── demo_ipaddresswidget.ui │ ├── demo_lineedit.cpp │ ├── demo_lineedit.h │ ├── demo_lineedit.ui │ ├── demo_messagebox.cpp │ ├── demo_messagebox.h │ ├── demo_messagebox.ui │ ├── demo_msgnotify.cpp │ ├── demo_msgnotify.h │ ├── demo_msgnotify.ui │ ├── demo_navlistview.cpp │ ├── demo_navlistview.h │ ├── demo_navlistview.ui │ ├── demo_perfmon.cpp │ ├── demo_perfmon.h │ ├── demo_perfmon.ui │ ├── demo_qgauge.cpp │ ├── demo_qgauge.h │ ├── demo_qgauge.ui │ ├── demo_qmeter.cpp │ ├── demo_qmeter.h │ ├── demo_qmeter.ui │ ├── demo_rightdownmessagebox.cpp │ ├── demo_rightdownmessagebox.h │ ├── demo_rightdownmessagebox.ui │ ├── demo_roundprogressbar.cpp │ ├── demo_roundprogressbar.h │ ├── demo_roundprogressbar.ui │ ├── demo_ruler.cpp │ ├── demo_ruler.h │ ├── demo_ruler.ui │ ├── demo_speedgauge.cpp │ ├── demo_speedgauge.h │ ├── demo_speedgauge.ui │ ├── demo_speedwatch.cpp │ ├── demo_speedwatch.h │ ├── demo_speedwatch.ui │ ├── demo_splashscreen.cpp │ ├── demo_splashscreen.h │ ├── demo_splashscreen.ui │ ├── demo_startwidget.cpp │ ├── demo_startwidget.h │ ├── demo_startwidget.ui │ ├── demo_tabwidget.cpp │ ├── demo_tabwidget.h │ ├── demo_tabwidget.ui │ ├── demo_tolerancebar.cpp │ ├── demo_tolerancebar.h │ ├── demo_tolerancebar.ui │ ├── demo_waveprogress.cpp │ ├── demo_waveprogress.h │ ├── demo_waveprogress.ui │ ├── demo_zxing.cpp │ ├── demo_zxing.h │ └── demo_zxing.ui ├── examplewidget.cpp ├── examplewidget.h ├── examplewidget.ui ├── image │ ├── RightMessageBox │ │ └── title.png │ └── start │ │ └── Splashscreen.png └── main.cpp ├── LICENSE ├── LQ3rdparty ├── LQ3rdparty.pro └── QZXing │ └── QZXing │ ├── CameraImageWrapper.cpp │ ├── LQ3rdparty.pri │ ├── QZXing.pri │ ├── QZXing.pro │ ├── StdMain.h │ ├── imagehandler.cpp │ ├── inc │ ├── CameraImageWrapper.h │ ├── QZXing.h │ ├── QZXing_global.h │ ├── QZxingInc.h │ ├── QZxingIncLib.h │ └── imagehandler.h │ ├── qzxing.cpp │ └── zxing │ ├── bigint │ ├── BigInteger.cc │ ├── BigInteger.hh │ ├── BigIntegerAlgorithms.cc │ ├── BigIntegerAlgorithms.hh │ ├── BigIntegerLibrary.hh │ ├── BigIntegerUtils.cc │ ├── BigIntegerUtils.hh │ ├── BigUnsigned.cc │ ├── BigUnsigned.hh │ ├── BigUnsignedInABase.cc │ ├── BigUnsignedInABase.hh │ ├── ChangeLog │ ├── NumberlikeArray.hh │ └── README │ ├── win32 │ └── zxing │ │ ├── iconv.h │ │ ├── msvc │ │ └── stdint.h │ │ └── win_iconv.c │ └── zxing │ ├── BarcodeFormat.cpp │ ├── BarcodeFormat.h │ ├── Binarizer.cpp │ ├── Binarizer.h │ ├── BinaryBitmap.cpp │ ├── BinaryBitmap.h │ ├── ChecksumException.cpp │ ├── ChecksumException.h │ ├── DecodeHints.cpp │ ├── DecodeHints.h │ ├── Exception.cpp │ ├── Exception.h │ ├── FormatException.cpp │ ├── FormatException.h │ ├── IllegalStateException.h │ ├── InvertedLuminanceSource.cpp │ ├── InvertedLuminanceSource.h │ ├── LuminanceSource.cpp │ ├── LuminanceSource.h │ ├── MultiFormatReader.cpp │ ├── MultiFormatReader.h │ ├── NotFoundException.h │ ├── Reader.cpp │ ├── Reader.h │ ├── ReaderException.h │ ├── Result.cpp │ ├── Result.h │ ├── ResultIO.cpp │ ├── ResultPoint.cpp │ ├── ResultPoint.h │ ├── ResultPointCallback.cpp │ ├── ResultPointCallback.h │ ├── ZXing.h │ ├── aztec │ ├── AztecDetectorResult.cpp │ ├── AztecDetectorResult.h │ ├── AztecReader.cpp │ ├── AztecReader.h │ ├── decoder │ │ ├── AztecDecoder.cpp │ │ └── Decoder.h │ └── detector │ │ ├── AztecDetector.cpp │ │ └── Detector.h │ ├── common │ ├── Array.h │ ├── BitArray.cpp │ ├── BitArray.h │ ├── BitArrayIO.cpp │ ├── BitMatrix.cpp │ ├── BitMatrix.h │ ├── BitSource.cpp │ ├── BitSource.h │ ├── CharacterSetECI.cpp │ ├── CharacterSetECI.h │ ├── Counted.h │ ├── DecoderResult.cpp │ ├── DecoderResult.h │ ├── DetectorResult.cpp │ ├── DetectorResult.h │ ├── GlobalHistogramBinarizer.cpp │ ├── GlobalHistogramBinarizer.h │ ├── GreyscaleLuminanceSource.cpp │ ├── GreyscaleLuminanceSource.h │ ├── GreyscaleRotatedLuminanceSource.cpp │ ├── GreyscaleRotatedLuminanceSource.h │ ├── GridSampler.cpp │ ├── GridSampler.h │ ├── HybridBinarizer.cpp │ ├── HybridBinarizer.h │ ├── IllegalArgumentException.cpp │ ├── IllegalArgumentException.h │ ├── PerspectiveTransform.cpp │ ├── PerspectiveTransform.h │ ├── Point.h │ ├── Str.cpp │ ├── Str.h │ ├── StringUtils.cpp │ ├── StringUtils.h │ ├── detector │ │ ├── JavaMath.h │ │ ├── MathUtils.h │ │ ├── MonochromeRectangleDetector.cpp │ │ ├── MonochromeRectangleDetector.h │ │ ├── WhiteRectangleDetector.cpp │ │ └── WhiteRectangleDetector.h │ └── reedsolomon │ │ ├── GenericGF.cpp │ │ ├── GenericGF.h │ │ ├── GenericGFPoly.cpp │ │ ├── GenericGFPoly.h │ │ ├── ReedSolomonDecoder.cpp │ │ ├── ReedSolomonDecoder.h │ │ ├── ReedSolomonException.cpp │ │ └── ReedSolomonException.h │ ├── datamatrix │ ├── DataMatrixReader.cpp │ ├── DataMatrixReader.h │ ├── DataMatrixVersion.cpp │ ├── Version.h │ ├── decoder │ │ ├── BitMatrixParser.h │ │ ├── DataBlock.h │ │ ├── DataMatrixBitMatrixParser.cpp │ │ ├── DataMatrixDataBlock.cpp │ │ ├── DataMatrixDecodedBitStreamParser.cpp │ │ ├── DataMatrixDecoder.cpp │ │ ├── DecodedBitStreamParser.h │ │ └── Decoder.h │ └── detector │ │ ├── CornerPoint.h │ │ ├── DataMatrixCornerPoint.cpp │ │ ├── DataMatrixDetector.cpp │ │ ├── DataMatrixDetectorException.cpp │ │ ├── Detector.h │ │ └── DetectorException.h │ ├── multi │ ├── ByQuadrantReader.cpp │ ├── ByQuadrantReader.h │ ├── GenericMultipleBarcodeReader.cpp │ ├── GenericMultipleBarcodeReader.h │ ├── MultipleBarcodeReader.cpp │ ├── MultipleBarcodeReader.h │ └── qrcode │ │ ├── QRCodeMultiReader.cpp │ │ ├── QRCodeMultiReader.h │ │ └── detector │ │ ├── MultiDetector.cpp │ │ ├── MultiDetector.h │ │ ├── MultiFinderPatternFinder.cpp │ │ └── MultiFinderPatternFinder.h │ ├── oned │ ├── CodaBarReader.cpp │ ├── CodaBarReader.h │ ├── Code128Reader.cpp │ ├── Code128Reader.h │ ├── Code39Reader.cpp │ ├── Code39Reader.h │ ├── Code93Reader.cpp │ ├── Code93Reader.h │ ├── EAN13Reader.cpp │ ├── EAN13Reader.h │ ├── EAN8Reader.cpp │ ├── EAN8Reader.h │ ├── ITFReader.cpp │ ├── ITFReader.h │ ├── MultiFormatOneDReader.cpp │ ├── MultiFormatOneDReader.h │ ├── MultiFormatUPCEANReader.cpp │ ├── MultiFormatUPCEANReader.h │ ├── OneDReader.cpp │ ├── OneDReader.h │ ├── OneDResultPoint.cpp │ ├── OneDResultPoint.h │ ├── UPCAReader.cpp │ ├── UPCAReader.h │ ├── UPCEANReader.cpp │ ├── UPCEANReader.h │ ├── UPCEReader.cpp │ └── UPCEReader.h │ ├── pdf417 │ ├── PDF417Reader.cpp │ ├── PDF417Reader.h │ ├── decoder │ │ ├── BitMatrixParser.h │ │ ├── DecodedBitStreamParser.h │ │ ├── Decoder.h │ │ ├── PDF417BitMatrixParser.cpp │ │ ├── PDF417DecodedBitStreamParser.cpp │ │ ├── PDF417Decoder.cpp │ │ └── ec │ │ │ ├── ErrorCorrection.cpp │ │ │ ├── ErrorCorrection.h │ │ │ ├── ModulusGF.cpp │ │ │ ├── ModulusGF.h │ │ │ ├── ModulusPoly.cpp │ │ │ └── ModulusPoly.h │ └── detector │ │ ├── Detector.h │ │ ├── LinesSampler.cpp │ │ ├── LinesSampler.h │ │ └── PDF417Detector.cpp │ └── qrcode │ ├── ErrorCorrectionLevel.h │ ├── FormatInformation.h │ ├── QRCodeReader.cpp │ ├── QRCodeReader.h │ ├── QRErrorCorrectionLevel.cpp │ ├── QRFormatInformation.cpp │ ├── QRVersion.cpp │ ├── Version.h │ ├── decoder │ ├── BitMatrixParser.h │ ├── DataBlock.h │ ├── DataMask.h │ ├── DecodedBitStreamParser.h │ ├── Decoder.h │ ├── Mode.h │ ├── QRBitMatrixParser.cpp │ ├── QRDataBlock.cpp │ ├── QRDataMask.cpp │ ├── QRDecodedBitStreamParser.cpp │ ├── QRDecoder.cpp │ └── QRMode.cpp │ └── detector │ ├── AlignmentPattern.h │ ├── AlignmentPatternFinder.h │ ├── Detector.h │ ├── FinderPattern.h │ ├── FinderPatternFinder.h │ ├── FinderPatternInfo.h │ ├── QRAlignmentPattern.cpp │ ├── QRAlignmentPatternFinder.cpp │ ├── QRDetector.cpp │ ├── QRFinderPattern.cpp │ ├── QRFinderPatternFinder.cpp │ └── QRFinderPatternInfo.cpp ├── LQChart ├── LQChart.pro ├── StdMain.h ├── inc │ ├── CustomeTableView.h │ ├── LQChartInc.h │ ├── LQChartIncLib.h │ ├── lqchart.h │ └── lqchart_global.h ├── lqchart_inc.pri ├── lqchart_src.pri └── src │ ├── CustomeTableView.cpp │ ├── CustomeTableView.h │ └── lqchart.cpp ├── LQFormWidget ├── LQFormWidget.pro ├── StdMain.h ├── inc │ ├── LQFormWidgetInc.h │ ├── LQFormWidgetIncLib.h │ ├── cmysplashscreen.h │ ├── drawprogressbar │ │ └── drawprogressbar.h │ ├── gradientcombobox.h │ ├── ipaddresswidget.h │ ├── lqformwidget.h │ ├── lqformwidget_global.h │ ├── lqstartwidget.h │ ├── messageWidget │ │ ├── messagetitle.h │ │ ├── messagewidget.h │ │ └── readme.txt │ ├── msgNotify │ │ ├── notify.h │ │ └── notifymanager.h │ ├── msgboxbase.h │ ├── navlistview.h │ ├── nbaseswitchbutton.h │ ├── searchlineedit.h │ ├── tabWidget │ │ ├── customtabstyle.h │ │ └── mytabwidget.h │ └── tolerancebar.h ├── lqformwidget_inc.pri ├── lqformwidget_src.pri └── src │ ├── cmysplashscreen.cpp │ ├── drawprogressbar │ └── drawprogressbar.cpp │ ├── gradientcombobox.cpp │ ├── ipaddresswidget.cpp │ ├── lqformwidget.cpp │ ├── lqstartwidget.cpp │ ├── messageWidget │ ├── 2016-11-11_23-37-42.png │ ├── messagetitle.cpp │ ├── messagewidget.cpp │ └── readme.txt │ ├── msgNotify │ ├── notify.cpp │ └── notifymanager.cpp │ ├── msgboxbase.cpp │ ├── navlistview.cpp │ ├── nbaseswitchbutton.cpp │ ├── searchlineedit.cpp │ ├── tabWidget │ ├── customtabstyle.cpp │ └── mytabwidget.cpp │ └── tolerancebar.cpp ├── LQFramKit.pro ├── LQGlobal.pri ├── LQInclude └── IncludeGlobal │ └── GlobalInc.h ├── LQInstrumentation ├── LQInstrumentation.pro ├── StdMain.h ├── inc │ ├── LQInstrumenttationInc.h │ ├── LQInstrumenttationIncLib.h │ ├── QRoundProgressBar.h │ ├── airspeedgaugewidget.h │ ├── attitudemeter.h │ ├── colorprogressbar.h │ ├── compasswidget.h │ ├── lqinstrumentation.h │ ├── lqinstrumentation_global.h │ ├── lwaveupprogress.h │ ├── myspeedwatch.h │ ├── qcgaugewidget.h │ ├── qgauge.h │ ├── qmeter.h │ └── speedgaugewidget.h ├── lqinstrumentation_inc.pri ├── lqinstrumentation_src.pri └── src │ ├── QRoundProgressBar.cpp │ ├── airspeedgaugewidget.cpp │ ├── attitudemeter.cpp │ ├── colorprogressbar.cpp │ ├── compasswidget.cpp │ ├── lqinstrumentation.cpp │ ├── lwaveupprogress.cpp │ ├── myspeedwatch.cpp │ ├── qcgaugewidget.cpp │ ├── qgauge.cpp │ ├── qgaugedrawfunctions.cpp │ ├── qmeter.cpp │ ├── qmeterdrawfunctions.cpp │ └── speedgaugewidget.cpp ├── LQMisc ├── Global │ ├── GlobalDef.h │ ├── GlobalInclude.h │ ├── GlobalStruct.h │ ├── GlobalVar.cpp │ └── GlobalVar.h ├── IncludeMisc │ └── LQString │ │ ├── LQStringInc.h │ │ ├── LQStringIncLib.h │ │ ├── LQStringLib.h │ │ ├── LQStringUtil.h │ │ └── LQString_Export.h ├── LQMisc.pri ├── LQMisc.pro └── LQString │ ├── Global │ ├── GlobalDef.h │ ├── GlobalInclude.h │ ├── GlobalStruct.h │ ├── GlobalVar.cpp │ └── GlobalVar.h │ ├── LQString.pro │ ├── LQStringUtil.cpp │ └── StdMain.h ├── LQRes ├── ExampleImage.qrc ├── FormWidgetimage.qrc ├── image │ ├── RightMessageBox │ │ └── title.png │ ├── config │ │ └── config.xml │ ├── intiloading.png │ ├── message.css │ ├── message.png │ ├── search.png │ ├── search_dark.png │ └── start │ │ └── Splashscreen.png ├── message.css ├── search.png └── search_dark.png ├── LQTools ├── LQTools.pro ├── inc │ ├── LQToolsInc.h │ ├── LQToolsIncLib.h │ ├── LQimagehandler.h │ ├── cruler.h │ ├── lqtools_global.h │ └── perfmon.h ├── lqtools_inc.pri ├── lqtools_src.pri └── src │ ├── LQimagehandler.cpp │ ├── cruler.cpp │ └── perfmon.cpp ├── LQ_LibForAdditions.pri ├── README.md ├── README_Demo.md ├── README_zh.md ├── Scripts ├── l_clear.sh └── w_clear.bat ├── doc ├── project_frame.bmml └── project_frame.png ├── screen ├── ColorProgress.png ├── Splashscreen.png ├── attitudemeter.png ├── bugs │ └── build_error_tools.png ├── build_setting.png ├── customComBox.png ├── drawprogressbar.png ├── gauge.gif ├── gauge.png ├── homeWidget.png ├── ipAddress.png ├── linux │ └── Screenshot_2018-08-23.png ├── logo.png ├── messagebox.png ├── meter.gif ├── meter.png ├── msgNotify.png ├── myCode.png ├── navlistview.png ├── nettool.png ├── perfmon.png ├── proCreate.png ├── qrcode_for_devstone.png ├── qzxing.png ├── roundPorgressbar.png ├── ruler.png ├── search.png ├── speed1.png ├── speed2.png ├── speedwatch.gif ├── speedwatch2.png ├── start.png ├── switch.png ├── tabwidget.png ├── toleranceBar.png └── wavePro.gif └── test.jpg /.gitignore: -------------------------------------------------------------------------------- 1 | #pro.user 2 | LQFramKit.pro.user 3 | bin/* 4 | Bin/* 5 | build_/* 6 | tempFiles/* 7 | *.Debug 8 | *.Release 9 | *Makefile 10 | *.o 11 | *moc_*.cpp 12 | *ui_*.h 13 | 14 | *.lib 15 | *.dll 16 | *.a 17 | *.so 18 | *.exe 19 | -------------------------------------------------------------------------------- /Doc/pro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/Doc/pro.png -------------------------------------------------------------------------------- /Exmaple/demo/CreateProjectFileForm.h: -------------------------------------------------------------------------------- 1 | #ifndef CREATEPROJECTFILEFORM_H 2 | #define CREATEPROJECTFILEFORM_H 3 | 4 | #include 5 | #include 6 | 7 | namespace Ui { 8 | class CreateProjectFileForm; 9 | } 10 | 11 | class CreateProjectFileForm : public QWidget 12 | { 13 | Q_OBJECT 14 | 15 | public: 16 | explicit CreateProjectFileForm(QWidget *parent = 0); 17 | ~CreateProjectFileForm(); 18 | 19 | private: 20 | void initForm(); 21 | 22 | bool createFile(const QString &strName, const QString &strContext); 23 | 24 | QString getCommonHeadText(const QString &strName); 25 | 26 | QString getCommonEndText(const QString &strName); 27 | 28 | QString getCommonContext(const QString &strName); 29 | 30 | QString getStdMainContext(); 31 | 32 | QString getProFileContext(const QString &strProName); 33 | 34 | QString getGlobalIncludeContext(); 35 | 36 | QString getExportContext(); 37 | QString getIncContext(); 38 | QString getIncLibContext(); 39 | 40 | private slots: 41 | void on_pbnCreate_clicked(); 42 | 43 | private: 44 | Ui::CreateProjectFileForm *ui; 45 | 46 | QMapm_FileMap; 47 | QString m_strProName; 48 | QString m_strLibDefine; 49 | }; 50 | 51 | #endif // CREATEPROJECTFILEFORM_H 52 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_airspeedwidget.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | 3 | #include "demo_airspeedwidget.h" 4 | #include "ui_demo_airspeedwidget.h" 5 | 6 | Demo_AirSpeedWidget::Demo_AirSpeedWidget(const QString &title, 7 | QWidget *parent) : 8 | QDialog(parent), 9 | ui(new Ui::Demo_AirSpeedWidget) 10 | { 11 | ui->setupUi(this); 12 | 13 | this->setWindowTitle(title); 14 | } 15 | 16 | Demo_AirSpeedWidget::~Demo_AirSpeedWidget() 17 | { 18 | delete ui; 19 | } 20 | 21 | void Demo_AirSpeedWidget::on_horizontalSlider_valueChanged(int value) 22 | { 23 | ui->widget->setCurrentValue(value); 24 | } 25 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_airspeedwidget.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_AIRSPEEDWIDGET_H 2 | #define DEMO_AIRSPEEDWIDGET_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_AirSpeedWidget; 8 | } 9 | 10 | class Demo_AirSpeedWidget : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_AirSpeedWidget(const QString &title ="", 16 | QWidget *parent = 0); 17 | ~Demo_AirSpeedWidget(); 18 | 19 | private slots: 20 | void on_horizontalSlider_valueChanged(int value); 21 | 22 | private: 23 | Ui::Demo_AirSpeedWidget *ui; 24 | }; 25 | 26 | #endif // DEMO_AIRSPEEDWIDGET_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_airspeedwidget.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_AirSpeedWidget 4 | 5 | 6 | 7 | 0 8 | 0 9 | 400 10 | 300 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | Qt::Horizontal 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | AirSpeedGaugeWidget 32 | QWidget 33 |
airspeedgaugewidget.h
34 | 1 35 |
36 |
37 | 38 | 39 |
40 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_attitudemeter.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | #include "demo_attitudemeter.h" 3 | #include "ui_demo_attitudemeter.h" 4 | 5 | Demo_AttitudeMeter::Demo_AttitudeMeter(const QString &title, QWidget *parent) : 6 | QWidget(parent), 7 | ui(new Ui::Demo_AttitudeMeter) 8 | { 9 | ui->setupUi(this); 10 | 11 | this->setWindowTitle(title); 12 | 13 | ui->horizontalSlider->setMinimum(-100); 14 | ui->horizontalSlider->setMaximum(100); 15 | ui->horizontalSlider->setSingleStep(1); 16 | ui->horizontalSlider->setValue(0); 17 | ui->horizontalSlider->setPageStep(10); 18 | 19 | ui->verticalSlider->setMinimum(-100); 20 | ui->verticalSlider->setMaximum(100); 21 | ui->verticalSlider->setSingleStep(1); 22 | ui->verticalSlider->setValue(0); 23 | ui->verticalSlider->setPageStep(10); 24 | } 25 | 26 | Demo_AttitudeMeter::~Demo_AttitudeMeter() 27 | { 28 | delete ui; 29 | } 30 | 31 | void Demo_AttitudeMeter::on_horizontalSlider_valueChanged(int value) 32 | { 33 | ui->widget->setCurrentValue(value); 34 | } 35 | 36 | void Demo_AttitudeMeter::on_verticalSlider_valueChanged(int value) 37 | { 38 | ui->widget->setCurrentPitch(value); 39 | ui->label->setText(QString::number(value)); 40 | } 41 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_attitudemeter.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_ATTITUDEMETER_H 2 | #define DEMO_ATTITUDEMETER_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_AttitudeMeter; 8 | } 9 | 10 | class Demo_AttitudeMeter : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_AttitudeMeter(const QString &title = "",QWidget *parent = 0); 16 | ~Demo_AttitudeMeter(); 17 | 18 | private slots: 19 | void on_horizontalSlider_valueChanged(int value); 20 | 21 | void on_verticalSlider_valueChanged(int value); 22 | 23 | private: 24 | Ui::Demo_AttitudeMeter *ui; 25 | }; 26 | 27 | #endif // DEMO_ATTITUDEMETER_H 28 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_attitudemeter.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_AttitudeMeter 4 | 5 | 6 | 7 | 0 8 | 0 9 | 400 10 | 300 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | Qt::Vertical 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | Qt::Horizontal 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | AttitudeMeter 46 | QWidget 47 |
attitudemeter.h
48 | 1 49 |
50 |
51 | 52 | 53 |
54 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_colorprogressbar.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_COLORPROGRESSBAR_H 2 | #define DEMO_COLORPROGRESSBAR_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_ColorProgressBar; 8 | } 9 | 10 | class Demo_ColorProgressBar : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_ColorProgressBar(const QString &title ="", 16 | QWidget *parent = 0); 17 | ~Demo_ColorProgressBar(); 18 | private: 19 | void init(); 20 | 21 | Q_SIGNALS: 22 | 23 | private Q_SLOTS: 24 | 25 | void on_horizontalSlider_3_valueChanged(int value); 26 | 27 | private: 28 | 29 | private: 30 | Ui::Demo_ColorProgressBar *ui; 31 | }; 32 | 33 | #endif // DEMO_COLORPROGRESSBAR_H 34 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_colorprogressbar.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_ColorProgressBar 4 | 5 | 6 | 7 | 0 8 | 0 9 | 491 10 | 173 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | Qt::Horizontal 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | ColorProgressBar 38 | QWidget 39 |
colorprogressbar.h
40 | 1 41 |
42 |
43 | 44 | 45 |
46 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_compasswidget.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | #include "demo_compasswidget.h" 3 | #include "ui_demo_compasswidget.h" 4 | 5 | Demo_compassWidget::Demo_compassWidget(const QString &title, QWidget *parent) : 6 | QWidget(parent), 7 | ui(new Ui::Demo_compassWidget) 8 | { 9 | ui->setupUi(this); 10 | 11 | this->setWindowTitle(title); 12 | 13 | ui->horizontalSlider->setRange(0,360); 14 | ui->horizontalSlider->setValue(0); 15 | ui->horizontalSlider->setSingleStep(10); 16 | } 17 | 18 | Demo_compassWidget::~Demo_compassWidget() 19 | { 20 | delete ui; 21 | } 22 | 23 | void Demo_compassWidget::on_horizontalSlider_sliderMoved(int position) 24 | { 25 | ui->widget->setCurrentValue(position); 26 | } 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_compasswidget.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_COMPASSWIDGET_H 2 | #define DEMO_COMPASSWIDGET_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_compassWidget; 8 | } 9 | 10 | class Demo_compassWidget : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_compassWidget(const QString &title = "", 16 | QWidget *parent = 0); 17 | ~Demo_compassWidget(); 18 | 19 | private slots: 20 | void on_horizontalSlider_sliderMoved(int position); 21 | 22 | private: 23 | Ui::Demo_compassWidget *ui; 24 | }; 25 | 26 | #endif // DEMO_COMPASSWIDGET_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_compasswidget.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_compassWidget 4 | 5 | 6 | 7 | 0 8 | 0 9 | 392 10 | 330 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | Qt::Horizontal 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | CompassWidget 32 | QWidget 33 |
compasswidget.h
34 | 1 35 |
36 |
37 | 38 | 39 |
40 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_customcombox.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_customcombox.h" 4 | #include "ui_demo_customcombox.h" 5 | 6 | Demo_CustomComBox::Demo_CustomComBox(const QString &title, 7 | QWidget *parent) : 8 | QDialog(parent), 9 | ui(new Ui::Demo_CustomComBox) 10 | { 11 | ui->setupUi(this); 12 | 13 | setWindowTitle(title); 14 | } 15 | 16 | Demo_CustomComBox::~Demo_CustomComBox() 17 | { 18 | delete ui; 19 | } 20 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_customcombox.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_CUSTOMCOMBOX_H 2 | #define DEMO_CUSTOMCOMBOX_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_CustomComBox; 8 | } 9 | 10 | class Demo_CustomComBox : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_CustomComBox(const QString &title, 16 | QWidget *parent = 0); 17 | ~Demo_CustomComBox(); 18 | 19 | private: 20 | Ui::Demo_CustomComBox *ui; 21 | }; 22 | 23 | #endif // DEMO_CUSTOMCOMBOX_H 24 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_customcombox.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_CustomComBox 4 | 5 | 6 | 7 | 0 8 | 0 9 | 289 10 | 114 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 0 22 | 30 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | GradientComboBox 32 | QComboBox 33 |
gradientcombobox.h
34 |
35 |
36 | 37 | 38 |
39 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_drawprogressbar.cpp: -------------------------------------------------------------------------------- 1 | #include "demo_drawprogressbar.h" 2 | #include "ui_demo_drawprogressbar.h" 3 | 4 | Demo_DrawProgressbar::Demo_DrawProgressbar(const QString &title, 5 | QWidget *parent) : 6 | QDialog(parent), 7 | ui(new Ui::Demo_DrawProgressbar) 8 | { 9 | ui->setupUi(this); 10 | 11 | this->setWindowTitle (title); 12 | 13 | ui->widget->setValue (ui->lineEdit->text ().toInt ()); 14 | } 15 | 16 | Demo_DrawProgressbar::~Demo_DrawProgressbar() 17 | { 18 | delete ui; 19 | } 20 | 21 | void Demo_DrawProgressbar::on_pushButton_clicked() 22 | { 23 | int value = ui->lineEdit->text ().toInt (); 24 | ui->widget->setValue (value); 25 | } 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_drawprogressbar.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_DRAWPROGRESSBAR_H 2 | #define DEMO_DRAWPROGRESSBAR_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_DrawProgressbar; 8 | } 9 | 10 | class Demo_DrawProgressbar : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_DrawProgressbar(const QString &title = "", 16 | QWidget *parent = 0); 17 | ~Demo_DrawProgressbar(); 18 | 19 | private slots: 20 | void on_pushButton_clicked(); 21 | 22 | private: 23 | Ui::Demo_DrawProgressbar *ui; 24 | }; 25 | 26 | #endif // DEMO_DRAWPROGRESSBAR_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_imagebrowser.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_IMAGEBROWSER_H 2 | #define DEMO_IMAGEBROWSER_H 3 | 4 | #include 5 | 6 | class LQImageHandler; 7 | 8 | namespace Ui { 9 | class Demo_ImageBrowser; 10 | } 11 | 12 | class Demo_ImageBrowser : public QDialog 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | explicit Demo_ImageBrowser(const QString &title, 18 | QWidget *parent = 0); 19 | ~Demo_ImageBrowser(); 20 | 21 | void setPixmap(const QPixmap &pixmap); 22 | 23 | protected: 24 | virtual void resizeEvent(QResizeEvent *event); 25 | 26 | private Q_SLOTS: 27 | void openButtonClicked(); 28 | 29 | void originalSizeButtonClicked(bool checked); 30 | 31 | void zoomInButtonClicked(); 32 | 33 | void zoomOutButtonClicked(); 34 | 35 | void clockwise90ButtonClicked(); 36 | 37 | void anticlockwise90ButtonClicked(); 38 | 39 | void slotPercentageChanged(double percentage); 40 | 41 | private: 42 | Ui::Demo_ImageBrowser *ui; 43 | 44 | QPixmap m_pixmap; 45 | 46 | LQImageHandler *m_pImageHandler; 47 | }; 48 | 49 | #endif // DEMO_IMAGEBROWSER_H 50 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_ipaddresswidget.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_ipaddresswidget.h" 4 | #include "ui_demo_ipaddresswidget.h" 5 | 6 | #include 7 | 8 | Demo_IpAddressWidget::Demo_IpAddressWidget(const QString &title, QWidget *parent) : 9 | QDialog(parent), 10 | ui(new Ui::Demo_IpAddressWidget) 11 | { 12 | ui->setupUi(this); 13 | 14 | this->setWindowTitle (title); 15 | } 16 | 17 | Demo_IpAddressWidget::~Demo_IpAddressWidget() 18 | { 19 | delete ui; 20 | } 21 | 22 | void Demo_IpAddressWidget::on_pushButton_clicked() 23 | { 24 | QString ip = ui->widget->getIpAddress (); 25 | if (ip.isEmpty ()) 26 | { 27 | QMessageBox::information( this, tr("Error"), tr("The IP address is illegal") ); 28 | }else 29 | { 30 | QMessageBox::information(this, tr("IP Address"), ip); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_ipaddresswidget.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_IPADDRESSWIDGET_H 2 | #define DEMO_IPADDRESSWIDGET_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_IpAddressWidget; 8 | } 9 | 10 | class Demo_IpAddressWidget : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_IpAddressWidget(const QString &title ="" 16 | ,QWidget *parent = 0); 17 | ~Demo_IpAddressWidget(); 18 | 19 | private slots: 20 | void on_pushButton_clicked(); 21 | 22 | private: 23 | Ui::Demo_IpAddressWidget *ui; 24 | }; 25 | 26 | #endif // DEMO_IPADDRESSWIDGET_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_ipaddresswidget.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_IpAddressWidget 4 | 5 | 6 | 7 | 0 8 | 0 9 | 341 10 | 98 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 获取IP地址 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | IpAddressWidget 32 | QWidget 33 |
ipaddresswidget.h
34 | 1 35 |
36 |
37 | 38 | 39 |
40 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_lineedit.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_lineedit.h" 4 | #include "ui_demo_lineedit.h" 5 | 6 | Demo_lineEdit::Demo_lineEdit(const QString &title, QWidget *parent) : 7 | QWidget(parent), 8 | ui(new Ui::Demo_lineEdit) 9 | { 10 | ui->setupUi(this); 11 | 12 | this->setWindowTitle(title); 13 | 14 | this->setFocusPolicy (Qt::ClickFocus); 15 | 16 | connect(ui->lineEdit,SIGNAL(signalSearchContent(QString)), 17 | this,SIGNAL(signalSearchContent(QString))); 18 | } 19 | 20 | Demo_lineEdit::~Demo_lineEdit() 21 | { 22 | delete ui; 23 | } 24 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_lineedit.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_LINEEDIT_H 2 | #define DEMO_LINEEDIT_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_lineEdit; 8 | } 9 | 10 | class Demo_lineEdit : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_lineEdit(const QString &title ="", 16 | QWidget *parent = 0); 17 | ~Demo_lineEdit(); 18 | 19 | Q_SIGNALS: 20 | void signalSearchContent(const QString&); 21 | 22 | private: 23 | Ui::Demo_lineEdit *ui; 24 | }; 25 | 26 | #endif // DEMO_LINEEDIT_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_lineedit.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_lineEdit 4 | 5 | 6 | 7 | 0 8 | 0 9 | 394 10 | 61 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 21 | 0 22 | 30 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | SearchLineEdit 32 | QLineEdit 33 |
searchlineedit.h
34 |
35 |
36 | 37 | 38 |
39 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_messagebox.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_messagebox.h" 4 | #include "ui_demo_messagebox.h" 5 | 6 | 7 | 8 | Demo_MessageBox::Demo_MessageBox(const QString &title, 9 | QWidget *parent) : 10 | QDialog(parent), 11 | ui(new Ui::Demo_MessageBox) 12 | { 13 | ui->setupUi(this); 14 | 15 | setWindowTitle (title); 16 | 17 | m_pMsgBox = new MsgBoxBase; 18 | } 19 | 20 | Demo_MessageBox::~Demo_MessageBox() 21 | { 22 | delete ui; 23 | } 24 | 25 | void Demo_MessageBox::on_pushButton_clicked() 26 | { 27 | m_pMsgBox->showMessageError ("这是一个错误消息框"); 28 | } 29 | 30 | void Demo_MessageBox::on_pushButton_2_clicked() 31 | { 32 | int ret = m_pMsgBox->showMessageQuestion ("您是否要?"); 33 | if (ret) 34 | m_pMsgBox->showMessageInfo ("你选择了要"); 35 | else 36 | m_pMsgBox->showMessageInfo ("您选择了不要!"); 37 | } 38 | 39 | void Demo_MessageBox::on_pushButton_3_clicked() 40 | { 41 | m_pMsgBox->showMessageInfo ("你今天的运气很好,适合出门!"); 42 | } 43 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_messagebox.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_MESSAGEBOX_H 2 | #define DEMO_MESSAGEBOX_H 3 | 4 | #include 5 | 6 | class MsgBoxBase; 7 | 8 | namespace Ui { 9 | class Demo_MessageBox; 10 | } 11 | 12 | class Demo_MessageBox : public QDialog 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | explicit Demo_MessageBox(const QString &title, 18 | QWidget *parent = 0); 19 | ~Demo_MessageBox(); 20 | 21 | private slots: 22 | void on_pushButton_clicked(); 23 | 24 | void on_pushButton_2_clicked(); 25 | 26 | void on_pushButton_3_clicked(); 27 | 28 | private: 29 | Ui::Demo_MessageBox *ui; 30 | 31 | MsgBoxBase *m_pMsgBox; 32 | }; 33 | 34 | #endif // DEMO_MESSAGEBOX_H 35 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_msgnotify.cpp: -------------------------------------------------------------------------------- 1 | #include "demo_msgnotify.h" 2 | #include "ui_demo_msgnotify.h" 3 | 4 | #include "msgNotify/notifymanager.h" 5 | 6 | Demo_MsgNotify::Demo_MsgNotify(const QString &title, QWidget *parent) : 7 | QWidget(parent), 8 | ui(new Ui::Demo_MsgNotify) 9 | { 10 | ui->setupUi(this); 11 | 12 | this->setWindowTitle(title); 13 | 14 | m_mang = new NotifyManager(this); 15 | } 16 | 17 | Demo_MsgNotify::~Demo_MsgNotify() 18 | { 19 | delete ui; 20 | } 21 | 22 | void Demo_MsgNotify::on_pushButton_clicked() 23 | { 24 | m_mang->notify("新消息","你中了800W大奖", 25 | ":/image/message.png", 26 | "https://github.com/kevinlq"); 27 | } 28 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_msgnotify.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_MSGNOTIFY_H 2 | #define DEMO_MSGNOTIFY_H 3 | 4 | #include 5 | class NotifyManager; 6 | 7 | namespace Ui { 8 | class Demo_MsgNotify; 9 | } 10 | 11 | class Demo_MsgNotify : public QWidget 12 | { 13 | Q_OBJECT 14 | 15 | public: 16 | explicit Demo_MsgNotify(const QString &title = "",QWidget *parent = 0); 17 | ~Demo_MsgNotify(); 18 | 19 | private slots: 20 | void on_pushButton_clicked(); 21 | 22 | private: 23 | Ui::Demo_MsgNotify *ui; 24 | NotifyManager *m_mang; 25 | }; 26 | 27 | #endif // DEMO_MSGNOTIFY_H 28 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_msgnotify.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_MsgNotify 4 | 5 | 6 | 7 | 0 8 | 0 9 | 246 10 | 142 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 80 20 | 60 21 | 75 22 | 31 23 | 24 | 25 | 26 | 消息弹窗 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_navlistview.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_NAVLISTVIEW_H 2 | #define DEMO_NAVLISTVIEW_H 3 | 4 | #include 5 | #include 6 | 7 | namespace Ui { 8 | class Demo_NavListView; 9 | } 10 | 11 | class Demo_NavListView : public QWidget 12 | { 13 | Q_OBJECT 14 | 15 | public: 16 | explicit Demo_NavListView(const QString &title = "",QWidget *parent = 0); 17 | ~Demo_NavListView(); 18 | 19 | private: 20 | void initForm(); 21 | 22 | private: 23 | Ui::Demo_NavListView *ui; 24 | }; 25 | 26 | #endif // DEMO_NAVLISTVIEW_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_navlistview.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_NavListView 4 | 5 | 6 | 7 | 0 8 | 0 9 | 743 10 | 562 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | NavListView 37 | QListView 38 |
navlistview.h
39 |
40 |
41 | 42 | 43 |
44 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_perfmon.cpp: -------------------------------------------------------------------------------- 1 | #include "../LQTools/inc/LQToolsIncLib.h" 2 | 3 | #include "demo_perfmon.h" 4 | #include "ui_demo_perfmon.h" 5 | 6 | #include 7 | 8 | 9 | #define CHANNEL_COUNT 2 10 | 11 | Demo_PerfMon::Demo_PerfMon(const QString &title, QWidget *parent) : 12 | QDialog(parent), 13 | ui(new Ui::Demo_PerfMon) 14 | { 15 | ui->setupUi(this); 16 | 17 | this->init (); 18 | 19 | this->setWindowTitle (title); 20 | } 21 | 22 | Demo_PerfMon::~Demo_PerfMon() 23 | { 24 | delete ui; 25 | } 26 | 27 | void Demo_PerfMon::init() 28 | { 29 | m_pUpdateTimer = new QTimer(this); 30 | m_pUpdateTimer->setInterval (200); 31 | 32 | m_pPerfMon = new PerfMon(this); 33 | 34 | ui->verticalLayout->addWidget (m_pPerfMon); 35 | 36 | connect (m_pUpdateTimer,SIGNAL(timeout()), 37 | this,SLOT(slotUpdateData())); 38 | m_pUpdateTimer->start (); 39 | 40 | m_pPerfMon->setChannelCount (CHANNEL_COUNT); 41 | m_pPerfMon->setChannelColor (0,Qt::red); 42 | m_pPerfMon->setChannelColor (1,Qt::green); 43 | } 44 | 45 | void Demo_PerfMon::slotUpdateData() 46 | { 47 | for(int cIndex = 0;cIndex < CHANNEL_COUNT;cIndex++) 48 | { 49 | m_pPerfMon->addChannelData(cIndex,qrand()%100); 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_perfmon.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_PERFMON_H 2 | #define DEMO_PERFMON_H 3 | 4 | #include 5 | 6 | class QTimer; 7 | class PerfMon; 8 | 9 | namespace Ui { 10 | class Demo_PerfMon; 11 | } 12 | 13 | class Demo_PerfMon : public QDialog 14 | { 15 | Q_OBJECT 16 | 17 | public: 18 | explicit Demo_PerfMon(const QString &title,QWidget *parent = 0); 19 | ~Demo_PerfMon(); 20 | 21 | private: 22 | void init(); 23 | 24 | private Q_SLOTS: 25 | void slotUpdateData(); 26 | 27 | private: 28 | Ui::Demo_PerfMon *ui; 29 | 30 | QTimer *m_pUpdateTimer; 31 | 32 | PerfMon *m_pPerfMon; 33 | }; 34 | 35 | #endif // DEMO_PERFMON_H 36 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_perfmon.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_PerfMon 4 | 5 | 6 | 7 | 0 8 | 0 9 | 379 10 | 315 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_qgauge.cpp: -------------------------------------------------------------------------------- 1 | #include "demo_qgauge.h" 2 | #include "ui_demo_qgauge.h" 3 | 4 | Demo_qgauge::Demo_qgauge(const QString &title, QWidget *parent) : 5 | QWidget(parent), 6 | ui(new Ui::Demo_qgauge) 7 | { 8 | ui->setupUi(this); 9 | this->setWindowTitle(title); 10 | 11 | ui->horizontalSlider->setRange(0,100); 12 | } 13 | 14 | Demo_qgauge::~Demo_qgauge() 15 | { 16 | delete ui; 17 | } 18 | 19 | void Demo_qgauge::on_horizontalSlider_sliderMoved(int position) 20 | { 21 | ui->widget->setValue(position); 22 | } 23 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_qgauge.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_QGAUGE_H 2 | #define DEMO_QGAUGE_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_qgauge; 8 | } 9 | 10 | class Demo_qgauge : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_qgauge(const QString &title ="", 16 | QWidget *parent = 0); 17 | ~Demo_qgauge(); 18 | 19 | private slots: 20 | void on_horizontalSlider_sliderMoved(int position); 21 | 22 | private: 23 | Ui::Demo_qgauge *ui; 24 | }; 25 | 26 | #endif // DEMO_QGAUGE_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_qgauge.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_qgauge 4 | 5 | 6 | 7 | 0 8 | 0 9 | 339 10 | 303 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | Qt::Horizontal 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | QGauge 36 | QWidget 37 |
qgauge.h
38 | 1 39 |
40 |
41 | 42 | 43 |
44 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_qmeter.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | 3 | #include "demo_qmeter.h" 4 | #include "ui_demo_qmeter.h" 5 | 6 | Demo_qmeter::Demo_qmeter(const QString &title, QWidget *parent) : 7 | QWidget(parent), 8 | ui(new Ui::Demo_qmeter) 9 | { 10 | ui->setupUi(this); 11 | 12 | this->setWindowTitle(title); 13 | 14 | ui->horizontalSlider->setRange(0,100); 15 | } 16 | 17 | Demo_qmeter::~Demo_qmeter() 18 | { 19 | delete ui; 20 | } 21 | 22 | void Demo_qmeter::on_horizontalSlider_sliderMoved(int position) 23 | { 24 | ui->widget->setValue(position); 25 | } 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_qmeter.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_QMETER_H 2 | #define DEMO_QMETER_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_qmeter; 8 | } 9 | 10 | class Demo_qmeter : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_qmeter(const QString &title = "", 16 | QWidget *parent = 0); 17 | ~Demo_qmeter(); 18 | 19 | private slots: 20 | void on_horizontalSlider_sliderMoved(int position); 21 | 22 | private: 23 | Ui::Demo_qmeter *ui; 24 | }; 25 | 26 | #endif // DEMO_QMETER_H 27 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_qmeter.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_qmeter 4 | 5 | 6 | 7 | 0 8 | 0 9 | 387 10 | 310 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | Qt::Horizontal 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | QMeter 32 | QWidget 33 |
qmeter.h
34 | 1 35 |
36 |
37 | 38 | 39 |
40 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_rightdownmessagebox.cpp: -------------------------------------------------------------------------------- 1 | #include "demo_rightdownmessagebox.h" 2 | #include "ui_demo_rightdownmessagebox.h" 3 | 4 | #include "messageWidget/messagewidget.h" 5 | 6 | Demo_RightDownMessageBox::Demo_RightDownMessageBox(const QString &title, QWidget *parent) : 7 | QDialog(parent), 8 | ui(new Ui::Demo_RightDownMessageBox) 9 | { 10 | ui->setupUi(this); 11 | 12 | setWindowTitle (title); 13 | 14 | m_pMessageBox = new MessageWidget; 15 | } 16 | 17 | Demo_RightDownMessageBox::~Demo_RightDownMessageBox() 18 | { 19 | delete ui; 20 | 21 | m_pMessageBox->deleteLater (); 22 | m_pMessageBox = Q_NULLPTR; 23 | } 24 | 25 | void Demo_RightDownMessageBox::on_pushButton_clicked() 26 | { 27 | QString title,content; 28 | 29 | if( (!ui->lineEdit->text ().isEmpty ()) && 30 | (!ui->lineEdit_2->text ().isEmpty ())) 31 | { 32 | title = ui->lineEdit->text (); 33 | content = ui->lineEdit_2->text (); 34 | } 35 | m_pMessageBox->showMsg (":/image/RightMessageBox/title.png",title,content); 36 | } 37 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_rightdownmessagebox.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_RIGHTDOWNMESSAGEBOX_H 2 | #define DEMO_RIGHTDOWNMESSAGEBOX_H 3 | 4 | #include 5 | 6 | class MessageWidget; 7 | 8 | namespace Ui { 9 | class Demo_RightDownMessageBox; 10 | } 11 | 12 | class Demo_RightDownMessageBox : public QDialog 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | explicit Demo_RightDownMessageBox(const QString &title = "", 18 | QWidget *parent = 0); 19 | ~Demo_RightDownMessageBox(); 20 | 21 | private slots: 22 | void on_pushButton_clicked(); 23 | 24 | private: 25 | Ui::Demo_RightDownMessageBox *ui; 26 | 27 | MessageWidget *m_pMessageBox; 28 | }; 29 | 30 | #endif // DEMO_RIGHTDOWNMESSAGEBOX_H 31 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_roundprogressbar.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_ROUNDPROGRESSBAR_H 2 | #define DEMO_ROUNDPROGRESSBAR_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_RoundProgressBar; 8 | } 9 | 10 | class Demo_RoundProgressBar : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_RoundProgressBar(const QString &title = "", 16 | QWidget *parent = 0); 17 | ~Demo_RoundProgressBar(); 18 | 19 | private: 20 | void init(); 21 | 22 | Q_SIGNALS: 23 | 24 | private Q_SLOTS: 25 | 26 | private: 27 | void connectToSlider(class QRoundProgressBar* bar); 28 | 29 | private: 30 | Ui::Demo_RoundProgressBar *ui; 31 | }; 32 | 33 | #endif // DEMO_ROUNDPROGRESSBAR_H 34 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_ruler.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_RULER_H 2 | #define DEMO_RULER_H 3 | 4 | #include 5 | 6 | class QAction; 7 | 8 | namespace Ui { 9 | class Demo_Ruler; 10 | } 11 | 12 | class Demo_Ruler : public QDialog 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | explicit Demo_Ruler(const QString &title = "", 18 | QWidget *parent = 0); 19 | ~Demo_Ruler(); 20 | 21 | private: 22 | void init(); 23 | 24 | private Q_SLOTS: 25 | void slotOnMove(const QPoint &p); 26 | 27 | void slotOnOrn(); 28 | 29 | void slotOnAlign(); 30 | 31 | protected: 32 | void keyReleaseEvent (QKeyEvent *e); 33 | 34 | private: 35 | Ui::Demo_Ruler *ui; 36 | QString m_title; 37 | 38 | QAction *m_pActionOrn; 39 | QAction *m_pActionAlign; 40 | }; 41 | 42 | #endif // DEMO_RULER_H 43 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_ruler.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_Ruler 4 | 5 | 6 | 7 | 0 8 | 0 9 | 478 10 | 86 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | CRuler 25 | QWidget 26 |
cruler.h
27 | 1 28 |
29 |
30 | 31 | 32 |
33 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_speedgauge.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | #include "demo_speedgauge.h" 3 | #include "ui_demo_speedgauge.h" 4 | 5 | Demo_SpeedGauge::Demo_SpeedGauge(const QString &title, QWidget *parent) : 6 | QDialog(parent), 7 | ui(new Ui::Demo_SpeedGauge) 8 | { 9 | ui->setupUi(this); 10 | 11 | this->setWindowTitle(title); 12 | } 13 | 14 | Demo_SpeedGauge::~Demo_SpeedGauge() 15 | { 16 | delete ui; 17 | } 18 | 19 | void Demo_SpeedGauge::on_horizontalSlider_valueChanged(int value) 20 | { 21 | ui->widget->setCurrentValue(value); 22 | } 23 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_speedgauge.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_SPEEDGAUGE_H 2 | #define DEMO_SPEEDGAUGE_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_SpeedGauge; 8 | } 9 | 10 | class Demo_SpeedGauge : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_SpeedGauge(const QString &title ="",QWidget *parent = 0); 16 | ~Demo_SpeedGauge(); 17 | 18 | private slots: 19 | void on_horizontalSlider_valueChanged(int value); 20 | 21 | private: 22 | Ui::Demo_SpeedGauge *ui; 23 | }; 24 | 25 | #endif // DEMO_SPEEDGAUGE_H 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_speedgauge.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_SpeedGauge 4 | 5 | 6 | 7 | 0 8 | 0 9 | 405 10 | 329 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | Qt::Horizontal 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | SpeedGaugeWidget 32 | QWidget 33 |
speedgaugewidget.h
34 | 1 35 |
36 |
37 | 38 | 39 |
40 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_speedwatch.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | 3 | #include "demo_speedwatch.h" 4 | #include "ui_demo_speedwatch.h" 5 | 6 | Demo_SpeedWatch::Demo_SpeedWatch(const QString &title, QWidget *parent) : 7 | QWidget(parent), 8 | ui(new Ui::Demo_SpeedWatch) 9 | { 10 | ui->setupUi(this); 11 | 12 | this->setWindowTitle (title); 13 | } 14 | 15 | Demo_SpeedWatch::~Demo_SpeedWatch() 16 | { 17 | delete ui; 18 | } 19 | 20 | void Demo_SpeedWatch::on_horizontalSlider_valueChanged(int value) 21 | { 22 | ui->widget->setValue (value); 23 | } 24 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_speedwatch.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_SPEEDWATCH_H 2 | #define DEMO_SPEEDWATCH_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_SpeedWatch; 8 | } 9 | 10 | class Demo_SpeedWatch : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_SpeedWatch(const QString &title = "",QWidget *parent = 0); 16 | ~Demo_SpeedWatch(); 17 | 18 | private slots: 19 | void on_horizontalSlider_valueChanged(int value); 20 | 21 | private: 22 | Ui::Demo_SpeedWatch *ui; 23 | }; 24 | 25 | #endif // DEMO_SPEEDWATCH_H 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_speedwatch.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_SpeedWatch 4 | 5 | 6 | 7 | 0 8 | 0 9 | 379 10 | 290 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | Qt::Horizontal 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | mySpeedWatch 32 | QWidget 33 |
myspeedwatch.h
34 | 1 35 |
36 |
37 | 38 | 39 |
40 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_splashscreen.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_splashscreen.h" 4 | #include "ui_demo_splashscreen.h" 5 | 6 | #include 7 | #include 8 | #include 9 | 10 | #define LOAD_TIME 2000 11 | 12 | Demo_SplashScreen::Demo_SplashScreen(const QString &title, 13 | QWidget *parent) : 14 | QWidget(parent), 15 | ui(new Ui::Demo_SplashScreen) 16 | { 17 | ui->setupUi(this); 18 | 19 | setWindowTitle(title); 20 | } 21 | 22 | Demo_SplashScreen::~Demo_SplashScreen() 23 | { 24 | delete ui; 25 | } 26 | 27 | void Demo_SplashScreen::showWidget() 28 | { 29 | QPixmap pixmap(":/image/start/Splashscreen.png"); 30 | pixmap.scaled(QApplication::desktop()->availableGeometry().size() 31 | ,Qt::KeepAspectRatio); 32 | CMySplashScreen *splash = new CMySplashScreen(pixmap,LOAD_TIME); 33 | splash->setDisabled(true); 34 | splash->show(); 35 | 36 | QTimer::singleShot(LOAD_TIME,this,SLOT(show())); 37 | } 38 | 39 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_splashscreen.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_SPLASHSCREEN_H 2 | #define DEMO_SPLASHSCREEN_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_SplashScreen; 8 | } 9 | 10 | class Demo_SplashScreen : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_SplashScreen(const QString &title = "", 16 | QWidget *parent = 0); 17 | ~Demo_SplashScreen(); 18 | 19 | void showWidget(); 20 | 21 | private: 22 | Ui::Demo_SplashScreen *ui; 23 | }; 24 | 25 | #endif // DEMO_SPLASHSCREEN_H 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_splashscreen.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_SplashScreen 4 | 5 | 6 | 7 | 0 8 | 0 9 | 408 10 | 268 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 我是主界面 21 | 22 | 23 | Qt::AlignCenter 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_startwidget.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_startwidget.h" 4 | #include "ui_demo_startwidget.h" 5 | 6 | 7 | Demo_StartWidget::Demo_StartWidget(const QString &title,QWidget *parent) : 8 | QDialog(parent), 9 | ui(new Ui::Demo_StartWidget) 10 | { 11 | ui->setupUi(this); 12 | 13 | setWindowTitle (title); 14 | 15 | m_pStartWidget = new LQStartWidget; 16 | 17 | m_pStartWidget->setLoadText ("程序正在加载插件"); 18 | m_pStartWidget->setLoadTime (6); 19 | m_pStartWidget->setStartShow (); 20 | 21 | connect (m_pStartWidget,SIGNAL(signalLoadFinish()), 22 | this,SIGNAL(signalShow())); 23 | 24 | } 25 | 26 | Demo_StartWidget::~Demo_StartWidget() 27 | { 28 | delete ui; 29 | if (m_pStartWidget != Q_NULLPTR){ 30 | m_pStartWidget->deleteLater (); 31 | m_pStartWidget = Q_NULLPTR; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_startwidget.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_STARTWIDGET_H 2 | #define DEMO_STARTWIDGET_H 3 | 4 | #include 5 | 6 | class LQStartWidget; 7 | 8 | namespace Ui { 9 | class Demo_StartWidget; 10 | } 11 | 12 | class Demo_StartWidget : public QDialog 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | explicit Demo_StartWidget(const QString &title = "", 18 | QWidget *parent = 0); 19 | ~Demo_StartWidget(); 20 | 21 | Q_SIGNALS: 22 | void signalShow(); 23 | 24 | private: 25 | Ui::Demo_StartWidget *ui; 26 | LQStartWidget *m_pStartWidget; 27 | }; 28 | 29 | #endif // DEMO_STARTWIDGET_H 30 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_startwidget.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_StartWidget 4 | 5 | 6 | 7 | 0 8 | 0 9 | 427 10 | 298 11 | 12 | 13 | 14 | Dialog 15 | 16 | 17 | 18 | 19 | 70 20 | 60 21 | 251 22 | 131 23 | 24 | 25 | 26 | 我是主界面 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_tabwidget.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_tabwidget.h" 4 | #include "ui_demo_tabwidget.h" 5 | 6 | 7 | Demo_tabwidget::Demo_tabwidget(const QString &title, QWidget *parent) : 8 | QWidget(parent), 9 | ui(new Ui::Demo_tabwidget) 10 | { 11 | ui->setupUi(this); 12 | 13 | this->setWindowTitle (title); 14 | } 15 | 16 | Demo_tabwidget::~Demo_tabwidget() 17 | { 18 | delete ui; 19 | } 20 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_tabwidget.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_TABWIDGET_H 2 | #define DEMO_TABWIDGET_H 3 | 4 | #include 5 | 6 | class MyTabWidget; 7 | 8 | namespace Ui { 9 | class Demo_tabwidget; 10 | } 11 | 12 | class Demo_tabwidget : public QWidget 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | explicit Demo_tabwidget(const QString &title = "",QWidget *parent = 0); 18 | ~Demo_tabwidget(); 19 | 20 | private: 21 | Ui::Demo_tabwidget *ui; 22 | MyTabWidget *m_ptabWidget; 23 | }; 24 | 25 | #endif // DEMO_TABWIDGET_H 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_tabwidget.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_tabwidget 4 | 5 | 6 | 7 | 0 8 | 0 9 | 400 10 | 300 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 19 | 20 | 2 21 | 22 | 23 | 24 | 主页 25 | 26 | 27 | 28 | 29 | 系统设置 30 | 31 | 32 | 33 | 34 | 关于系统 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | MyTabWidget 44 | QTabWidget 45 |
mytabwidget.h
46 | 1 47 |
48 |
49 | 50 | 51 |
52 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_tolerancebar.cpp: -------------------------------------------------------------------------------- 1 | #include "LQFormWidgetIncLib.h" 2 | 3 | #include "demo_tolerancebar.h" 4 | #include "ui_demo_tolerancebar.h" 5 | 6 | Demo_ToleranceBar::Demo_ToleranceBar(const QString &title, QWidget *parent) : 7 | QWidget(parent), 8 | ui(new Ui::Demo_ToleranceBar) 9 | { 10 | ui->setupUi(this); 11 | 12 | setWindowTitle (title); 13 | 14 | connect (ui->widget,SIGNAL(signalSendValue(int)), 15 | this,SIGNAL(signalValueChange(int))); 16 | } 17 | 18 | Demo_ToleranceBar::~Demo_ToleranceBar() 19 | { 20 | delete ui; 21 | } 22 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_tolerancebar.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_TOLERANCEBAR_H 2 | #define DEMO_TOLERANCEBAR_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_ToleranceBar; 8 | } 9 | 10 | class Demo_ToleranceBar : public QWidget 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_ToleranceBar(const QString &title,QWidget *parent = 0); 16 | ~Demo_ToleranceBar(); 17 | 18 | Q_SIGNALS: 19 | void signalValueChange(const int &value); 20 | 21 | private: 22 | Ui::Demo_ToleranceBar *ui; 23 | }; 24 | 25 | #endif // DEMO_TOLERANCEBAR_H 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_tolerancebar.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | Demo_ToleranceBar 4 | 5 | 6 | 7 | 0 8 | 0 9 | 274 10 | 124 11 | 12 | 13 | 14 | Form 15 | 16 | 17 | 18 | 0 19 | 20 | 21 | 0 22 | 23 | 24 | 0 25 | 26 | 27 | 0 28 | 29 | 30 | 0 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | ToleranceBar 40 | QWidget 41 |
tolerancebar.h
42 | 1 43 |
44 |
45 | 46 | 47 |
48 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_waveprogress.cpp: -------------------------------------------------------------------------------- 1 | #include "LQInstrumenttationIncLib.h" 2 | 3 | #include "demo_waveprogress.h" 4 | #include "ui_demo_waveprogress.h" 5 | 6 | Demo_WaveProgress::Demo_WaveProgress(const QString &title, QWidget *parent) : 7 | QDialog(parent), 8 | ui(new Ui::Demo_WaveProgress) 9 | { 10 | ui->setupUi(this); 11 | 12 | this->setWindowTitle (title); 13 | 14 | ui->horizontalSlider->setValue (0); 15 | ui->horizontalSlider->setRange (0,100); 16 | 17 | connect (ui->horizontalSlider,SIGNAL(valueChanged(int)), 18 | ui->widget,SLOT(slotValueChange(int))); 19 | } 20 | 21 | Demo_WaveProgress::~Demo_WaveProgress() 22 | { 23 | delete ui; 24 | } 25 | 26 | void Demo_WaveProgress::on_comboBox_activated(int index) 27 | { 28 | if (1 == index){ 29 | ui->widget->setWaveText ("帅"); 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_waveprogress.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_WAVEPROGRESS_H 2 | #define DEMO_WAVEPROGRESS_H 3 | 4 | #include 5 | 6 | namespace Ui { 7 | class Demo_WaveProgress; 8 | } 9 | 10 | class Demo_WaveProgress : public QDialog 11 | { 12 | Q_OBJECT 13 | 14 | public: 15 | explicit Demo_WaveProgress(const QString &title,QWidget *parent = 0); 16 | ~Demo_WaveProgress(); 17 | 18 | private slots: 19 | void on_comboBox_activated(int index); 20 | 21 | private: 22 | Ui::Demo_WaveProgress *ui; 23 | }; 24 | 25 | #endif // DEMO_WAVEPROGRESS_H 26 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_zxing.cpp: -------------------------------------------------------------------------------- 1 | #include "QZXing/inc/QZxingIncLib.h" 2 | 3 | #include "demo_zxing.h" 4 | #include "ui_demo_zxing.h" 5 | 6 | #include 7 | 8 | Demo_Zxing::Demo_Zxing(const QString &title, QWidget *parent) : 9 | QDialog(parent), 10 | ui(new Ui::Demo_Zxing) 11 | { 12 | ui->setupUi(this); 13 | 14 | if(!title.isEmpty ()) 15 | setWindowTitle (title); 16 | } 17 | 18 | Demo_Zxing::~Demo_Zxing() 19 | { 20 | delete ui; 21 | } 22 | 23 | void Demo_Zxing::on_pushButton_clicked() 24 | { 25 | m_fileName = QFileDialog::getOpenFileName(this, 26 | tr("二维码打开文件"), 27 | "./", 28 | tr("任何文件(*.*)" 29 | ";;文本文件(*.png)") 30 | ); 31 | if(m_fileName.isEmpty() == false) 32 | { 33 | ui->lineEdit->setText(m_fileName); 34 | QImage img; //加载图像 35 | if(!(img.load(m_fileName))) 36 | { 37 | return; 38 | } 39 | img = img.scaled(ui->label->width(),ui->label->height(),Qt::KeepAspectRatio); 40 | ui->label->setPixmap(QPixmap::fromImage(img)); 41 | 42 | QZXing decoder(QZXing::DecoderFormat_None); 43 | QString qrmsg = decoder.decodeImage(img); 44 | ui->textEdit->setText(tr(">> %1").arg(qrmsg)); 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /Exmaple/demo/demo_zxing.h: -------------------------------------------------------------------------------- 1 | #ifndef DEMO_ZXING_H 2 | #define DEMO_ZXING_H 3 | 4 | #include 5 | 6 | #define QRBUFSIZ 20480 7 | 8 | typedef bool (*fpGetQrStr)(const char*, char*, int); 9 | 10 | namespace Ui { 11 | class Demo_Zxing; 12 | } 13 | 14 | class Demo_Zxing : public QDialog 15 | { 16 | Q_OBJECT 17 | 18 | public: 19 | explicit Demo_Zxing(const QString &title = "", 20 | QWidget *parent = 0); 21 | ~Demo_Zxing(); 22 | 23 | private slots: 24 | void on_pushButton_clicked(); 25 | 26 | private: 27 | Ui::Demo_Zxing *ui; 28 | 29 | QString m_fileName; 30 | fpGetQrStr GetQrStr; 31 | }; 32 | 33 | #endif // DEMO_ZXING_H 34 | -------------------------------------------------------------------------------- /Exmaple/image/RightMessageBox/title.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/Exmaple/image/RightMessageBox/title.png -------------------------------------------------------------------------------- /Exmaple/image/start/Splashscreen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/Exmaple/image/start/Splashscreen.png -------------------------------------------------------------------------------- /Exmaple/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include "examplewidget.h" 4 | 5 | int main(int argc, char *argv[]) 6 | { 7 | QApplication app(argc,argv); 8 | 9 | ExampleWidget widget; 10 | widget.show (); 11 | 12 | int ret = app.exec (); 13 | return ret; 14 | } 15 | 16 | -------------------------------------------------------------------------------- /LQ3rdparty/LQ3rdparty.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | 3 | SUBDIRS +=\ 4 | $$PWD/QZXing/QZXing/QZXing.pro 5 | 6 | 7 | CONFIG +=ordered 8 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/StdMain.h: -------------------------------------------------------------------------------- 1 | #ifndef STDMAIN_H 2 | #define STDMAIN_H 3 | 4 | #include "../inc/QZXing_global.h" 5 | 6 | #include "../inc/QZxingInc.h" 7 | 8 | #endif // STDMAIN_H 9 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/imagehandler.cpp: -------------------------------------------------------------------------------- 1 | #include "StdMain.h" 2 | 3 | #include "inc/imagehandler.h" 4 | 5 | #include 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | ImageHandler::ImageHandler(QObject *parent) : 12 | QObject(parent) 13 | { 14 | } 15 | 16 | QImage ImageHandler::extractQImage(QObject *imageObj, 17 | const double offsetX, const double offsetY, 18 | const double width, const double height) 19 | { 20 | QGraphicsObject *item = qobject_cast(imageObj); 21 | 22 | if (!item) { 23 | qDebug() << "Item is NULL"; 24 | return QImage(); 25 | } 26 | 27 | QImage img(item->boundingRect().size().toSize(), QImage::Format_RGB32); 28 | img.fill(QColor(255, 255, 255).rgb()); 29 | QPainter painter(&img); 30 | QStyleOptionGraphicsItem styleOption; 31 | item->paint(&painter, &styleOption); 32 | 33 | if(offsetX == 0 && offsetY == 0 && width == 0 && height == 0) 34 | return img; 35 | else 36 | { 37 | return img.copy(offsetX, offsetY, width, height); 38 | } 39 | } 40 | 41 | void ImageHandler::save(QObject *imageObj, const QString &path, 42 | const double offsetX, const double offsetY, 43 | const double width, const double height) 44 | { 45 | QImage img = extractQImage(imageObj, offsetX, offsetY, width, height); 46 | img.save(path); 47 | } 48 | 49 | #include "moc_imagehandler.cpp" 50 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/inc/CameraImageWrapper.h: -------------------------------------------------------------------------------- 1 | #ifndef CAMERAIMAGE_H 2 | #define CAMERAIMAGE_H 3 | 4 | #include 5 | #include 6 | 7 | //#include "zxing/LuminanceSource.h" 8 | #include "zxing/zxing/LuminanceSource.h" 9 | 10 | using namespace zxing; 11 | 12 | class QZXINGSHARED_EXPORT CameraImageWrapper : public LuminanceSource 13 | { 14 | public: 15 | CameraImageWrapper(); 16 | CameraImageWrapper(const QImage& sourceImage); 17 | CameraImageWrapper(CameraImageWrapper& otherInstance); 18 | ~CameraImageWrapper(); 19 | 20 | static CameraImageWrapper* Factory(const QImage& image, int maxWidth=-1, int maxHeight=-1, bool smoothTransformation=false); 21 | 22 | int getWidth() const; 23 | int getHeight() const; 24 | 25 | unsigned char getPixel(int x, int y) const; 26 | unsigned char* copyMatrix() const; 27 | 28 | QImage grayScaleImage(QImage::Format f); 29 | QImage getOriginalImage(); 30 | 31 | // Callers take ownership of the returned memory and must call delete [] on it themselves. 32 | ArrayRef getRow(int y, ArrayRef row) const; 33 | ArrayRef getMatrix() const; 34 | 35 | private: 36 | QImage image; 37 | unsigned char* pRow; 38 | unsigned char* pMatrix; 39 | }; 40 | 41 | #endif //CAMERAIMAGE_H 42 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/inc/QZXing_global.h: -------------------------------------------------------------------------------- 1 | #ifndef QZXING_GLOBAL_H 2 | #define QZXING_GLOBAL_H 3 | 4 | #include 5 | #include 6 | 7 | #if defined(QZXING_LIBRARY) 8 | # define QZXINGSHARED_EXPORT Q_DECL_EXPORT 9 | #else 10 | # define QZXINGSHARED_EXPORT Q_DECL_IMPORT 11 | #endif 12 | 13 | #endif //QZXING_GLOBAL_H 14 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/inc/QZxingInc.h: -------------------------------------------------------------------------------- 1 | #ifndef QZXINGINC_H 2 | #define QZXINGINC_H 3 | 4 | #include "CameraImageWrapper.h" 5 | #include "imagehandler.h" 6 | #include "QZXing.h" 7 | 8 | 9 | #endif // QZXINGINC_H 10 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/inc/QZxingIncLib.h: -------------------------------------------------------------------------------- 1 | #ifndef QZXINGINCLIB_H 2 | #define QZXINGINCLIB_H 3 | 4 | #include "QZXing_global.h" 5 | 6 | #include "QZxingInc.h" 7 | 8 | #endif // QZXINGINCLIB_H 9 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/inc/imagehandler.h: -------------------------------------------------------------------------------- 1 | #ifndef IMAGEHANDLER_H 2 | #define IMAGEHANDLER_H 3 | 4 | #include 5 | #include 6 | 7 | class QZXINGSHARED_EXPORT ImageHandler : public QObject 8 | { 9 | Q_OBJECT 10 | public: 11 | explicit ImageHandler(QObject *parent = 0); 12 | 13 | QImage extractQImage(QObject *imageObj, 14 | const double offsetX = 0 , const double offsetY = 0, 15 | const double width = 0, const double height = 0); 16 | 17 | public slots: 18 | void save(QObject *item, const QString &path, 19 | const double offsetX = 0, const double offsetY = 0, 20 | const double width = 0, const double height = 0); 21 | }; 22 | 23 | #endif // IMAGEHANDLER_H 24 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/bigint/BigIntegerAlgorithms.hh: -------------------------------------------------------------------------------- 1 | #ifndef BIGINTEGERALGORITHMS_H 2 | #define BIGINTEGERALGORITHMS_H 3 | 4 | #include "BigInteger.hh" 5 | 6 | /* Some mathematical algorithms for big integers. 7 | * This code is new and, as such, experimental. */ 8 | 9 | // Returns the greatest common divisor of a and b. 10 | BigUnsigned gcd(BigUnsigned a, BigUnsigned b); 11 | 12 | /* Extended Euclidean algorithm. 13 | * Given m and n, finds gcd g and numbers r, s such that r*m + s*n == g. */ 14 | void extendedEuclidean(BigInteger m, BigInteger n, 15 | BigInteger &g, BigInteger &r, BigInteger &s); 16 | 17 | /* Returns the multiplicative inverse of x modulo n, or throws an exception if 18 | * they have a common factor. */ 19 | BigUnsigned modinv(const BigInteger &x, const BigUnsigned &n); 20 | 21 | // Returns (base ^ exponent) % modulus. 22 | BigUnsigned modexp(const BigInteger &base, const BigUnsigned &exponent, 23 | const BigUnsigned &modulus); 24 | 25 | #endif 26 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/bigint/BigIntegerLibrary.hh: -------------------------------------------------------------------------------- 1 | // This header file includes all of the library header files. 2 | 3 | #include "NumberlikeArray.hh" 4 | #include "BigUnsigned.hh" 5 | #include "BigInteger.hh" 6 | #include "BigIntegerAlgorithms.hh" 7 | #include "BigUnsignedInABase.hh" 8 | #include "BigIntegerUtils.hh" 9 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/win32/zxing/iconv.h: -------------------------------------------------------------------------------- 1 | #ifndef _LIBICONV_H 2 | #define _LIBICONV_H 3 | #include 4 | #ifdef __cplusplus 5 | extern "C" { 6 | #endif 7 | typedef void* iconv_t; 8 | iconv_t iconv_open(const char *tocode, const char *fromcode); 9 | int iconv_close(iconv_t cd); 10 | size_t iconv(iconv_t cd, char **inbuf, size_t *inbytesleft, char **outbuf, size_t *outbytesleft); 11 | #ifdef __cplusplus 12 | } 13 | #endif 14 | #endif//_LIBICONV_H -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/BarcodeFormat.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * Created by Christian Brunschen on 13/05/2008. 4 | * Copyright 2008 ZXing authors All rights reserved. 5 | * 6 | * Licensed under the Apache License, Version 2.0 (the "License"); 7 | * you may not use this file except in compliance with the License. 8 | * You may obtain a copy of the License at 9 | * 10 | * http://www.apache.org/licenses/LICENSE-2.0 11 | * 12 | * Unless required by applicable law or agreed to in writing, software 13 | * distributed under the License is distributed on an "AS IS" BASIS, 14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | * See the License for the specific language governing permissions and 16 | * limitations under the License. 17 | */ 18 | 19 | #include 20 | 21 | const char* zxing::BarcodeFormat::barcodeFormatNames[] = { 22 | 0, 23 | "AZTEC", 24 | "CODABAR", 25 | "CODE_39", 26 | "CODE_93", 27 | "CODE_128", 28 | "DATA_MATRIX", 29 | "EAN_8", 30 | "EAN_13", 31 | "ITF", 32 | "MAXICODE", 33 | "PDF_417", 34 | "QR_CODE", 35 | "RSS_14", 36 | "RSS_EXPANDED", 37 | "UPC_A", 38 | "UPC_E", 39 | "UPC_EAN_EXTENSION" 40 | }; 41 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/Binarizer.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * Binarizer.cpp 4 | * zxing 5 | * 6 | * Created by Ralf Kistner on 16/10/2009. 7 | * Copyright 2008 ZXing authors All rights reserved. 8 | * Modified by Lukasz Warchol on 02/02/2010. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | 25 | namespace zxing { 26 | 27 | Binarizer::Binarizer(Ref source) : source_(source) { 28 | } 29 | 30 | Binarizer::~Binarizer() { 31 | } 32 | 33 | Ref Binarizer::getLuminanceSource() const { 34 | return source_; 35 | } 36 | 37 | int Binarizer::getWidth() const { 38 | return source_->getWidth(); 39 | } 40 | 41 | int Binarizer::getHeight() const { 42 | return source_->getHeight(); 43 | } 44 | 45 | } 46 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/Binarizer.h: -------------------------------------------------------------------------------- 1 | #ifndef BINARIZER_H_ 2 | #define BINARIZER_H_ 3 | 4 | /* 5 | * Binarizer.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | 30 | class Binarizer : public Counted { 31 | private: 32 | Ref source_; 33 | 34 | public: 35 | Binarizer(Ref source); 36 | virtual ~Binarizer(); 37 | 38 | virtual Ref getBlackRow(int y, Ref row) = 0; 39 | virtual Ref getBlackMatrix() = 0; 40 | 41 | Ref getLuminanceSource() const ; 42 | virtual Ref createBinarizer(Ref source) = 0; 43 | 44 | int getWidth() const; 45 | int getHeight() const; 46 | 47 | }; 48 | 49 | } 50 | #endif /* BINARIZER_H_ */ 51 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/ChecksumException.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * ChecksumException.cpp 4 | * zxing 5 | * 6 | * Created by Christian Brunschen on 13/05/2008. 7 | * Copyright 2008 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | using zxing::ChecksumException; 25 | 26 | ChecksumException::ChecksumException() throw() {} 27 | ChecksumException::ChecksumException(const char *msg) throw() : ReaderException(msg) {} 28 | ChecksumException::~ChecksumException() throw() {} 29 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/ChecksumException.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | 3 | #ifndef __CHECKSUM_EXCEPTION_H__ 4 | #define __NOT_FOUND_EXCEPTION_H__ 5 | 6 | /* 7 | * Copyright 20011 ZXing authors 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | namespace zxing { 25 | class ChecksumException : public ReaderException { 26 | typedef ReaderException Base; 27 | public: 28 | ChecksumException() throw(); 29 | ChecksumException(const char *msg) throw(); 30 | ~ChecksumException() throw(); 31 | }; 32 | } 33 | 34 | #endif // __CHECKSUM_EXCEPTION_H__ 35 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/Exception.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * Exception.cpp 4 | * ZXing 5 | * 6 | * Created by Christian Brunschen on 03/06/2008. 7 | * Copyright 2008-2011 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | 27 | using zxing::Exception; 28 | 29 | void Exception::deleteMessage() { 30 | delete [] message; 31 | } 32 | 33 | char const* Exception::copy(char const* msg) { 34 | char* message = 0; 35 | if (msg) { 36 | int l = strlen(msg)+1; 37 | if (l) { 38 | message = new char[l]; 39 | strcpy(message, msg); 40 | } 41 | } 42 | return message; 43 | } 44 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/Exception.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __EXCEPTION_H__ 3 | #define __EXCEPTION_H__ 4 | 5 | /* 6 | * Exception.h 7 | * ZXing 8 | * 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | 27 | namespace zxing { 28 | 29 | class Exception : public std::exception { 30 | private: 31 | char const* const message; 32 | 33 | public: 34 | Exception() throw() : message(0) {} 35 | Exception(const char* msg) throw() : message(copy(msg)) {} 36 | Exception(Exception const& that) throw() : std::exception(that), message(copy(that.message)) {} 37 | ~Exception() throw() { 38 | if(message) { 39 | deleteMessage(); 40 | } 41 | } 42 | char const* what() const throw() {return message ? message : "";} 43 | 44 | private: 45 | static char const* copy(char const*); 46 | void deleteMessage(); 47 | }; 48 | 49 | } 50 | 51 | #endif // __EXCEPTION_H__ 52 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/FormatException.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * FormatException.cpp 4 | * zxing 5 | * 6 | * Created by Christian Brunschen on 13/05/2008. 7 | * Copyright 2008 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | namespace zxing { 25 | 26 | FormatException::FormatException() {} 27 | 28 | FormatException::FormatException(const char *msg) : 29 | ReaderException(msg) { 30 | } 31 | 32 | FormatException::~FormatException() throw() { 33 | } 34 | 35 | FormatException const& 36 | FormatException::getFormatInstance() { 37 | static FormatException instance; 38 | return instance; 39 | } 40 | 41 | } 42 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/FormatException.h: -------------------------------------------------------------------------------- 1 | #ifndef __FORMAT_EXCEPTION_H__ 2 | #define __FORMAT_EXCEPTION_H__ 3 | 4 | /* 5 | * FormatException.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | 25 | namespace zxing { 26 | 27 | class FormatException : public ReaderException { 28 | public: 29 | FormatException(); 30 | FormatException(const char *msg); 31 | ~FormatException() throw(); 32 | 33 | static FormatException const& getFormatInstance(); 34 | }; 35 | 36 | } 37 | #endif // __FORMAT_EXCEPTION_H__ 38 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/IllegalStateException.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | 3 | #ifndef __ILLEGAL_STATE_EXCEPTION_H__ 4 | #define __ILLEGAL_STATE_EXCEPTION_H__ 5 | 6 | /* 7 | * Copyright 20011 ZXing authors 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may illegal use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | namespace zxing { 25 | 26 | class IllegalStateException : public ReaderException { 27 | public: 28 | IllegalStateException() throw() {} 29 | IllegalStateException(const char *msg) throw() : ReaderException(msg) {} 30 | ~IllegalStateException() throw() {} 31 | }; 32 | 33 | } 34 | 35 | #endif // __ILLEGAL_STATE_EXCEPTION_H__ 36 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/MultiFormatReader.h: -------------------------------------------------------------------------------- 1 | #ifndef __MULTI_FORMAT_READER_H__ 2 | #define __MULTI_FORMAT_READER_H__ 3 | 4 | /* 5 | * MultiFormatBarcodeReader.h 6 | * ZXing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | 29 | namespace zxing { 30 | class MultiFormatReader : public Reader { 31 | private: 32 | Ref decodeInternal(Ref image); 33 | 34 | std::vector > readers_; 35 | DecodeHints hints_; 36 | 37 | public: 38 | MultiFormatReader(); 39 | 40 | Ref decode(Ref image); 41 | Ref decode(Ref image, DecodeHints hints); 42 | Ref decodeWithState(Ref image); 43 | void setHints(DecodeHints hints); 44 | ~MultiFormatReader(); 45 | }; 46 | } 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/NotFoundException.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | 3 | #ifndef __NOT_FOUND_EXCEPTION_H__ 4 | #define __NOT_FOUND_EXCEPTION_H__ 5 | 6 | /* 7 | * Copyright 20011 ZXing authors 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | namespace zxing { 25 | 26 | class NotFoundException : public ReaderException { 27 | public: 28 | NotFoundException() throw() {} 29 | NotFoundException(const char *msg) throw() : ReaderException(msg) {} 30 | ~NotFoundException() throw() {} 31 | }; 32 | 33 | } 34 | 35 | #endif // __NOT_FOUND_EXCEPTION_H__ 36 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/Reader.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Reader.cpp 3 | * zxing 4 | * 5 | * Created by Christian Brunschen on 13/05/2008. 6 | * Copyright 2008 ZXing authors All rights reserved. 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #include 22 | 23 | namespace zxing { 24 | 25 | Reader::~Reader() { } 26 | 27 | Ref Reader::decode(Ref image) { 28 | return decode(image, DecodeHints::DEFAULT_HINT); 29 | } 30 | 31 | } 32 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/Reader.h: -------------------------------------------------------------------------------- 1 | #ifndef __READER_H__ 2 | #define __READER_H__ 3 | 4 | /* 5 | * Reader.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | 27 | namespace zxing { 28 | 29 | class Reader : public Counted { 30 | protected: 31 | Reader() {} 32 | public: 33 | virtual Ref decode(Ref image); 34 | virtual Ref decode(Ref image, DecodeHints hints) = 0; 35 | virtual ~Reader(); 36 | }; 37 | 38 | } 39 | 40 | #endif // __READER_H__ 41 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/ReaderException.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __READER_EXCEPTION_H__ 3 | #define __READER_EXCEPTION_H__ 4 | 5 | /* 6 | * ReaderException.h 7 | * zxing 8 | * 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | 26 | namespace zxing { 27 | 28 | class ReaderException : public Exception { 29 | public: 30 | ReaderException() throw() {} 31 | ReaderException(char const* msg) throw() : Exception(msg) {} 32 | ~ReaderException() throw() {} 33 | }; 34 | 35 | } 36 | 37 | #endif // __READER_EXCEPTION_H__ 38 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/ResultIO.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * ResultIO.cpp 4 | * zxing 5 | * 6 | * Created by Christian Brunschen on 13/05/2008. 7 | * Copyright 2008 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | using zxing::Result; 25 | using std::ostream; 26 | 27 | ostream& zxing::operator<<(ostream &out, Result& result) { 28 | if (result.text_ != 0) { 29 | out << result.text_->getText(); 30 | } else { 31 | out << "[" << result.rawBytes_->size() << " bytes]"; 32 | } 33 | return out; 34 | } 35 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/ResultPointCallback.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * ResultPointCallback.cpp 3 | * zxing 4 | * 5 | * Copyright 2010 ZXing authors All rights reserved. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include 21 | 22 | namespace zxing { 23 | 24 | ResultPointCallback::~ResultPointCallback() {} 25 | 26 | } 27 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/ResultPointCallback.h: -------------------------------------------------------------------------------- 1 | #ifndef __RESULT_POINT_CALLBACK_H__ 2 | #define __RESULT_POINT_CALLBACK_H__ 3 | 4 | /* 5 | * ResultPointCallback.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | 25 | namespace zxing { 26 | 27 | class ResultPoint; 28 | 29 | class ResultPointCallback : public Counted { 30 | protected: 31 | ResultPointCallback() {} 32 | public: 33 | virtual void foundPossibleResultPoint(ResultPoint const& point) = 0; 34 | virtual ~ResultPointCallback(); 35 | }; 36 | 37 | } 38 | 39 | #endif // __RESULT_POINT_CALLBACK_H__ 40 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/aztec/AztecDetectorResult.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * AtztecDetecorResult.h 4 | * zxing 5 | * 6 | * Created by Lukas Stabe on 08/02/2012. 7 | * Copyright 2012 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | #ifndef ZXingWidget_AtztecDetecorResult_h 25 | #define ZXingWidget_AtztecDetecorResult_h 26 | 27 | namespace zxing { 28 | namespace aztec { 29 | 30 | class AztecDetectorResult : public DetectorResult { 31 | private: 32 | bool compact_; 33 | int nbDatablocks_, nbLayers_; 34 | public: 35 | AztecDetectorResult(Ref bits, 36 | ArrayRef< Ref > points, 37 | bool compact, 38 | int nbDatablocks, 39 | int nbLayers); 40 | bool isCompact(); 41 | int getNBDatablocks(); 42 | int getNBLayers(); 43 | }; 44 | 45 | } 46 | } 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/aztec/AztecReader.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * AztecReader.h 4 | * zxing 5 | * 6 | * Created by Lukas Stabe on 08/02/2012. 7 | * Copyright 2012 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | #include 24 | #include 25 | 26 | #ifndef ZXingWidget_AztecReader_h 27 | #define ZXingWidget_AztecReader_h 28 | 29 | namespace zxing { 30 | namespace aztec { 31 | 32 | class AztecReader : public Reader { 33 | private: 34 | Decoder decoder_; 35 | 36 | protected: 37 | Decoder &getDecoder(); 38 | 39 | public: 40 | AztecReader(); 41 | virtual Ref decode(Ref image); 42 | virtual Ref decode(Ref image, DecodeHints hints); 43 | virtual ~AztecReader(); 44 | }; 45 | 46 | } 47 | } 48 | 49 | #endif 50 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/BitArrayIO.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * Copyright 2010 ZXing authors. All rights reserved. 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | #include 19 | 20 | using zxing::BitArray; 21 | using std::ostream; 22 | 23 | ostream& zxing::operator << (ostream& os, BitArray const& ba) { 24 | for (int i = 0, size = ba.getSize(); i < size; i++) { 25 | if ((i & 0x07) == 0) { 26 | os << ' '; 27 | } 28 | os << (ba.get(i) ? 'X' : '.'); 29 | } 30 | return os; 31 | } 32 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/DecoderResult.h: -------------------------------------------------------------------------------- 1 | #ifndef __DECODER_RESULT_H__ 2 | #define __DECODER_RESULT_H__ 3 | 4 | /* 5 | * DecoderResult.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | 30 | class DecoderResult : public Counted { 31 | private: 32 | ArrayRef rawBytes_; 33 | Ref text_; 34 | ArrayRef< ArrayRef > byteSegments_; 35 | std::string ecLevel_; 36 | 37 | public: 38 | DecoderResult(ArrayRef rawBytes, 39 | Ref text, 40 | ArrayRef< ArrayRef >& byteSegments, 41 | std::string const& ecLevel); 42 | 43 | DecoderResult(ArrayRef rawBytes, Ref text); 44 | 45 | ArrayRef getRawBytes(); 46 | Ref getText(); 47 | }; 48 | 49 | } 50 | 51 | #endif // __DECODER_RESULT_H__ 52 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/DetectorResult.cpp: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | /* 3 | * DetectorResult.cpp 4 | * zxing 5 | * 6 | * Created by Christian Brunschen on 14/05/2008. 7 | * Copyright 2008 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | namespace zxing { 25 | 26 | DetectorResult::DetectorResult(Ref bits, 27 | ArrayRef< Ref > points) 28 | : bits_(bits), points_(points) { 29 | } 30 | 31 | Ref DetectorResult::getBits() { 32 | return bits_; 33 | } 34 | 35 | ArrayRef< Ref > DetectorResult::getPoints() { 36 | return points_; 37 | } 38 | 39 | } 40 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/DetectorResult.h: -------------------------------------------------------------------------------- 1 | #ifndef __DETECTOR_RESULT_H__ 2 | #define __DETECTOR_RESULT_H__ 3 | 4 | /* 5 | * DetectorResult.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | 30 | class DetectorResult : public Counted { 31 | private: 32 | Ref bits_; 33 | ArrayRef< Ref > points_; 34 | 35 | public: 36 | DetectorResult(Ref bits, ArrayRef< Ref > points); 37 | Ref getBits(); 38 | ArrayRef< Ref > getPoints(); 39 | }; 40 | 41 | } 42 | 43 | #endif // __DETECTOR_RESULT_H__ 44 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/GreyscaleRotatedLuminanceSource.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __GREYSCALE_ROTATED_LUMINANCE_SOURCE__ 3 | #define __GREYSCALE_ROTATED_LUMINANCE_SOURCE__ 4 | /* 5 | * GreyscaleRotatedLuminanceSource.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | 24 | #include 25 | 26 | namespace zxing { 27 | 28 | class GreyscaleRotatedLuminanceSource : public LuminanceSource { 29 | private: 30 | typedef LuminanceSource Super; 31 | ArrayRef greyData_; 32 | const int dataWidth_; 33 | const int left_; 34 | const int top_; 35 | 36 | public: 37 | GreyscaleRotatedLuminanceSource(ArrayRef greyData, int dataWidth, int dataHeight, 38 | int left, int top, int width, int height); 39 | 40 | ArrayRef getRow(int y, ArrayRef row) const; 41 | ArrayRef getMatrix() const; 42 | }; 43 | 44 | } 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/IllegalArgumentException.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * IllegalArgumentException.cpp 3 | * zxing 4 | * 5 | * Created by Christian Brunschen on 06/05/2008. 6 | * Copyright 2008 Google UK. All rights reserved. 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #include 22 | 23 | using zxing::IllegalArgumentException; 24 | 25 | IllegalArgumentException::IllegalArgumentException() : Exception() {} 26 | IllegalArgumentException::IllegalArgumentException(const char *msg) : Exception(msg) {} 27 | IllegalArgumentException::~IllegalArgumentException() throw() {} 28 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/IllegalArgumentException.h: -------------------------------------------------------------------------------- 1 | #ifndef __ILLEGAL_ARGUMENT_EXCEPTION_H__ 2 | #define __ILLEGAL_ARGUMENT_EXCEPTION_H__ 3 | 4 | /* 5 | * IllegalArgumentException.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | 25 | namespace zxing { 26 | 27 | class IllegalArgumentException : public Exception { 28 | public: 29 | IllegalArgumentException(); 30 | IllegalArgumentException(const char *msg); 31 | ~IllegalArgumentException() throw(); 32 | }; 33 | 34 | } 35 | 36 | #endif // __ILLEGAL_ARGUMENT_EXCEPTION_H__ 37 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/Point.h: -------------------------------------------------------------------------------- 1 | #ifndef __POINT_H__ 2 | #define __POINT_H__ 3 | 4 | /* 5 | * Point.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | namespace zxing { 24 | class PointI { 25 | public: 26 | int x; 27 | int y; 28 | }; 29 | 30 | class Point { 31 | public: 32 | Point() : x(0.0f), y(0.0f) {}; 33 | Point(float x_, float y_) : x(x_), y(y_) {}; 34 | 35 | float x; 36 | float y; 37 | }; 38 | 39 | class Line { 40 | public: 41 | Line(Point start_, Point end_) : start(start_), end(end_) {}; 42 | 43 | Point start; 44 | Point end; 45 | }; 46 | } 47 | #endif // POINT_H_ 48 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/detector/JavaMath.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __ZXING_COMMON_DETECTOR_MATH_H__ 3 | #define __ZXING_COMMON_DETECTOR_MATH_H__ 4 | /* 5 | * Copyright 2012 ZXing authors All rights reserved. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include 21 | 22 | namespace zxing { 23 | namespace common { 24 | namespace detector { 25 | 26 | class Math { 27 | private: 28 | Math(); 29 | ~Math(); 30 | public: 31 | 32 | // Java standard Math.round 33 | static inline int round(float a) { 34 | return (int)std::floor(a +0.5f); 35 | } 36 | 37 | }; 38 | 39 | } 40 | } 41 | } 42 | 43 | #endif 44 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/reedsolomon/ReedSolomonException.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * ReedSolomonException.cpp 3 | * zxing 4 | * 5 | * Created by Christian Brunschen on 06/05/2008. 6 | * Copyright 2008 Google UK. All rights reserved. 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #include 22 | 23 | namespace zxing { 24 | ReedSolomonException::ReedSolomonException(const char *msg) throw() : 25 | Exception(msg) { 26 | } 27 | ReedSolomonException::~ReedSolomonException() throw() { 28 | } 29 | 30 | } 31 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/common/reedsolomon/ReedSolomonException.h: -------------------------------------------------------------------------------- 1 | #ifndef __REED_SOLOMON_EXCEPTION_H__ 2 | #define __REED_SOLOMON_EXCEPTION_H__ 3 | 4 | /* 5 | * ReedSolomonException.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | 25 | namespace zxing { 26 | class ReedSolomonException : public Exception { 27 | public: 28 | ReedSolomonException(const char *msg) throw(); 29 | ~ReedSolomonException() throw(); 30 | }; 31 | } 32 | 33 | #endif // __REED_SOLOMON_EXCEPTION_H__ 34 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/DataMatrixReader.h: -------------------------------------------------------------------------------- 1 | #ifndef __DATA_MATRIX_READER_H__ 2 | #define __DATA_MATRIX_READER_H__ 3 | 4 | /* 5 | * DataMatrixReader.h 6 | * zxing 7 | * 8 | * Created by Luiz Silva on 09/02/2010. 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | namespace datamatrix { 30 | 31 | class DataMatrixReader : public Reader { 32 | private: 33 | Decoder decoder_; 34 | 35 | public: 36 | DataMatrixReader(); 37 | virtual Ref decode(Ref image, DecodeHints hints); 38 | virtual ~DataMatrixReader(); 39 | 40 | }; 41 | 42 | } 43 | } 44 | 45 | #endif // __DATA_MATRIX_READER_H__ 46 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/decoder/DataBlock.h: -------------------------------------------------------------------------------- 1 | #ifndef __DATA_BLOCK_DM_H__ 2 | #define __DATA_BLOCK_DM_H__ 3 | 4 | /* 5 | * DataBlock.h 6 | * zxing 7 | * 8 | * Created by Luiz Silva on 09/02/2010. 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | 29 | namespace zxing { 30 | namespace datamatrix { 31 | 32 | class DataBlock : public Counted { 33 | private: 34 | int numDataCodewords_; 35 | ArrayRef codewords_; 36 | 37 | DataBlock(int numDataCodewords, ArrayRef codewords); 38 | 39 | public: 40 | static std::vector > getDataBlocks(ArrayRef rawCodewords, Version *version); 41 | 42 | int getNumDataCodewords(); 43 | ArrayRef getCodewords(); 44 | }; 45 | 46 | } 47 | } 48 | 49 | #endif // __DATA_BLOCK_DM_H__ 50 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/decoder/Decoder.h: -------------------------------------------------------------------------------- 1 | #ifndef __DECODER_DM_H__ 2 | #define __DECODER_DM_H__ 3 | 4 | /* 5 | * Decoder.h 6 | * zxing 7 | * 8 | * Created by Luiz Silva on 09/02/2010. 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | #include 29 | 30 | 31 | namespace zxing { 32 | namespace datamatrix { 33 | 34 | class Decoder { 35 | private: 36 | ReedSolomonDecoder rsDecoder_; 37 | 38 | void correctErrors(ArrayRef bytes, int numDataCodewords); 39 | 40 | public: 41 | Decoder(); 42 | 43 | Ref decode(Ref bits); 44 | }; 45 | 46 | } 47 | } 48 | 49 | #endif // __DECODER_DM_H__ 50 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/detector/CornerPoint.h: -------------------------------------------------------------------------------- 1 | #ifndef __CORNER_FINDER_H__ 2 | #define __CORNER_FINDER_H__ 3 | 4 | /* 5 | * CornerPoint.h 6 | * zxing 7 | * 8 | * Created by Luiz Silva on 09/02/2010. 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | 27 | namespace zxing { 28 | namespace datamatrix { 29 | 30 | class CornerPoint : public ResultPoint { 31 | private: 32 | int counter_; 33 | 34 | public: 35 | CornerPoint(float posX, float posY); 36 | int getCount() const; 37 | void incrementCount(); 38 | bool equals(Ref other) const; 39 | }; 40 | } 41 | } 42 | 43 | #endif // __CORNER_FINDER_H__ 44 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/detector/DataMatrixCornerPoint.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * CornerPoint.cpp 3 | * zxing 4 | * 5 | * Created by Luiz Silva on 09/02/2010. 6 | * Copyright 2010 ZXing authors All rights reserved. 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #include 22 | 23 | 24 | namespace zxing { 25 | namespace datamatrix { 26 | 27 | using namespace std; 28 | 29 | CornerPoint::CornerPoint(float posX, float posY) : 30 | ResultPoint(posX,posY), counter_(0) { 31 | } 32 | 33 | int CornerPoint::getCount() const { 34 | return counter_; 35 | } 36 | 37 | void CornerPoint::incrementCount() { 38 | counter_++; 39 | } 40 | 41 | bool CornerPoint::equals(Ref other) const { 42 | return posX_ == other->getX() && posY_ == other->getY(); 43 | } 44 | 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/detector/DataMatrixDetectorException.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * DetectorException.cpp 3 | * 4 | * Created on: Aug 26, 2011 5 | * Author: luiz 6 | */ 7 | 8 | #include "DetectorException.h" 9 | 10 | namespace zxing { 11 | namespace datamatrix { 12 | 13 | DetectorException::DetectorException(const char *msg) : 14 | Exception(msg) { 15 | 16 | } 17 | 18 | DetectorException::~DetectorException() throw () { 19 | // TODO Auto-generated destructor stub 20 | } 21 | 22 | } 23 | } /* namespace zxing */ 24 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/datamatrix/detector/DetectorException.h: -------------------------------------------------------------------------------- 1 | /* 2 | * DetectorException.h 3 | * 4 | * Created on: Aug 26, 2011 5 | * Author: luiz 6 | */ 7 | 8 | #ifndef DETECTOREXCEPTION_H_ 9 | #define DETECTOREXCEPTION_H_ 10 | 11 | #include 12 | 13 | namespace zxing { 14 | namespace datamatrix { 15 | 16 | class DetectorException : public Exception { 17 | public: 18 | DetectorException(const char *msg); 19 | virtual ~DetectorException() throw(); 20 | }; 21 | } /* namespace nexxera */ 22 | } /* namespace zxing */ 23 | #endif /* DETECTOREXCEPTION_H_ */ 24 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/multi/ByQuadrantReader.h: -------------------------------------------------------------------------------- 1 | #ifndef __BY_QUADRANT_READER_H__ 2 | #define __BY_QUADRANT_READER_H__ 3 | 4 | /* 5 | * Copyright 2011 ZXing authors All rights reserved. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include 21 | #include 22 | #include 23 | #include 24 | 25 | namespace zxing { 26 | namespace multi { 27 | 28 | class ByQuadrantReader : public Reader { 29 | private: 30 | Reader& delegate_; 31 | 32 | public: 33 | ByQuadrantReader(Reader& delegate); 34 | virtual ~ByQuadrantReader(); 35 | virtual Ref decode(Ref image); 36 | virtual Ref decode(Ref image, DecodeHints hints); 37 | }; 38 | 39 | } 40 | } 41 | 42 | #endif // __BY_QUADRANT_READER_H__ 43 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/multi/MultipleBarcodeReader.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2011 ZXing authors All rights reserved. 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include 18 | 19 | namespace zxing { 20 | namespace multi { 21 | 22 | MultipleBarcodeReader::~MultipleBarcodeReader() { } 23 | 24 | std::vector > MultipleBarcodeReader::decodeMultiple(Ref image) { 25 | return decodeMultiple(image, DecodeHints::DEFAULT_HINT); 26 | } 27 | 28 | } // End zxing::multi namespace 29 | } // End zxing namespace 30 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/multi/MultipleBarcodeReader.h: -------------------------------------------------------------------------------- 1 | #ifndef __MULTIPLE_BARCODE_READER_H__ 2 | #define __MULTIPLE_BARCODE_READER_H__ 3 | 4 | /* 5 | * Copyright 2011 ZXing authors All rights reserved. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include 21 | #include 22 | #include 23 | #include 24 | #include 25 | 26 | namespace zxing { 27 | namespace multi { 28 | 29 | class MultipleBarcodeReader : public Counted { 30 | protected: 31 | MultipleBarcodeReader() {} 32 | public: 33 | virtual std::vector > decodeMultiple(Ref image); 34 | virtual std::vector > decodeMultiple(Ref image, DecodeHints hints) = 0; 35 | virtual ~MultipleBarcodeReader(); 36 | }; 37 | 38 | } 39 | } 40 | 41 | #endif // __MULTIPLE_BARCODE_READER_H__ 42 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/multi/qrcode/QRCodeMultiReader.h: -------------------------------------------------------------------------------- 1 | #ifndef __QRCODE_MULTI_READER_H__ 2 | #define __QRCODE_MULTI_READER_H__ 3 | 4 | /* 5 | * Copyright 2011 ZXing authors All rights reserved. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include 21 | #include 22 | 23 | namespace zxing { 24 | namespace multi { 25 | 26 | class QRCodeMultiReader: public zxing::qrcode::QRCodeReader, public MultipleBarcodeReader { 27 | public: 28 | QRCodeMultiReader(); 29 | virtual ~QRCodeMultiReader(); 30 | virtual std::vector > decodeMultiple(Ref image, DecodeHints hints); 31 | }; 32 | 33 | } 34 | } 35 | 36 | #endif // __QRCODE_MULTI_READER_H__ 37 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/multi/qrcode/detector/MultiDetector.h: -------------------------------------------------------------------------------- 1 | #ifndef __MULTI_DETECTOR_H__ 2 | #define __MULTI_DETECTOR_H__ 3 | 4 | /* 5 | * Copyright 2011 ZXing authors 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include 21 | #include 22 | #include 23 | 24 | namespace zxing { 25 | namespace multi { 26 | 27 | class MultiDetector : public zxing::qrcode::Detector { 28 | public: 29 | MultiDetector(Ref image); 30 | virtual ~MultiDetector(); 31 | virtual std::vector > detectMulti(DecodeHints hints); 32 | }; 33 | 34 | } 35 | } 36 | 37 | #endif // __MULTI_DETECTOR_H__ 38 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/EAN13Reader.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __EAN_13_READER_H__ 3 | #define __EAN_13_READER_H__ 4 | 5 | /* 6 | * EAN13Reader.h 7 | * ZXing 8 | * 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | 27 | namespace zxing { 28 | namespace oned { 29 | 30 | class EAN13Reader : public UPCEANReader { 31 | private: 32 | std::vector decodeMiddleCounters; 33 | static void determineFirstDigit(std::string& resultString, 34 | int lgPatternFound); 35 | 36 | public: 37 | EAN13Reader(); 38 | 39 | int decodeMiddle(Ref row, 40 | Range const& startRange, 41 | std::string& resultString); 42 | 43 | BarcodeFormat getBarcodeFormat(); 44 | }; 45 | 46 | } 47 | } 48 | 49 | #endif 50 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/EAN8Reader.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __EAN_8_READER_H__ 3 | #define __EAN_8_READER_H__ 4 | 5 | /* 6 | * EAN8Reader.h 7 | * ZXing 8 | * 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | 27 | namespace zxing { 28 | namespace oned { 29 | 30 | class EAN8Reader : public UPCEANReader { 31 | private: 32 | std::vector decodeMiddleCounters; 33 | 34 | public: 35 | EAN8Reader(); 36 | 37 | int decodeMiddle(Ref row, 38 | Range const& startRange, 39 | std::string& resultString); 40 | 41 | BarcodeFormat getBarcodeFormat(); 42 | }; 43 | 44 | } 45 | } 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/MultiFormatOneDReader.h: -------------------------------------------------------------------------------- 1 | #ifndef __MULTI_FORMAT_ONED_READER_H__ 2 | #define __MULTI_FORMAT_ONED_READER_H__ 3 | /* 4 | * MultiFormatOneDReader.h 5 | * ZXing 6 | * 7 | * Copyright 2010 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #include 23 | 24 | namespace zxing { 25 | namespace oned { 26 | class MultiFormatOneDReader : public OneDReader { 27 | 28 | private: 29 | std::vector > readers; 30 | public: 31 | MultiFormatOneDReader(DecodeHints hints); 32 | 33 | Ref decodeRow(int rowNumber, Ref row); 34 | }; 35 | } 36 | } 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/MultiFormatUPCEANReader.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __MULTI_FORMAT_UPC_EAN_READER_H__ 3 | #define __MULTI_FORMAT_UPC_EAN_READER_H__ 4 | /* 5 | * MultiFormatUPCEANReader.h 6 | * ZXing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | 25 | namespace zxing { 26 | namespace oned { 27 | 28 | class UPCEANReader; 29 | 30 | class MultiFormatUPCEANReader : public OneDReader { 31 | private: 32 | std::vector< Ref > readers; 33 | public: 34 | MultiFormatUPCEANReader(DecodeHints hints); 35 | Ref decodeRow(int rowNumber, Ref row); 36 | }; 37 | 38 | } 39 | } 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/OneDResultPoint.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * OneDResultPoint.cpp 3 | * ZXing 4 | * 5 | * Copyright 2010 ZXing authors All rights reserved. 6 | * 7 | * Licensed under the Apache License, Version 2.0 (the "License"); 8 | * you may not use this file except in compliance with the License. 9 | * You may obtain a copy of the License at 10 | * 11 | * http://www.apache.org/licenses/LICENSE-2.0 12 | * 13 | * Unless required by applicable law or agreed to in writing, software 14 | * distributed under the License is distributed on an "AS IS" BASIS, 15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 | * See the License for the specific language governing permissions and 17 | * limitations under the License. 18 | */ 19 | 20 | #include "OneDResultPoint.h" 21 | 22 | namespace zxing { 23 | namespace oned { 24 | 25 | OneDResultPoint::OneDResultPoint(float posX, float posY) : ResultPoint(posX,posY) { 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/OneDResultPoint.h: -------------------------------------------------------------------------------- 1 | #ifndef __ONED_RESULT_POINT_H__ 2 | #define __ONED_RESULT_POINT_H__ 3 | /* 4 | * OneDResultPoint.h 5 | * ZXing 6 | * 7 | * Copyright 2010 ZXing authors All rights reserved. 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | #include 22 | #include 23 | 24 | namespace zxing { 25 | namespace oned { 26 | 27 | class OneDResultPoint : public ResultPoint { 28 | 29 | public: 30 | OneDResultPoint(float posX, float posY); 31 | }; 32 | } 33 | } 34 | 35 | #endif 36 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/oned/UPCEReader.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __UPC_E_READER_H__ 3 | #define __UPC_E_READER_H__ 4 | 5 | /* 6 | * Copyright 2010 ZXing authors All rights reserved. 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #include 22 | #include 23 | 24 | namespace zxing { 25 | namespace oned { 26 | 27 | class UPCEReader : public UPCEANReader { 28 | private: 29 | std::vector decodeMiddleCounters; 30 | static bool determineNumSysAndCheckDigit(std::string& resultString, int lgPatternFound); 31 | 32 | protected: 33 | Range decodeEnd(Ref row, int endStart); 34 | bool checkChecksum(Ref const& s); 35 | public: 36 | UPCEReader(); 37 | 38 | int decodeMiddle(Ref row, Range const& startRange, std::string& resultString); 39 | static Ref convertUPCEtoUPCA(Ref const& upce); 40 | 41 | BarcodeFormat getBarcodeFormat(); 42 | }; 43 | 44 | } 45 | } 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/QRCodeReader.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | #ifndef __QR_CODE_READER_H__ 3 | #define __QR_CODE_READER_H__ 4 | 5 | /* 6 | * QRCodeReader.h 7 | * zxing 8 | * 9 | * Copyright 2010 ZXing authors All rights reserved. 10 | * 11 | * Licensed under the Apache License, Version 2.0 (the "License"); 12 | * you may not use this file except in compliance with the License. 13 | * You may obtain a copy of the License at 14 | * 15 | * http://www.apache.org/licenses/LICENSE-2.0 16 | * 17 | * Unless required by applicable law or agreed to in writing, software 18 | * distributed under the License is distributed on an "AS IS" BASIS, 19 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | * See the License for the specific language governing permissions and 21 | * limitations under the License. 22 | */ 23 | 24 | #include 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | namespace qrcode { 30 | 31 | class QRCodeReader : public Reader { 32 | private: 33 | Decoder decoder_; 34 | 35 | protected: 36 | Decoder& getDecoder(); 37 | 38 | public: 39 | QRCodeReader(); 40 | virtual ~QRCodeReader(); 41 | 42 | Ref decode(Ref image, DecodeHints hints); 43 | }; 44 | 45 | } 46 | } 47 | 48 | #endif // __QR_CODE_READER_H__ 49 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/decoder/DataBlock.h: -------------------------------------------------------------------------------- 1 | #ifndef __DATA_BLOCK_H__ 2 | #define __DATA_BLOCK_H__ 3 | 4 | /* 5 | * DataBlock.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | #include 27 | #include 28 | 29 | namespace zxing { 30 | namespace qrcode { 31 | 32 | class DataBlock : public Counted { 33 | private: 34 | int numDataCodewords_; 35 | ArrayRef codewords_; 36 | 37 | DataBlock(int numDataCodewords, ArrayRef codewords); 38 | 39 | public: 40 | static std::vector > 41 | getDataBlocks(ArrayRef rawCodewords, Version *version, ErrorCorrectionLevel &ecLevel); 42 | 43 | int getNumDataCodewords(); 44 | ArrayRef getCodewords(); 45 | }; 46 | 47 | } 48 | } 49 | 50 | #endif // __DATA_BLOCK_H__ 51 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/decoder/DataMask.h: -------------------------------------------------------------------------------- 1 | #ifndef __DATA_MASK_H__ 2 | #define __DATA_MASK_H__ 3 | 4 | /* 5 | * DataMask.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | 27 | #include 28 | 29 | namespace zxing { 30 | namespace qrcode { 31 | 32 | class DataMask : public Counted { 33 | private: 34 | static std::vector > DATA_MASKS; 35 | 36 | protected: 37 | 38 | public: 39 | static int buildDataMasks(); 40 | DataMask(); 41 | virtual ~DataMask(); 42 | void unmaskBitMatrix(BitMatrix& matrix, size_t dimension); 43 | virtual bool isMasked(size_t x, size_t y) = 0; 44 | static DataMask& forReference(int reference); 45 | }; 46 | 47 | } 48 | } 49 | 50 | #endif // __DATA_MASK_H__ 51 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/decoder/Decoder.h: -------------------------------------------------------------------------------- 1 | #ifndef __DECODER_H__ 2 | #define __DECODER_H__ 3 | 4 | /* 5 | * Decoder.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | #include 27 | #include 28 | 29 | namespace zxing { 30 | namespace qrcode { 31 | 32 | class Decoder { 33 | private: 34 | ReedSolomonDecoder rsDecoder_; 35 | 36 | void correctErrors(ArrayRef bytes, int numDataCodewords); 37 | 38 | public: 39 | Decoder(); 40 | Ref decode(Ref bits); 41 | }; 42 | 43 | } 44 | } 45 | 46 | #endif // __DECODER_H__ 47 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/detector/AlignmentPattern.h: -------------------------------------------------------------------------------- 1 | // -*- mode:c++; tab-width:2; indent-tabs-mode:nil; c-basic-offset:2 -*- 2 | 3 | #ifndef __ALIGNMENT_PATTERN_H__ 4 | #define __ALIGNMENT_PATTERN_H__ 5 | 6 | /* 7 | * AlignmentPattern.h 8 | * zxing 9 | * 10 | * Copyright 2010 ZXing authors All rights reserved. 11 | * 12 | * Licensed under the Apache License, Version 2.0 (the "License"); 13 | * you may not use this file except in compliance with the License. 14 | * You may obtain a copy of the License at 15 | * 16 | * http://www.apache.org/licenses/LICENSE-2.0 17 | * 18 | * Unless required by applicable law or agreed to in writing, software 19 | * distributed under the License is distributed on an "AS IS" BASIS, 20 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 21 | * See the License for the specific language governing permissions and 22 | * limitations under the License. 23 | */ 24 | 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | namespace qrcode { 30 | 31 | class AlignmentPattern : public ResultPoint { 32 | private: 33 | float estimatedModuleSize_; 34 | 35 | public: 36 | AlignmentPattern(float posX, float posY, float estimatedModuleSize); 37 | bool aboutEquals(float moduleSize, float i, float j) const; 38 | Ref combineEstimate(float i, float j, 39 | float newModuleSize) const; 40 | }; 41 | 42 | } 43 | } 44 | 45 | #endif // __ALIGNMENT_PATTERN_H__ 46 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/detector/FinderPatternInfo.h: -------------------------------------------------------------------------------- 1 | #ifndef __FINDER_PATTERN_INFO_H__ 2 | #define __FINDER_PATTERN_INFO_H__ 3 | 4 | /* 5 | * FinderPatternInfo.h 6 | * zxing 7 | * 8 | * Copyright 2010 ZXing authors All rights reserved. 9 | * 10 | * Licensed under the Apache License, Version 2.0 (the "License"); 11 | * you may not use this file except in compliance with the License. 12 | * You may obtain a copy of the License at 13 | * 14 | * http://www.apache.org/licenses/LICENSE-2.0 15 | * 16 | * Unless required by applicable law or agreed to in writing, software 17 | * distributed under the License is distributed on an "AS IS" BASIS, 18 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 19 | * See the License for the specific language governing permissions and 20 | * limitations under the License. 21 | */ 22 | 23 | #include 24 | #include 25 | #include 26 | #include 27 | 28 | namespace zxing { 29 | namespace qrcode { 30 | 31 | class FinderPatternInfo : public Counted { 32 | private: 33 | Ref bottomLeft_; 34 | Ref topLeft_; 35 | Ref topRight_; 36 | 37 | public: 38 | FinderPatternInfo(std::vector > patternCenters); 39 | 40 | Ref getBottomLeft(); 41 | Ref getTopLeft(); 42 | Ref getTopRight(); 43 | }; 44 | } 45 | } 46 | 47 | #endif // __FINDER_PATTERN_INFO_H__ 48 | -------------------------------------------------------------------------------- /LQ3rdparty/QZXing/QZXing/zxing/zxing/qrcode/detector/QRFinderPatternInfo.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * FinderPatternInfo.cpp 3 | * zxing 4 | * 5 | * Created by Christian Brunschen on 13/05/2008. 6 | * Copyright 2008 ZXing authors All rights reserved. 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #include 22 | 23 | namespace zxing { 24 | namespace qrcode { 25 | 26 | FinderPatternInfo::FinderPatternInfo(std::vector > patternCenters) : 27 | bottomLeft_(patternCenters[0]), topLeft_(patternCenters[1]), topRight_(patternCenters[2]) { 28 | } 29 | 30 | Ref FinderPatternInfo::getBottomLeft() { 31 | return bottomLeft_; 32 | } 33 | Ref FinderPatternInfo::getTopLeft() { 34 | return topLeft_; 35 | } 36 | Ref FinderPatternInfo::getTopRight() { 37 | return topRight_; 38 | } 39 | 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /LQChart/LQChart.pro: -------------------------------------------------------------------------------- 1 | #------------------------------------------------- 2 | # 3 | # Project created by QtCreator 2017-03-21T23:01:24 4 | # 5 | #------------------------------------------------- 6 | #常见的图表类控件集合(各种折线图,条形图,饼图……) 7 | include($$PWD/../LQGlobal.pri) 8 | QT -= gui 9 | 10 | TARGET = LQChart$${FILE_POSTFIX} 11 | TEMPLATE = lib 12 | 13 | DEFINES += LQCHART_LIBRARY 14 | 15 | #include ($$PWD/lqchart_src.pri) 16 | 17 | INCLUDEPATH +=$$PWD/inc 18 | 19 | 20 | SOURCES += \ 21 | $$PWD/src/lqchart.cpp \ 22 | src/CustomeTableView.cpp 23 | 24 | HEADERS += \ 25 | StdMain.h \ 26 | inc/LQChartInc.h \ 27 | inc/LQChartIncLib.h \ 28 | $$PWD/inc/lqchart_global.h \ 29 | $$PWD/inc/lqchart.h \ 30 | $$PWD/inc/CustomeTableView.h 31 | 32 | QT += widgets 33 | 34 | 35 | -------------------------------------------------------------------------------- /LQChart/StdMain.h: -------------------------------------------------------------------------------- 1 | #ifndef STDMAIN_H 2 | #define STDMAIN_H 3 | 4 | #include "inc/lqchart_global.h" 5 | 6 | #include "inc/LQChartInc.h" 7 | 8 | #endif // STDMAIN_H 9 | -------------------------------------------------------------------------------- /LQChart/inc/LQChartInc.h: -------------------------------------------------------------------------------- 1 | #ifndef LQCHARTINC_H 2 | #define LQCHARTINC_H 3 | 4 | #include "lqchart_global.h" 5 | #include "lqchart.h" 6 | #include "CustomeTableView.h" 7 | 8 | #endif // LQCHARTINC_H 9 | -------------------------------------------------------------------------------- /LQChart/inc/LQChartIncLib.h: -------------------------------------------------------------------------------- 1 | #ifndef LQCHARTINCLIB_H 2 | #define LQCHARTINCLIB_H 3 | 4 | #include "lqchart_global.h" 5 | #include "LQChartInc.h" 6 | 7 | #endif // LQCHARTINCLIB_H 8 | -------------------------------------------------------------------------------- /LQChart/inc/lqchart.h: -------------------------------------------------------------------------------- 1 | #ifndef LQCHART_H 2 | #define LQCHART_H 3 | 4 | 5 | class LQCHARTSHARED_EXPORT LQChart 6 | { 7 | 8 | public: 9 | LQChart(); 10 | ~LQChart(); 11 | }; 12 | 13 | #endif // LQCHART_H 14 | -------------------------------------------------------------------------------- /LQChart/inc/lqchart_global.h: -------------------------------------------------------------------------------- 1 | #ifndef LQCHART_GLOBAL_H 2 | #define LQCHART_GLOBAL_H 3 | 4 | #include 5 | 6 | #if defined(LQCHART_LIBRARY) 7 | # define LQCHARTSHARED_EXPORT Q_DECL_EXPORT 8 | #else 9 | # define LQCHARTSHARED_EXPORT Q_DECL_IMPORT 10 | #endif 11 | 12 | #endif // LQCHART_GLOBAL_H 13 | -------------------------------------------------------------------------------- /LQChart/lqchart_inc.pri: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQChart/lqchart_inc.pri -------------------------------------------------------------------------------- /LQChart/lqchart_src.pri: -------------------------------------------------------------------------------- 1 | HEADERS += \ 2 | $$PWD/inc/lqchart.h \ 3 | $$PWD/inc/lqchart_global.h 4 | 5 | SOURCES += \ 6 | $$PWD/src/lqchart.cpp 7 | -------------------------------------------------------------------------------- /LQChart/src/CustomeTableView.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQChart/src/CustomeTableView.h -------------------------------------------------------------------------------- /LQChart/src/lqchart.cpp: -------------------------------------------------------------------------------- 1 | #include "StdMain.h" 2 | 3 | #include "lqchart.h" 4 | 5 | 6 | LQChart::LQChart() 7 | { 8 | } 9 | 10 | LQChart::~LQChart() 11 | { 12 | // 13 | } 14 | -------------------------------------------------------------------------------- /LQFormWidget/StdMain.h: -------------------------------------------------------------------------------- 1 | #ifndef STDMAIN_H 2 | #define STDMAIN_H 3 | 4 | #include "inc/lqformwidget_global.h" 5 | 6 | #include "inc/LQFormWidgetInc.h" 7 | 8 | #endif // STDMAIN_H 9 | -------------------------------------------------------------------------------- /LQFormWidget/inc/LQFormWidgetInc.h: -------------------------------------------------------------------------------- 1 | #ifndef LQFORMWIDGETINC_H 2 | #define LQFORMWIDGETINC_H 3 | 4 | #include "cmysplashscreen.h" 5 | #include "gradientcombobox.h" 6 | #include "ipaddresswidget.h" 7 | #include "lqformwidget.h" 8 | #include "lqformwidget.h" 9 | #include "lqstartwidget.h" 10 | #include "msgboxbase.h" 11 | #include "navlistview.h" 12 | #include "nbaseswitchbutton.h" 13 | #include "searchlineedit.h" 14 | #include "tolerancebar.h" 15 | 16 | #endif // LQFORMWIDGETINC_H 17 | -------------------------------------------------------------------------------- /LQFormWidget/inc/LQFormWidgetIncLib.h: -------------------------------------------------------------------------------- 1 | #ifndef LQFORMWIDGETINCLIB_H 2 | #define LQFORMWIDGETINCLIB_H 3 | 4 | #include "lqformwidget_global.h" 5 | 6 | #include "LQFormWidgetInc.h" 7 | 8 | #endif // LQFORMWIDGETINCLIB_H 9 | -------------------------------------------------------------------------------- /LQFormWidget/inc/drawprogressbar/drawprogressbar.h: -------------------------------------------------------------------------------- 1 | #ifndef DRAWPROGRESSBAR_H 2 | #define DRAWPROGRESSBAR_H 3 | 4 | #define RECT_WIDTH 40 //第一个圆中心点到左边界的距离 5 | #define iMaxNum 5 //定义最大阶段数 6 | #include 7 | 8 | class QPushButton; 9 | 10 | #include 11 | 12 | class LQFORMWIDGETSHARED_EXPORT DrawProgressBar : public QWidget 13 | { 14 | Q_OBJECT 15 | 16 | public: 17 | DrawProgressBar(QWidget *parent = 0); 18 | ~DrawProgressBar(); 19 | void setValue(int value); 20 | 21 | private: 22 | void init(); 23 | void drawBackground(QPainter* painter); //绘制整个背景颜色 24 | void drawBarBackground(QPainter* painter); //绘制灰色的导航条:包括灰色的圆,灰色的长条矩形和灰色的text 25 | void drawBlueBar(QPainter* painter); //绘制蓝色信息:圆、长条和本文 26 | void drawBarNumber(QPainter* painter); //绘制数字 27 | 28 | //绘制多边形测试用 29 | void drawPolygonTest(QPainter* painter); 30 | 31 | protected: 32 | void paintEvent(QPaintEvent *event); 33 | QSize sizeHint() const 34 | { 35 | return QSize(800,600); 36 | } 37 | 38 | private: 39 | int m_value; //设置当前值大小 40 | int iBigRadius; //灰色的圆半径 41 | int iSmallRadius; //蓝色的圆半径 42 | 43 | int rectHight; //连接两圆之间矩形的高度 44 | int rectWidth; //连接两圆之间矩形的宽度 45 | int rectBlueHight; //定义蓝色矩形的高度比灰色少2 46 | 47 | QStringList strlist; //显示进度条下方的文本 48 | QStringList str_list2; //显示在进度条上方,椭圆形中文本 49 | 50 | }; 51 | 52 | #endif // DRAWPROGRESSBAR_H 53 | -------------------------------------------------------------------------------- /LQFormWidget/inc/gradientcombobox.h: -------------------------------------------------------------------------------- 1 | #ifndef GRADIENTCOMBOBOX_H 2 | #define GRADIENTCOMBOBOX_H 3 | 4 | #include 5 | 6 | class QListWidgetItem; 7 | class GradientComboBoxPrivate; 8 | class LQFORMWIDGETSHARED_EXPORT GradientComboBox : public QComboBox 9 | { 10 | Q_OBJECT 11 | public: 12 | explicit GradientComboBox(QWidget* parent = Q_NULLPTR); 13 | ~GradientComboBox(); 14 | 15 | void setCurrentIndex(int index); 16 | int currentIndex() const; 17 | 18 | QString currentName() const; 19 | QColor currentColor1() const; 20 | QColor currentColor2() const; 21 | 22 | static QPair colorPair(int index); 23 | 24 | void showPopup(); 25 | void hidePopup(); 26 | 27 | protected: 28 | void paintEvent(QPaintEvent *e); 29 | void resizeEvent(QResizeEvent* e); 30 | QSize minimumSizeHint() const; 31 | 32 | private slots: 33 | void onActivated(int index); 34 | 35 | private: 36 | GradientComboBoxPrivate* d_ptr; 37 | Q_DISABLE_COPY(GradientComboBox) 38 | }; 39 | #endif // GRADIENTCOMBOBOX_H 40 | -------------------------------------------------------------------------------- /LQFormWidget/inc/ipaddresswidget.h: -------------------------------------------------------------------------------- 1 | #ifndef IPADDRESSWIDGET_H 2 | #define IPADDRESSWIDGET_H 3 | 4 | #include 5 | 6 | class QSpinBox; 7 | class QLabel; 8 | class QHBoxLayout; 9 | 10 | 11 | class LQFORMWIDGETSHARED_EXPORT IpAddressWidget : public QWidget 12 | { 13 | Q_OBJECT 14 | public: 15 | explicit IpAddressWidget(QWidget *parent = 0); 16 | ~IpAddressWidget(); 17 | 18 | /** 19 | @brief getIpAddress() 获取IP地址 20 | */ 21 | QString getIpAddress (); 22 | 23 | void setSeparator (const QString &separator); 24 | 25 | protected: 26 | bool eventFilter (QObject *obj, QEvent *event); 27 | 28 | 29 | private: 30 | void init(); 31 | 32 | Q_SIGNALS: 33 | 34 | private Q_SLOTS: 35 | 36 | private: 37 | QHBoxLayout *m_pHMainLayout; //主布局 38 | QSpinBox *m_pSpinBox[4]; //IP数字输入框 39 | QLabel *m_pLabel[3]; //.号 40 | QString m_Separator; //四个数字之间的间隔 41 | }; 42 | 43 | #endif // IPADDRESSWIDGET_H 44 | -------------------------------------------------------------------------------- /LQFormWidget/inc/lqformwidget.h: -------------------------------------------------------------------------------- 1 | #ifndef LQFORMWIDGET_H 2 | #define LQFORMWIDGET_H 3 | 4 | 5 | class LQFORMWIDGETSHARED_EXPORT LQFormWidget 6 | { 7 | 8 | public: 9 | LQFormWidget(); 10 | }; 11 | 12 | #endif // LQFORMWIDGET_H 13 | -------------------------------------------------------------------------------- /LQFormWidget/inc/lqformwidget_global.h: -------------------------------------------------------------------------------- 1 | #ifndef LQFORMWIDGET_GLOBAL_H 2 | #define LQFORMWIDGET_GLOBAL_H 3 | 4 | #include 5 | 6 | #if defined(LQFORMWIDGET_LIBRARY) 7 | # define LQFORMWIDGETSHARED_EXPORT Q_DECL_EXPORT 8 | #else 9 | # define LQFORMWIDGETSHARED_EXPORT Q_DECL_IMPORT 10 | #endif 11 | 12 | #endif // LQFORMWIDGET_GLOBAL_H 13 | -------------------------------------------------------------------------------- /LQFormWidget/inc/lqstartwidget.h: -------------------------------------------------------------------------------- 1 | #ifndef LQSTARTWIDGET_H 2 | #define LQSTARTWIDGET_H 3 | 4 | #include 5 | 6 | class QGridLayout; 7 | class QLabel; 8 | class QTimer; 9 | 10 | class LQFORMWIDGETSHARED_EXPORT LQStartWidget : public QWidget 11 | { 12 | Q_OBJECT 13 | public: 14 | explicit LQStartWidget(QWidget *parent = 0); 15 | ~LQStartWidget(); 16 | 17 | /** 18 | @breif:设置加载文本 19 | */ 20 | void setLoadText(const QString &title); 21 | 22 | /** 23 | @breif:设置加载时间 24 | */ 25 | void setLoadTime(int count); 26 | 27 | void setStartShow(); 28 | 29 | private: 30 | void init(); 31 | 32 | void initWidget(); 33 | 34 | protected: 35 | virtual void mousePressEvent (QMouseEvent *event); 36 | 37 | virtual void mouseMoveEvent (QMouseEvent *event); 38 | 39 | virtual void paintEvent (QPaintEvent *event); 40 | 41 | Q_SIGNALS: 42 | void signalLoadFinish(); 43 | 44 | private Q_SLOTS: 45 | void slotLoading(); 46 | 47 | void slotCountShow(); 48 | 49 | private: 50 | QGridLayout *m_pGridLayout; 51 | QLabel *m_pLabelNum; 52 | QLabel *m_pLabelLoadText; 53 | 54 | QPoint m_pWindowPos; 55 | QPoint m_pMousePos; 56 | QPoint m_pDPos; 57 | 58 | QImage *m_pImage; 59 | 60 | QTimer *m_pLoadTime; 61 | QTimer *m_pCountTime; 62 | 63 | int m_w; 64 | int m_h; 65 | int m_dig; 66 | 67 | int m_count; 68 | }; 69 | 70 | #endif // LQSTARTWIDGET_H 71 | -------------------------------------------------------------------------------- /LQFormWidget/inc/messageWidget/messagetitle.h: -------------------------------------------------------------------------------- 1 | #ifndef MESSAGETITLE_H 2 | #define MESSAGETITLE_H 3 | 4 | #include 5 | 6 | #include "../lqformwidget_global.h" 7 | 8 | class QLabel; 9 | class QPushButton; 10 | class QHBoxLayout; 11 | 12 | class LQFORMWIDGETSHARED_EXPORT MessageTitle : public QWidget 13 | { 14 | Q_OBJECT 15 | public: 16 | explicit MessageTitle(QWidget *parent = 0); 17 | ~MessageTitle(); 18 | 19 | void setTitleText(const QString &); 20 | 21 | signals: 22 | void signal_Close(); 23 | 24 | public slots: 25 | 26 | private: 27 | void initForm(); 28 | void initLayout(); 29 | void initConnect(); 30 | 31 | protected: 32 | void paintEvent (QPaintEvent*); 33 | 34 | private: 35 | QLabel *m_pTitleLabel; 36 | QPushButton *m_pPbnClose; 37 | QHBoxLayout *m_pLayout; 38 | }; 39 | 40 | #endif // MESSAGETITLE_H 41 | -------------------------------------------------------------------------------- /LQFormWidget/inc/messageWidget/messagewidget.h: -------------------------------------------------------------------------------- 1 | #ifndef MESSAGEWIDGET_H 2 | #define MESSAGEWIDGET_H 3 | 4 | #include 5 | 6 | #include "../lqformwidget_global.h" 7 | 8 | class MessageTitle; 9 | class QVBoxLayout; 10 | class QLabel; 11 | class QTimer; 12 | 13 | class LQFORMWIDGETSHARED_EXPORT MessageWidget : public QWidget 14 | { 15 | Q_OBJECT 16 | public: 17 | explicit MessageWidget(QWidget *parent = 0); 18 | ~MessageWidget(); 19 | //显示消息 20 | void showMsg(const QString &iconPath, 21 | const QString &title, 22 | const QString &content); 23 | void showMessage(); 24 | signals: 25 | 26 | public slots: 27 | void slot_MyMove(); 28 | void slot_myState(); 29 | void slot_myClose(); 30 | 31 | private: 32 | void initForm(); 33 | void initLayout(); 34 | void initConnect(); 35 | 36 | protected: 37 | void paintEvent (QPaintEvent*); 38 | 39 | private: 40 | MessageTitle *m_pTitle; 41 | QLabel *m_pContentLabel; 42 | QTimer *m_pTimerShow; 43 | QTimer *m_pTimerStay; 44 | QTimer *m_pTimerClose; 45 | QLabel *m_pIconLabel; 46 | 47 | int m_time_count; 48 | int m_desktop_height; 49 | float m_transparent; 50 | QPoint m_normal_point; 51 | QRect m_desk_rect; 52 | 53 | QVBoxLayout *m_pMainLayout; 54 | 55 | }; 56 | 57 | #endif // MESSAGEWIDGET_H 58 | -------------------------------------------------------------------------------- /LQFormWidget/inc/messageWidget/readme.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQFormWidget/inc/messageWidget/readme.txt -------------------------------------------------------------------------------- /LQFormWidget/inc/msgNotify/notify.h: -------------------------------------------------------------------------------- 1 | #ifndef NOTIFY_H 2 | #define NOTIFY_H 3 | 4 | #include 5 | #include 6 | #include 7 | #include 8 | 9 | class Notify : public QWidget 10 | { 11 | Q_OBJECT 12 | public: 13 | explicit Notify(int displayTime, QWidget *parent = 0); 14 | 15 | void setIcon(const QString &value); 16 | 17 | void setTitle(const QString &value); 18 | 19 | void setBody(const QString &value); 20 | 21 | void setUrl(const QString &value); 22 | 23 | void showGriant(); 24 | 25 | Q_SIGNALS: 26 | void disappeared(); 27 | 28 | private: 29 | 30 | int displayTime; 31 | 32 | QString icon; 33 | QString title; 34 | QString body; 35 | QString url; 36 | 37 | QLabel *backgroundLabel; 38 | QLabel *iconLabel; 39 | QLabel *titleLabel; 40 | QLabel *bodyLabel; 41 | 42 | QPushButton *closeBtn; 43 | 44 | void hideGriant(); 45 | 46 | void mousePressEvent(QMouseEvent *event); 47 | }; 48 | 49 | #endif // NOTIFY_H 50 | -------------------------------------------------------------------------------- /LQFormWidget/inc/msgNotify/notifymanager.h: -------------------------------------------------------------------------------- 1 | #ifndef NOTIFYMANAGER_H 2 | #define NOTIFYMANAGER_H 3 | 4 | #include 5 | #include 6 | 7 | #include "notify.h" 8 | #include "./lqformwidget_global.h" 9 | 10 | class LQFORMWIDGETSHARED_EXPORT NotifyManager : public QObject 11 | { 12 | Q_OBJECT 13 | public: 14 | explicit NotifyManager( QObject *parent = 0); 15 | 16 | void notify(const QString &title, const QString &body, 17 | const QString &icon, const QString url); 18 | void setMaxCount(int count); 19 | void setDisplayTime(int ms); 20 | 21 | private: 22 | class NotifyData { 23 | public: 24 | NotifyData(const QString &icon, const QString &title, 25 | const QString &body, const QString url): 26 | icon(icon), 27 | title(title), 28 | body(body), 29 | url(url) 30 | { 31 | } 32 | 33 | QString icon; 34 | QString title; 35 | QString body; 36 | QString url; 37 | }; 38 | 39 | void rearrange(); 40 | void showNext(); 41 | 42 | QQueue dataQueue; 43 | QList notifyList; 44 | int maxCount; 45 | int displayTime; 46 | }; 47 | 48 | #endif // NOTIFYMANAGER_H 49 | -------------------------------------------------------------------------------- /LQFormWidget/inc/nbaseswitchbutton.h: -------------------------------------------------------------------------------- 1 | #ifndef NBASESWITCHBUTTON_H 2 | #define NBASESWITCHBUTTON_H 3 | 4 | /** 5 | * 作者: daodaoliang 6 | * 时间: 2016年9月05日 7 | * 邮箱: daodaoliang@yeah.net 8 | */ 9 | 10 | #include 11 | #include 12 | #include 13 | #include 14 | 15 | 16 | /** 17 | * @brief The NBaseSwitchButton class switch button 18 | */ 19 | class LQFORMWIDGETSHARED_EXPORT NBaseSwitchButton : public QWidget 20 | { 21 | Q_OBJECT 22 | public: 23 | explicit NBaseSwitchButton(QWidget *parent = 0); 24 | 25 | protected: 26 | void mousePressEvent(QMouseEvent *event); 27 | void mouseMoveEvent(QMouseEvent *event); 28 | void mouseReleaseEvent(QMouseEvent *event); 29 | void paintEvent(QPaintEvent *event); 30 | 31 | private: 32 | void drawPressBackground(QPainter *painter); 33 | void drawPressSlide(QPainter *painter); 34 | 35 | private: 36 | QColor mOffBgcBegin; 37 | QColor mOffBgcEnd; 38 | QColor mOnBgcBegin; 39 | QColor mOnBgcEnd; 40 | QColor mSlideONCBegin; 41 | QColor mSlideONCEnd; 42 | QColor mSlidOFFCBegin; 43 | QColor mSlidOFFCEnd; 44 | bool mState; 45 | bool mMouseDown; 46 | bool mMouseMove; 47 | bool mMouseUp; 48 | QPoint firstPoint; 49 | QPoint lastPoint; 50 | }; 51 | 52 | #endif // NBASESWITCHBUTTON_H 53 | -------------------------------------------------------------------------------- /LQFormWidget/inc/searchlineedit.h: -------------------------------------------------------------------------------- 1 | /************************************************* 2 | Copyright:kevin 3 | Author:Kevin LiQi 4 | Date:2016-03-11 5 | Email:kevinlq0912@163.com 6 | QQ:936563422 7 | Version:V1.0 8 | Description:自定义搜索框的实现 9 | **************************************************/ 10 | #ifndef SEARCHLINEEDIT_H 11 | #define SEARCHLINEEDIT_H 12 | #include 13 | #include 14 | class QToolButton; 15 | class QHBoxLayout; 16 | class QWidget; 17 | 18 | 19 | class LQFORMWIDGETSHARED_EXPORT SearchLineEdit : public QLineEdit 20 | { 21 | Q_OBJECT 22 | public: 23 | SearchLineEdit(QWidget *parent = 0); 24 | ~SearchLineEdit(); 25 | 26 | void initForm(); 27 | void initConnect(); 28 | void translator(); 29 | protected: 30 | virtual void focusInEvent(QFocusEvent * event); 31 | virtual void focusOutEvent(QFocusEvent * event); 32 | 33 | private Q_SLOTS: 34 | void slotSendSearchContent(); 35 | Q_SIGNALS: 36 | void signalSearchContent(const QString &test); 37 | 38 | private: 39 | QToolButton *m_tbnSearch; 40 | QHBoxLayout *m_mainLayout; 41 | }; 42 | 43 | #endif // SEARCHLINEEDIT_H 44 | -------------------------------------------------------------------------------- /LQFormWidget/inc/tabWidget/customtabstyle.h: -------------------------------------------------------------------------------- 1 | #ifndef CUSTOMTABSTYLE_H 2 | #define CUSTOMTABSTYLE_H 3 | 4 | #include 5 | #include 6 | 7 | //#include "../lqformwidget_global.h" 8 | 9 | class CustomTabStyle : public QProxyStyle 10 | { 11 | Q_OBJECT 12 | public: 13 | CustomTabStyle(); 14 | ~CustomTabStyle(); 15 | 16 | QSize sizeFromContents(ContentsType type, const QStyleOption *option, 17 | const QSize &size, const QWidget *widget) const; 18 | 19 | void drawControl(ControlElement element,const QStyleOption *option, 20 | QPainter *painter, const QWidget *widget) const; 21 | }; 22 | 23 | #endif // CUSTOMTABSTYLE_H 24 | -------------------------------------------------------------------------------- /LQFormWidget/inc/tabWidget/mytabwidget.h: -------------------------------------------------------------------------------- 1 | #ifndef MYTABWIDGET_H 2 | #define MYTABWIDGET_H 3 | 4 | #include 5 | #include "../lqformwidget_global.h" 6 | 7 | class LQFORMWIDGETSHARED_EXPORT MyTabWidget : public QTabWidget 8 | { 9 | Q_OBJECT 10 | public: 11 | explicit MyTabWidget(QWidget *parent = 0); 12 | ~MyTabWidget(); 13 | }; 14 | 15 | #endif // MYTABWIDGET_H 16 | -------------------------------------------------------------------------------- /LQFormWidget/inc/tolerancebar.h: -------------------------------------------------------------------------------- 1 | #ifndef TOLERANCEBAR_H 2 | #define TOLERANCEBAR_H 3 | 4 | #include 5 | 6 | 7 | struct TolerDataPrivate; 8 | 9 | class LQFORMWIDGETSHARED_EXPORT ToleranceBar : public QWidget 10 | { 11 | Q_OBJECT 12 | public: 13 | explicit ToleranceBar(QWidget *parent = 0); 14 | ~ToleranceBar(); 15 | 16 | private: 17 | void init(); 18 | 19 | Q_SIGNALS: 20 | void signalSendValue(const int &value); 21 | 22 | public Q_SLOTS: 23 | 24 | protected: 25 | void mousePressEvent(QMouseEvent * qevent); 26 | 27 | void mouseMoveEvent(QMouseEvent *qevent); 28 | 29 | void mouseReleaseEvent(QMouseEvent *qevent); 30 | 31 | void paintEvent(QPaintEvent *); 32 | 33 | private: 34 | TolerDataPrivate *d; 35 | }; 36 | 37 | #endif // TOLERANCEBAR_H 38 | -------------------------------------------------------------------------------- /LQFormWidget/lqformwidget_inc.pri: -------------------------------------------------------------------------------- 1 | INCLUDEPATH +=\ 2 | $$PWD/inc \ 3 | $$PWD/inc/drawprogressbar \ 4 | $$PWD/inc/msgNitify \ 5 | $$PWD/inc/tabWidget 6 | -------------------------------------------------------------------------------- /LQFormWidget/lqformwidget_src.pri: -------------------------------------------------------------------------------- 1 | HEADERS += \ 2 | $$PWD/inc/lqformwidget.h \ 3 | $$PWD/inc/lqformwidget_global.h \ 4 | $$PWD/inc/searchlineedit.h \ 5 | $$PWD/inc/gradientcombobox.h \ 6 | $$PWD/inc/cmysplashscreen.h \ 7 | $$PWD/inc/nbaseswitchbutton.h \ 8 | $$PWD/inc/msgboxbase.h \ 9 | $$PWD/inc/messageWidget/messagetitle.h \ 10 | $$PWD/inc/messageWidget/messagewidget.h \ 11 | $$PWD/inc/lqstartwidget.h \ 12 | $$PWD/inc/drawprogressbar/drawprogressbar.h \ 13 | $$PWD/inc/ipaddresswidget.h \ 14 | $$PWD/inc/msgNotify/notifymanager.h \ 15 | $$PWD/inc/msgNotify/notify.h \ 16 | $$PWD/inc/navlistview.h \ 17 | $$PWD/inc/tabWidget/customtabstyle.h \ 18 | $$PWD/inc/tabWidget/mytabwidget.h \ 19 | $$PWD/inc/tolerancebar.h 20 | 21 | SOURCES += \ 22 | $$PWD/src/lqformwidget.cpp \ 23 | $$PWD/src/searchlineedit.cpp \ 24 | $$PWD/src/gradientcombobox.cpp \ 25 | $$PWD/src/cmysplashscreen.cpp \ 26 | $$PWD/src/nbaseswitchbutton.cpp \ 27 | $$PWD/src/msgboxbase.cpp \ 28 | $$PWD/src/messageWidget/messagetitle.cpp \ 29 | $$PWD/src/messageWidget/messagewidget.cpp \ 30 | $$PWD/src/lqstartwidget.cpp \ 31 | $$PWD/src/drawprogressbar/drawprogressbar.cpp \ 32 | $$PWD/src/ipaddresswidget.cpp \ 33 | $$PWD/src/msgNotify/notify.cpp \ 34 | $$PWD/src/msgNotify/notifymanager.cpp \ 35 | $$PWD/src/navlistview.cpp \ 36 | $$PWD/src/tabWidget/customtabstyle.cpp \ 37 | $$PWD/src/tabWidget/mytabwidget.cpp \ 38 | $$PWD/src/tolerancebar.cpp 39 | -------------------------------------------------------------------------------- /LQFormWidget/src/lqformwidget.cpp: -------------------------------------------------------------------------------- 1 | #include "StdMain.h" 2 | 3 | #include "lqformwidget.h" 4 | 5 | 6 | LQFormWidget::LQFormWidget() 7 | { 8 | } 9 | -------------------------------------------------------------------------------- /LQFormWidget/src/messageWidget/2016-11-11_23-37-42.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQFormWidget/src/messageWidget/2016-11-11_23-37-42.png -------------------------------------------------------------------------------- /LQFormWidget/src/messageWidget/readme.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQFormWidget/src/messageWidget/readme.txt -------------------------------------------------------------------------------- /LQFormWidget/src/tabWidget/mytabwidget.cpp: -------------------------------------------------------------------------------- 1 | #include "tabWidget/mytabwidget.h" 2 | 3 | #include 4 | #include "tabWidget/customtabstyle.h" 5 | 6 | MyTabWidget::MyTabWidget(QWidget *parent) 7 | :QTabWidget(parent) 8 | { 9 | setTabPosition(QTabWidget::West); 10 | 11 | tabBar()->setStyle(new CustomTabStyle); 12 | } 13 | 14 | MyTabWidget::~MyTabWidget() 15 | { 16 | } 17 | -------------------------------------------------------------------------------- /LQFramKit.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | 3 | SUBDIRS += \ 4 | $$PWD/LQ3rdparty/LQ3rdparty.pro \ 5 | $$PWD/LQMisc/LQMisc.pro \ 6 | $$PWD/LQInstrumentation/LQInstrumentation.pro \ 7 | $$PWD/LQFormWidget/LQFormWidget.pro \ 8 | $$PWD/LQChart/LQChart.pro \ 9 | $$PWD/LQTools/LQTools.pro \ 10 | $$PWD/Exmaple/Exmaple.pro 11 | 12 | CONFIG +=ordered 13 | 14 | -------------------------------------------------------------------------------- /LQGlobal.pri: -------------------------------------------------------------------------------- 1 | # Config Para 2 | CONFIG(debug, debug|release):{ 3 | FILE_POSTFIX = D 4 | DIR_COMPILEMODE = Debug 5 | } 6 | else:CONFIG(release, debug|release):{ 7 | FILE_POSTFIX = 8 | DIR_COMPILEMODE = Release 9 | } 10 | 11 | win32:{ 12 | CONFIG(MinGW, MinGW|MSVC):{ 13 | DIR_COMPILER = MinGW 14 | FILE_LIB_PREFIX = lib 15 | FILE_LIB_EXT = .a 16 | } 17 | else:CONFIG(MSVC, MinGW|MSVC):{ 18 | DIR_COMPILER = MSVC 19 | FILE_LIB_PREFIX = 20 | FILE_LIB_EXT = .lib 21 | } 22 | 23 | DIR_PLATFORM = Win32 24 | FILE_DLL_PREFIX = 25 | FILE_DLL_EXT = .dll 26 | } 27 | else:mac:{ 28 | CONFIG(clang, clang):{ 29 | DIR_COMPILER = clang 30 | } 31 | 32 | DEFINES += MAC 33 | DIR_PLATFORM = MAC 34 | FILE_LIB_PREFIX = lib 35 | FILE_LIB_EXT = .a 36 | FILE_DLL_PREFIX = lib 37 | FILE_DLL_EXT = .so 38 | } 39 | else:linux:{ 40 | CONFIG(GCC, GCC|GCC32|GCC64):{ 41 | DIR_COMPILER = GCC 42 | } 43 | else:CONFIG(GCC32, GCC|GCC32|GCC64):{ 44 | DIR_COMPILER = GCC32 45 | } 46 | else:CONFIG(GCC64, GCC|GCC32|GCC64):{ 47 | DIR_COMPILER = GCC64 48 | } 49 | 50 | DIR_PLATFORM = Linux 51 | FILE_LIB_PREFIX = lib 52 | FILE_LIB_EXT = .a 53 | FILE_DLL_PREFIX = lib 54 | FILE_DLL_EXT = .so 55 | } 56 | 57 | 58 | DESTDIR = $$PWD/Bin/$${DIR_PLATFORM}/Client/$${DIR_COMPILER}/$${DIR_COMPILEMODE} 59 | 60 | DIR_DEPEND_DEST = $$PWD/Bin/$${DIR_PLATFORM}/Client/$${DIR_COMPILER}/$${DIR_COMPILEMODE} 61 | 62 | -------------------------------------------------------------------------------- /LQInclude/IncludeGlobal/GlobalInc.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBAL_INC_H 2 | #define GLOBAL_INC_H 3 | 4 | #if defined (STATIC_LIBRARY) && defined (Q_OS_WIN) 5 | #define LQ_DECL_EXPORT 6 | #define LQ_DECL_IMPORT 7 | #else 8 | #include 9 | 10 | #define LQ_DECL_EXPORT Q_DECL_EXPORT 11 | #define LQ_DECL_IMPORT Q_DECL_IMPORT 12 | 13 | #endif 14 | 15 | #endif //GLOBAL_INC_H 16 | -------------------------------------------------------------------------------- /LQInstrumentation/StdMain.h: -------------------------------------------------------------------------------- 1 | #ifndef STDMAIN_H 2 | #define STDMAIN_H 3 | 4 | #include "inc/lqinstrumentation_global.h" 5 | 6 | #include "inc/LQInstrumenttationInc.h" 7 | 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | 17 | #include 18 | 19 | #include 20 | 21 | #include 22 | 23 | #endif // STDMAIN_H 24 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/LQInstrumenttationInc.h: -------------------------------------------------------------------------------- 1 | #ifndef LQINSTRUMENTTATIONINC_H 2 | #define LQINSTRUMENTTATIONINC_H 3 | 4 | #include "airspeedgaugewidget.h" 5 | #include "attitudemeter.h" 6 | #include "colorprogressbar.h" 7 | #include "compasswidget.h" 8 | #include "lqinstrumentation.h" 9 | #include "lwaveupprogress.h" 10 | #include "myspeedwatch.h" 11 | #include "qcgaugewidget.h" 12 | #include "QRoundProgressBar.h" 13 | #include "speedgaugewidget.h" 14 | 15 | #endif // LQINSTRUMENTTATIONINC_H 16 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/LQInstrumenttationIncLib.h: -------------------------------------------------------------------------------- 1 | #ifndef LQINSTRUMENTTATIONINCLIB_H 2 | #define LQINSTRUMENTTATIONINCLIB_H 3 | 4 | #include "lqinstrumentation_global.h" 5 | 6 | #include "LQInstrumenttationInc.h" 7 | 8 | #endif // LQINSTRUMENTTATIONINCLIB_H 9 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/airspeedgaugewidget.h: -------------------------------------------------------------------------------- 1 | #ifndef AIRSPEEDGAUGEWIDGET_H 2 | #define AIRSPEEDGAUGEWIDGET_H 3 | 4 | #include 5 | 6 | class QcGaugeWidget; 7 | class QcNeedleItem; 8 | class QVBoxLayout; 9 | 10 | class LQINSTRUMENTATIONSHARED_EXPORT AirSpeedGaugeWidget : public QWidget 11 | { 12 | Q_OBJECT 13 | public: 14 | explicit AirSpeedGaugeWidget(QWidget *parent = 0); 15 | ~AirSpeedGaugeWidget(); 16 | 17 | void setCurrentValue(int value); 18 | 19 | private: 20 | void init(); 21 | 22 | Q_SIGNALS: 23 | 24 | private Q_SLOTS: 25 | 26 | private: 27 | QcGaugeWidget *m_pAirspeedGauge; 28 | QcNeedleItem *m_pAirspeedNeedle; 29 | 30 | QVBoxLayout *m_pMainLayout; 31 | }; 32 | 33 | #endif // AIRSPEEDGAUGEWIDGET_H 34 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/attitudemeter.h: -------------------------------------------------------------------------------- 1 | #ifndef ATTITUDEMETER_H 2 | #define ATTITUDEMETER_H 3 | 4 | #include 5 | 6 | 7 | #include "qcgaugewidget.h" 8 | 9 | class QVBoxLayout; 10 | 11 | class LQINSTRUMENTATIONSHARED_EXPORT AttitudeMeter : public QWidget 12 | { 13 | Q_OBJECT 14 | public: 15 | explicit AttitudeMeter(QWidget *parent = 0); 16 | ~AttitudeMeter(); 17 | 18 | void setCurrentValue(int value); 19 | 20 | void setCurrentPitch(int value); 21 | 22 | private: 23 | void init(); 24 | 25 | Q_SIGNALS: 26 | 27 | private Q_SLOTS: 28 | 29 | private: 30 | QcGaugeWidget *m_pAttitudeGauge; 31 | QcNeedleItem *m_pAttitudeNeedle; 32 | QcAttitudeMeter *m_pAttMeter; 33 | 34 | QVBoxLayout *m_pMainLayout; 35 | }; 36 | 37 | #endif // ATTITUDEMETER_H 38 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/compasswidget.h: -------------------------------------------------------------------------------- 1 | #ifndef COMPASSWIDGET_H 2 | #define COMPASSWIDGET_H 3 | 4 | #include 5 | 6 | 7 | class QcGaugeWidget; 8 | class QcNeedleItem; 9 | class QVBoxLayout; 10 | 11 | class LQINSTRUMENTATIONSHARED_EXPORT CompassWidget : public QWidget 12 | { 13 | Q_OBJECT 14 | public: 15 | explicit CompassWidget(QWidget *parent = 0); 16 | ~CompassWidget(); 17 | 18 | void setCurrentValue(int value); 19 | 20 | private: 21 | void init(); 22 | 23 | Q_SIGNALS: 24 | 25 | private Q_SLOTS: 26 | 27 | private: 28 | QcGaugeWidget *m_pCompassGauge; 29 | QcNeedleItem *m_pCompassNeedle; 30 | 31 | QVBoxLayout *m_pMainLayout; 32 | }; 33 | 34 | #endif // COMPASSWIDGET_H 35 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/lqinstrumentation.h: -------------------------------------------------------------------------------- 1 | #ifndef LQINSTRUMENTATION_H 2 | #define LQINSTRUMENTATION_H 3 | 4 | #include "lqinstrumentation_global.h" 5 | 6 | class LQINSTRUMENTATIONSHARED_EXPORT LQInstrumentation 7 | { 8 | 9 | public: 10 | LQInstrumentation(); 11 | }; 12 | 13 | #endif // LQINSTRUMENTATION_H 14 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/lqinstrumentation_global.h: -------------------------------------------------------------------------------- 1 | #ifndef LQINSTRUMENTATION_GLOBAL_H 2 | #define LQINSTRUMENTATION_GLOBAL_H 3 | 4 | #include 5 | 6 | #if defined(LQINSTRUMENTATION_LIBRARY) 7 | # define LQINSTRUMENTATIONSHARED_EXPORT Q_DECL_EXPORT 8 | #else 9 | # define LQINSTRUMENTATIONSHARED_EXPORT Q_DECL_IMPORT 10 | #endif 11 | 12 | #endif // LQINSTRUMENTATION_GLOBAL_H 13 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/lwaveupprogress.h: -------------------------------------------------------------------------------- 1 | #ifndef LWAVEUPPROGRESS_H 2 | #define LWAVEUPPROGRESS_H 3 | 4 | #include 5 | 6 | 7 | typedef enum PercentStyle{ 8 | percentStyleRect = 0, //矩形 9 | percentStyleCircle, //圆形 10 | percentStyleEllipse //椭圆 11 | }P_STYLE; 12 | 13 | struct LWavePrivateData; 14 | 15 | 16 | class LQINSTRUMENTATIONSHARED_EXPORT LWaveUpProgress : public QWidget 17 | { 18 | Q_OBJECT 19 | public: 20 | explicit LWaveUpProgress(QWidget *parent = 0); 21 | ~LWaveUpProgress(); 22 | 23 | void setWaveText(const QString &str); 24 | 25 | private: 26 | /** 27 | * @brief : drawValue() 绘制波浪核心函数 28 | * @param : painter 指针 29 | * @return : none 30 | */ 31 | void drawValue(QPainter *painter); 32 | 33 | protected: 34 | virtual void paintEvent (QPaintEvent *event); 35 | 36 | Q_SIGNALS: 37 | 38 | public Q_SLOTS: 39 | void slotTimeOut(); 40 | 41 | /** 42 | * @brief : slotValueChange() 改变当前波纹值 43 | * @param : value 泊位值 44 | * @return : none 45 | */ 46 | void slotValueChange(int value); 47 | 48 | private: 49 | LWavePrivateData *d_ptr; 50 | }; 51 | 52 | #endif // LWAVEUPPROGRESS_H 53 | -------------------------------------------------------------------------------- /LQInstrumentation/inc/speedgaugewidget.h: -------------------------------------------------------------------------------- 1 | #ifndef SPEEDGAUGEWIDGET_H 2 | #define SPEEDGAUGEWIDGET_H 3 | 4 | #include 5 | 6 | class QcGaugeWidget; 7 | class QcNeedleItem; 8 | class QVBoxLayout; 9 | 10 | class LQINSTRUMENTATIONSHARED_EXPORT SpeedGaugeWidget : public QWidget 11 | { 12 | Q_OBJECT 13 | public: 14 | explicit SpeedGaugeWidget(QWidget *parent = 0); 15 | ~SpeedGaugeWidget(); 16 | 17 | void setCurrentValue(int value); 18 | 19 | private: 20 | void init(); 21 | 22 | Q_SIGNALS: 23 | 24 | private Q_SLOTS: 25 | 26 | private: 27 | QcGaugeWidget *m_pSpeedGauge; 28 | QcNeedleItem *m_pSpeedNeedle; 29 | QVBoxLayout *m_pMainLayout; 30 | }; 31 | 32 | #endif // SPEEDGAUGEWIDGET_H 33 | -------------------------------------------------------------------------------- /LQInstrumentation/lqinstrumentation_inc.pri: -------------------------------------------------------------------------------- 1 | INCLUDEPATH +=\ 2 | $$PWD/inc 3 | -------------------------------------------------------------------------------- /LQInstrumentation/lqinstrumentation_src.pri: -------------------------------------------------------------------------------- 1 | HEADERS += \ 2 | # $$PWD/inc/lqinstrumentation.h \ 3 | $$PWD/inc/lqinstrumentation_global.h \ 4 | $$PWD/inc/qgauge.h \ 5 | $$PWD/inc/qmeter.h \ 6 | $$PWD/inc/qcgaugewidget.h \ 7 | $$PWD/inc/compasswidget.h \ 8 | $$PWD/inc/attitudemeter.h \ 9 | $$PWD/inc/speedgaugewidget.h \ 10 | $$PWD/inc/airspeedgaugewidget.h \ 11 | $$PWD/inc/QRoundProgressBar.h \ 12 | $$PWD/inc/colorprogressbar.h \ 13 | $$PWD/inc/myspeedwatch.h \ 14 | $$PWD/inc/lwaveupprogress.h 15 | 16 | SOURCES += \ 17 | # $$PWD/src/lqinstrumentation.cpp \ 18 | $$PWD/src/qgauge.cpp \ 19 | $$PWD/src/qgaugedrawfunctions.cpp \ 20 | $$PWD/src/qmeter.cpp \ 21 | $$PWD/src/qmeterdrawfunctions.cpp \ 22 | $$PWD/src/qcgaugewidget.cpp \ 23 | $$PWD/src/compasswidget.cpp \ 24 | $$PWD/src/attitudemeter.cpp \ 25 | $$PWD/src/speedgaugewidget.cpp \ 26 | $$PWD/src/airspeedgaugewidget.cpp \ 27 | $$PWD/src/QRoundProgressBar.cpp \ 28 | $$PWD/src/colorprogressbar.cpp \ 29 | $$PWD/src/myspeedwatch.cpp \ 30 | $$PWD/src/lwaveupprogress.cpp 31 | -------------------------------------------------------------------------------- /LQInstrumentation/src/airspeedgaugewidget.cpp: -------------------------------------------------------------------------------- 1 | #include "StdMain.h" 2 | 3 | #include "airspeedgaugewidget.h" 4 | 5 | #include "qcgaugewidget.h" 6 | 7 | #include 8 | 9 | AirSpeedGaugeWidget::AirSpeedGaugeWidget(QWidget *parent) 10 | : QWidget(parent) 11 | { 12 | init(); 13 | } 14 | 15 | AirSpeedGaugeWidget::~AirSpeedGaugeWidget() 16 | { 17 | } 18 | 19 | void AirSpeedGaugeWidget::setCurrentValue(int value) 20 | { 21 | m_pAirspeedNeedle->setCurrentValue(value); 22 | } 23 | 24 | void AirSpeedGaugeWidget::init() 25 | { 26 | m_pAirspeedGauge = new QcGaugeWidget(this); 27 | m_pAirspeedGauge->addArc(55); 28 | m_pAirspeedGauge->addDegrees(65)->setValueRange(0,100); 29 | QcColorBand *clrBand = m_pAirspeedGauge->addColorBand(50); 30 | clrBand->setValueRange(0,100); 31 | m_pAirspeedGauge->addValues(80)->setValueRange(0,100); 32 | m_pAirspeedGauge->addLabel(70)->setText("Km/h"); 33 | QcLabelItem *lab = m_pAirspeedGauge->addLabel(40); 34 | lab->setText("0"); 35 | m_pAirspeedNeedle = m_pAirspeedGauge->addNeedle(60); 36 | m_pAirspeedNeedle->setLabel(lab); 37 | m_pAirspeedNeedle->setColor(Qt::blue); 38 | m_pAirspeedNeedle->setValueRange(0,100); 39 | m_pAirspeedGauge->addBackground(7); 40 | 41 | m_pMainLayout = new QVBoxLayout(this); 42 | m_pMainLayout->addWidget(m_pAirspeedGauge); 43 | 44 | setLayout(m_pMainLayout); 45 | } 46 | 47 | 48 | #include "moc_airspeedgaugewidget.cpp" 49 | -------------------------------------------------------------------------------- /LQInstrumentation/src/attitudemeter.cpp: -------------------------------------------------------------------------------- 1 | #include "StdMain.h" 2 | 3 | #include "attitudemeter.h" 4 | 5 | #include 6 | 7 | AttitudeMeter::AttitudeMeter(QWidget *parent) 8 | : QWidget(parent) 9 | { 10 | init(); 11 | } 12 | 13 | AttitudeMeter::~AttitudeMeter() 14 | { 15 | } 16 | 17 | void AttitudeMeter::setCurrentValue(int value) 18 | { 19 | m_pAttitudeNeedle->setCurrentValue( 90 - value); 20 | m_pAttMeter->setCurrentRoll(value); 21 | } 22 | 23 | void AttitudeMeter::setCurrentPitch(int value) 24 | { 25 | m_pAttMeter->setCurrentPitch(value); 26 | } 27 | 28 | void AttitudeMeter::init() 29 | { 30 | m_pAttitudeGauge = new QcGaugeWidget; 31 | m_pAttitudeGauge->addBackground(99); 32 | QcBackgroundItem *bkg = m_pAttitudeGauge->addBackground(92); 33 | bkg->clearrColors(); 34 | bkg->addColor(0.1,Qt::black); 35 | bkg->addColor(1.0,Qt::white); 36 | m_pAttMeter = m_pAttitudeGauge->addAttitudeMeter(88); 37 | 38 | m_pAttitudeNeedle = m_pAttitudeGauge->addNeedle(70); 39 | m_pAttitudeNeedle->setMinDegree(0); 40 | m_pAttitudeNeedle->setMaxDegree(180); 41 | m_pAttitudeNeedle->setValueRange(0,180); 42 | m_pAttitudeNeedle->setCurrentValue(90); 43 | m_pAttitudeNeedle->setColor(Qt::white); 44 | m_pAttitudeNeedle->setNeedle(QcNeedleItem::AttitudeMeterNeedle); 45 | m_pAttitudeGauge->addGlass(80); 46 | 47 | m_pMainLayout = new QVBoxLayout(this); 48 | m_pMainLayout->addWidget(m_pAttitudeGauge); 49 | 50 | setLayout(m_pMainLayout); 51 | } 52 | 53 | 54 | #include "moc_attitudemeter.cpp" 55 | -------------------------------------------------------------------------------- /LQInstrumentation/src/lqinstrumentation.cpp: -------------------------------------------------------------------------------- 1 | #include "lqinstrumentation.h" 2 | 3 | 4 | LQInstrumentation::LQInstrumentation() 5 | { 6 | } 7 | -------------------------------------------------------------------------------- /LQMisc/Global/GlobalDef.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALDEF_H 2 | #define GLOBALDEF_H 3 | 4 | #endif //GLOBALDEF_H 5 | -------------------------------------------------------------------------------- /LQMisc/Global/GlobalInclude.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALINCLUDE_H 2 | #define GLOBALINCLUDE_H 3 | 4 | 5 | 6 | #include "GlobalDef.h" 7 | #include "GlobalVar.h" 8 | #include "GlobalStruct.h" 9 | 10 | 11 | #include "LQMisc_Export.h" 12 | 13 | #endif //GLOBALINCLUDE_H 14 | -------------------------------------------------------------------------------- /LQMisc/Global/GlobalStruct.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALSTRUCT_H 2 | #define GLOBALSTRUCT_H 3 | 4 | #endif //GLOBALSTRUCT_H 5 | -------------------------------------------------------------------------------- /LQMisc/Global/GlobalVar.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQMisc/Global/GlobalVar.cpp -------------------------------------------------------------------------------- /LQMisc/Global/GlobalVar.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALVAR_H 2 | #define GLOBALVAR_H 3 | 4 | #endif //GLOBALVAR_H 5 | -------------------------------------------------------------------------------- /LQMisc/IncludeMisc/LQString/LQStringInc.h: -------------------------------------------------------------------------------- 1 | #ifndef LQSTRING_INC_H 2 | #define LQSTRING_INC_H 3 | 4 | 5 | #include "LQString_Export.h" 6 | 7 | #endif //LQSTRING_INC_H 8 | -------------------------------------------------------------------------------- /LQMisc/IncludeMisc/LQString/LQStringIncLib.h: -------------------------------------------------------------------------------- 1 | #ifndef LQSTRING_INCLIB_H 2 | #define LQSTRING_INCLIB_H 3 | 4 | 5 | #include "LQStringInc.h" 6 | #include "LQStringLib.h" 7 | 8 | #endif //LQSTRING_INCLIB_H 9 | -------------------------------------------------------------------------------- /LQMisc/IncludeMisc/LQString/LQStringLib.h: -------------------------------------------------------------------------------- 1 | #ifndef LQSTRINGLIB_H 2 | #define LQSTRINGLIB_H 3 | 4 | #endif //LQSTRINGLIB_H 5 | -------------------------------------------------------------------------------- /LQMisc/IncludeMisc/LQString/LQStringUtil.h: -------------------------------------------------------------------------------- 1 | #ifndef LQSTRINGUTIL_H 2 | #define LQSTRINGUTIL_H 3 | 4 | #include 5 | #include 6 | 7 | class LQString_Export LQStringUtil 8 | { 9 | public: 10 | explicit LQStringUtil(); 11 | ~LQStringUtil(); 12 | 13 | public: 14 | static QString variantMapToJsonString(const QVariantMap & map); 15 | static QVariantMap variantMapFromJsonString(const QString & json); 16 | static QVariant variantFromJsonString(const QString & json); 17 | static QString variantToJsonString(const QVariant & json); 18 | }; 19 | 20 | #endif // LQSTRINGUTIL_H 21 | -------------------------------------------------------------------------------- /LQMisc/IncludeMisc/LQString/LQString_Export.h: -------------------------------------------------------------------------------- 1 | #ifndef LQSTRING_EXPORT_H 2 | #define LQSTRING_EXPORT_H 3 | 4 | #include "GlobalInc.h" 5 | 6 | #if defined(LQSTRING_LIBRARY) 7 | # define LQString_Export LQ_DECL_EXPORT 8 | #else 9 | # define LQString_Export LQ_DECL_IMPORT 10 | #endif 11 | 12 | #endif //LQSTRING_EXPORT_H 13 | -------------------------------------------------------------------------------- /LQMisc/LQMisc.pro: -------------------------------------------------------------------------------- 1 | #------------------------------------------------- 2 | # 3 | # Project created by QtCreator 2018-09-02 22:14:55 4 | # 5 | #------------------------------------------------- 6 | 7 | TEMPLATE = subdirs 8 | 9 | SUBDIRS +=\ 10 | $$PWD/LQString/LQString.pro 11 | 12 | 13 | CONFIG +=ordered 14 | 15 | -------------------------------------------------------------------------------- /LQMisc/LQString/Global/GlobalDef.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALDEF_H 2 | #define GLOBALDEF_H 3 | 4 | #endif //GLOBALDEF_H 5 | -------------------------------------------------------------------------------- /LQMisc/LQString/Global/GlobalInclude.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALINCLUDE_H 2 | #define GLOBALINCLUDE_H 3 | 4 | 5 | 6 | #include "GlobalDef.h" 7 | #include "GlobalVar.h" 8 | #include "GlobalStruct.h" 9 | 10 | 11 | #include "LQString_Export.h" 12 | 13 | #include "LQStringUtil.h" 14 | 15 | #endif //GLOBALINCLUDE_H 16 | -------------------------------------------------------------------------------- /LQMisc/LQString/Global/GlobalStruct.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALSTRUCT_H 2 | #define GLOBALSTRUCT_H 3 | 4 | #endif //GLOBALSTRUCT_H 5 | -------------------------------------------------------------------------------- /LQMisc/LQString/Global/GlobalVar.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQMisc/LQString/Global/GlobalVar.cpp -------------------------------------------------------------------------------- /LQMisc/LQString/Global/GlobalVar.h: -------------------------------------------------------------------------------- 1 | #ifndef GLOBALVAR_H 2 | #define GLOBALVAR_H 3 | 4 | #endif //GLOBALVAR_H 5 | -------------------------------------------------------------------------------- /LQMisc/LQString/LQString.pro: -------------------------------------------------------------------------------- 1 | #------------------------------------------------- 2 | # 3 | # Project created by QtCreator 2018-09-02 22:19:19 4 | # 5 | #------------------------------------------------- 6 | 7 | 8 | # add include pri file 9 | include($$PWD/../LQMisc.pri) 10 | QT +=core 11 | 12 | TEMPLATE =lib 13 | DEFINES +=LQSTRING_LIBRARY 14 | TARGET =LQString$${FILE_POSTFIX} 15 | 16 | 17 | INCLUDEPATH +=$$PWD/../../LQInclude/IncludeGlobal 18 | INCLUDEPATH +=$$PWD/../IncludeMisc 19 | INCLUDEPATH +=$$PWD/../IncludeMisc/LQString 20 | 21 | SOURCES +=\ 22 | Global/GlobalVar.cpp \ 23 | LQStringUtil.cpp 24 | 25 | HEADERS +=\ 26 | StdMain.h \ 27 | Global/GlobalVar.h \ 28 | Global/GlobalStruct.h \ 29 | Global/GlobalInclude.h \ 30 | Global/GlobalDef.h \ 31 | ../IncludeMisc/LQString/LQString_Export.h \ 32 | ../IncludeMisc/LQString/LQStringInc.h \ 33 | ../IncludeMisc/LQString/LQStringIncLib.h \ 34 | ../IncludeMisc/LQString/LQStringUtil.h 35 | 36 | -------------------------------------------------------------------------------- /LQMisc/LQString/LQStringUtil.cpp: -------------------------------------------------------------------------------- 1 | #include "StdMain.h" 2 | 3 | #include "LQStringUtil.h" 4 | 5 | #include 6 | 7 | LQStringUtil::LQStringUtil() 8 | { 9 | 10 | } 11 | 12 | LQStringUtil::~LQStringUtil() 13 | { 14 | } 15 | 16 | QString LQStringUtil::variantMapToJsonString(const QVariantMap &map) 17 | { 18 | QJsonDocument doc = QJsonDocument::fromVariant(QVariant(map)); 19 | return doc.toJson(QJsonDocument::Indented); 20 | } 21 | 22 | QVariantMap LQStringUtil::variantMapFromJsonString(const QString &json) 23 | { 24 | QByteArray ba = json.toUtf8(); 25 | QJsonDocument doc = QJsonDocument::fromJson(ba); 26 | return doc.toVariant().toMap(); 27 | } 28 | 29 | QVariant LQStringUtil::variantFromJsonString(const QString &json) 30 | { 31 | QByteArray ba = json.toUtf8(); 32 | QJsonDocument doc = QJsonDocument::fromJson(ba); 33 | return doc.toVariant(); 34 | } 35 | 36 | QString LQStringUtil::variantToJsonString(const QVariant &json) 37 | { 38 | QJsonDocument doc = QJsonDocument::fromVariant(json); 39 | return doc.toJson(QJsonDocument::Indented); 40 | } 41 | -------------------------------------------------------------------------------- /LQMisc/LQString/StdMain.h: -------------------------------------------------------------------------------- 1 | #ifndef STDMAIN_H 2 | 3 | #include "Global/GlobalInclude.h" 4 | 5 | #endif // STDMAIN_H 6 | -------------------------------------------------------------------------------- /LQRes/ExampleImage.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | image/start/Splashscreen.png 4 | image/message.png 5 | image/config/config.xml 6 | 7 | 8 | -------------------------------------------------------------------------------- /LQRes/FormWidgetimage.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | image/search.png 4 | image/search_dark.png 5 | image/message.css 6 | image/intiloading.png 7 | 8 | 9 | -------------------------------------------------------------------------------- /LQRes/image/RightMessageBox/title.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/image/RightMessageBox/title.png -------------------------------------------------------------------------------- /LQRes/image/config/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /LQRes/image/intiloading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/image/intiloading.png -------------------------------------------------------------------------------- /LQRes/image/message.css: -------------------------------------------------------------------------------- 1 | QWidget#widget_title{ 2 | border: 1px solid rgb(50, 50, 50); 3 | background: rgb(80, 80, 80); 4 | } 5 | QWidget#widget_button{ 6 | background: rgb(68, 69, 73); 7 | } 8 | QLabel#white_label{ 9 | color:#FFFFFF; 10 | } 11 | QPushButton#white_button,QToolButton#white_button{ 12 | color:#FFFFFF; 13 | } 14 | 15 | /*MessageBox style*/ 16 | QWidget#msgBox{ 17 | border-radius:3px; 18 | border:1px solid lightgray; 19 | } 20 | QWidget#widgetTitle{ 21 | background: rgb(68, 69, 73, 84); 22 | font: 11px; 23 | font-family:"MYingHei_C-Medium"; 24 | height: 20px; 25 | } 26 | QWidget#widgetButton{ 27 | background: rgb(238, 224, 229); 28 | font: 10px; 29 | font-family:" MYingHei_C-Medium"; 30 | height: 32px; 31 | } 32 | QPushButton#btnClose{ 33 | /*border-image: url(:/images/btn_close_nor.ico);*/ 34 | border: none; 35 | width: 20px; 36 | height: 20px; 37 | } 38 | QPushButton#btnClose:hover{ 39 | background-color:red; 40 | } 41 | QPushButton#btnOk, QPushButton#btnCancel{ 42 | font-family: "MYingHei_C-Medium"; 43 | border:1px solid rgb(79, 173, 216); 44 | border-radius: 2px; 45 | width: 60px; 46 | height: 22px; 47 | } 48 | QPushButton#btnOk:hover, QPushButton#btnCancel:hover{ 49 | background-color: rgb(190, 231, 253); 50 | } 51 | QLabel#labelContent{ 52 | font: 18px; 53 | font-family: "MYingHei_C-Medium"; 54 | } -------------------------------------------------------------------------------- /LQRes/image/message.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/image/message.png -------------------------------------------------------------------------------- /LQRes/image/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/image/search.png -------------------------------------------------------------------------------- /LQRes/image/search_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/image/search_dark.png -------------------------------------------------------------------------------- /LQRes/image/start/Splashscreen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/image/start/Splashscreen.png -------------------------------------------------------------------------------- /LQRes/message.css: -------------------------------------------------------------------------------- 1 | QWidget#widget_title{ 2 | border: 1px solid rgb(50, 50, 50); 3 | background: rgb(80, 80, 80); 4 | } 5 | QWidget#widget_button{ 6 | background: rgb(68, 69, 73); 7 | } 8 | QLabel#white_label{ 9 | color:#FFFFFF; 10 | } 11 | QPushButton#white_button,QToolButton#white_button{ 12 | color:#FFFFFF; 13 | } 14 | 15 | /*MessageBox style*/ 16 | QWidget#msgBox{ 17 | border-radius:3px; 18 | border:1px solid lightgray; 19 | } 20 | QWidget#widgetTitle{ 21 | background: rgb(68, 69, 73, 84); 22 | font: 11px; 23 | font-family:"MYingHei_C-Medium"; 24 | height: 20px; 25 | } 26 | QWidget#widgetButton{ 27 | background: rgb(238, 224, 229); 28 | font: 10px; 29 | font-family:" MYingHei_C-Medium"; 30 | height: 32px; 31 | } 32 | QPushButton#btnClose{ 33 | /*border-image: url(:/images/btn_close_nor.ico);*/ 34 | border: none; 35 | width: 20px; 36 | height: 20px; 37 | } 38 | QPushButton#btnClose:hover{ 39 | background-color:red; 40 | } 41 | QPushButton#btnOk, QPushButton#btnCancel{ 42 | font-family: "MYingHei_C-Medium"; 43 | border:1px solid rgb(79, 173, 216); 44 | border-radius: 2px; 45 | width: 60px; 46 | height: 22px; 47 | } 48 | QPushButton#btnOk:hover, QPushButton#btnCancel:hover{ 49 | background-color: rgb(190, 231, 253); 50 | } 51 | QLabel#labelContent{ 52 | font: 18px; 53 | font-family: "MYingHei_C-Medium"; 54 | } -------------------------------------------------------------------------------- /LQRes/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/search.png -------------------------------------------------------------------------------- /LQRes/search_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/LQRes/search_dark.png -------------------------------------------------------------------------------- /LQTools/LQTools.pro: -------------------------------------------------------------------------------- 1 | #------------------------------------------------- 2 | # 3 | # Project created by QtCreator 2017-03-21T23:02:13 4 | # 5 | #------------------------------------------------- 6 | #辅助工具类集合(常见的工具,比如二维码、验证码、串口通信、TCP/UDP通信……) 7 | include($$PWD/../LQGlobal.pri) 8 | 9 | QT -= gui 10 | greaterThan(QT_MAJOR_VERSION, 4): QT += widgets 11 | #greaterThan(QT_VERSION, 4.7): QT += declarative 12 | greaterThan(QT_VERSION, 5.0): QT += quick 13 | 14 | TARGET = LQTools$${FILE_POSTFIX} 15 | TEMPLATE = lib 16 | 17 | DEFINES += LQTOOLS_LIBRARY 18 | 19 | INCLUDEPATH +=$$PWD/inc 20 | 21 | SOURCES += \ 22 | src/perfmon.cpp \ 23 | src/LQimagehandler.cpp 24 | 25 | 26 | win32:{ 27 | SOURCES +=\ 28 | src/cruler.cpp 29 | 30 | HEADERS +=\ 31 | inc/cruler.h 32 | } 33 | 34 | HEADERS += \ 35 | inc/LQToolsIncLib.h \ 36 | inc/LQToolsInc.h \ 37 | inc/lqtools_global.h \ 38 | inc/perfmon.h \ 39 | inc/LQimagehandler.h 40 | 41 | 42 | win32:{ 43 | LIBS+=-L .. -lGdi32 44 | } 45 | 46 | 47 | -------------------------------------------------------------------------------- /LQTools/inc/LQToolsInc.h: -------------------------------------------------------------------------------- 1 | #ifndef LQTOOLSINC_H 2 | #define LQTOOLSINC_H 3 | 4 | #include "cruler.h" 5 | #include "LQimagehandler.h" 6 | #include "perfmon.h" 7 | 8 | #endif // LQTOOLSINC_H 9 | -------------------------------------------------------------------------------- /LQTools/inc/LQToolsIncLib.h: -------------------------------------------------------------------------------- 1 | #ifndef LQTOOLSINCLIB_H 2 | #define LQTOOLSINCLIB_H 3 | 4 | #include "lqtools_global.h" 5 | 6 | #include "LQToolsInc.h" 7 | 8 | #endif // LQTOOLSINCLIB_H 9 | -------------------------------------------------------------------------------- /LQTools/inc/LQimagehandler.h: -------------------------------------------------------------------------------- 1 | #ifndef LQIMAGEBROWSER_IMAGEHANDLER_H 2 | #define LQIMAGEBROWSER_IMAGEHANDLER_H 3 | 4 | #include 5 | #include 6 | 7 | 8 | class LQTOOLSSHARED_EXPORT LQImageHandler : public QWidget 9 | { 10 | Q_OBJECT 11 | public: 12 | explicit LQImageHandler(QWidget *parent = 0); 13 | ~LQImageHandler(); 14 | 15 | void setPixmap(const QPixmap &pixmap); 16 | 17 | void showOriginalSize(); //原始大小显示 18 | void showSuitableSize(); //合适大小显示 19 | void zoomIn(); 20 | void zoomOut(); 21 | void clockwise90(); 22 | void anticlockwise90(); 23 | 24 | private: 25 | void ariseScale(int rate); 26 | // bool isInPixmap(QPoint pos); 27 | 28 | Q_SIGNALS: 29 | void percentageChanged(double percentage); 30 | void rightButtonClicked(); 31 | 32 | protected: 33 | void paintEvent(QPaintEvent *event); 34 | void wheelEvent(QWheelEvent *event); 35 | void mousePressEvent(QMouseEvent *event); 36 | void mouseReleaseEvent(QMouseEvent *event); 37 | void mouseMoveEvent(QMouseEvent *event); 38 | 39 | public Q_SLOTS: 40 | 41 | private: 42 | QPixmap m_pixmap; 43 | 44 | //缩放 45 | double m_scale; //缩放比例 46 | double m_percentage; //缩放百分比 47 | 48 | //移动 49 | QPoint m_pressPoint; //鼠标按下点的坐标 50 | double m_originX; 51 | double m_originY; 52 | double m_basicX; 53 | double m_basicY; 54 | 55 | int m_suitableWidth; 56 | int m_suitableHeight; 57 | }; 58 | 59 | #endif // LQIMAGEBROWSER_IMAGEHANDLER_H 60 | -------------------------------------------------------------------------------- /LQTools/inc/cruler.h: -------------------------------------------------------------------------------- 1 | #ifndef CRULER_H 2 | #define CRULER_H 3 | 4 | #include 5 | #include 6 | 7 | class LQTOOLSSHARED_EXPORT CRuler : public QWidget 8 | { 9 | Q_OBJECT 10 | public: 11 | explicit CRuler(QWidget *parent = 0); 12 | void setOrientation(Qt::Orientation orn); 13 | QSize sizeHint() const; 14 | 15 | signals: 16 | void moved(const QPoint &); 17 | 18 | private: 19 | void paintEvent(QPaintEvent*); 20 | void mousePressEvent(QMouseEvent*e); 21 | void mouseMoveEvent(QMouseEvent*e); 22 | void mouseReleaseEvent(QMouseEvent*e); 23 | 24 | private: 25 | double m_pixmm; 26 | QBrush m_brush; 27 | QTextOption m_to; 28 | QPoint m_pos; 29 | int m_widthmm, m_heightmm; 30 | int m_width, m_height; 31 | Qt::Orientation m_orn; 32 | }; 33 | 34 | #endif // CRULER_H 35 | -------------------------------------------------------------------------------- /LQTools/inc/lqtools_global.h: -------------------------------------------------------------------------------- 1 | #ifndef LQAUXILIARYTOOLS_GLOBAL_H 2 | #define LQAUXILIARYTOOLS_GLOBAL_H 3 | 4 | #include 5 | 6 | #if defined(LQTOOLS_LIBRARY) 7 | # define LQTOOLSSHARED_EXPORT Q_DECL_EXPORT 8 | #else 9 | # define LQTOOLSSHARED_EXPORT Q_DECL_IMPORT 10 | #endif 11 | 12 | #endif // LQAUXILIARYTOOLS_GLOBAL_H 13 | -------------------------------------------------------------------------------- /LQTools/lqtools_inc.pri: -------------------------------------------------------------------------------- 1 | INCLUDEPATH +=\ 2 | $$PWD/inc 3 | -------------------------------------------------------------------------------- /LQTools/lqtools_src.pri: -------------------------------------------------------------------------------- 1 | SOURCES +=\ 2 | $$PWD/src/perfmon.cpp \ 3 | $$PWD/src/LQimagehandler.cpp \ 4 | $$PWD/src/cruler.cpp 5 | 6 | HEADERS +=\ 7 | $$PWD/inc/lqauxiliarytools_global.h \ 8 | $$PWD/inc/perfmon.h \ 9 | $$PWD/inc/LQimagehandler.h \ 10 | $$PWD/inc/cruler.h 11 | 12 | -------------------------------------------------------------------------------- /LQ_LibForAdditions.pri: -------------------------------------------------------------------------------- 1 | INCLUDEPATH +=$$PWD/LQ3rdparty 2 | INCLUDEPATH +=$$PWD/LQ3rdparty/QZXing 3 | INCLUDEPATH +=$$PWD/LQ3rdparty/QZXing/QZXing 4 | INCLUDEPATH +=$$PWD/LQ3rdparty/QZXing/QZXing/inc 5 | INCLUDEPATH +=$$PWD/LQ3rdparty/QZXing/QZXing/zxing 6 | 7 | DIR_DEPEND_QZXING_DEST = $$PWD/LQ3rdparty/QZXing/Lib/$${DIR_PLATFORM}/$${DIR_COMPILER}/$${DIR_COMPILEMODE} 8 | -------------------------------------------------------------------------------- /Scripts/l_clear.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | #FileName:clear.sh 3 | #Function:Remove the middle of the generated files in this project 4 | #Version:V0.1 5 | #Author:liqi 6 | #Data:2017-03-17 7 | 8 | CURRPATH=$PWD 9 | 10 | rm -rf ../AISApp/Makefile.Debug 11 | rm -rf ../AISApp/Makefile.Release 12 | rm -rf ../AISApp/Makefile 13 | rm -rf ../AISApp/*.o 14 | rm -rf ../AISApp/moc_* 15 | rm -rf ../AISApp/ui_* 16 | 17 | rm -rf ../buile_ 18 | rm -rf ../Makefile 19 | rm -rf ../*.pro.user 20 | rm -rf ../bin/*.so.* 21 | 22 | rm -rf ../LQAisInputModule/*.Debug 23 | rm -rf ../LQAisInputModule/*.Release 24 | rm -rf ../LQAisInputModule/Makefile 25 | rm -rf ../LQAisInputModule/debug 26 | rm -rf ../LQAisInputModule/release 27 | 28 | rm -rf ../LQAisParser/*.Debug 29 | rm -rf ../LQAisParser/*.Release 30 | rm -rf ../LQAisParser/Makefile 31 | rm -rf ../LQAisParser/debug 32 | rm -rf ../LQAisParser/release 33 | 34 | rm -rf ../LQBaiduMapLoadModule/*.Debug 35 | rm -rf ../LQBaiduMapLoadModule/*.Release 36 | rm -rf ../LQBaiduMapLoadModule/Makefile 37 | rm -rf ../LQBaiduMapLoadModule/debug 38 | rm -rf ../LQBaiduMapLoadModule/release 39 | 40 | rm -rf ../LQDatabaseModule/*.Debug 41 | rm -rf ../LQDatabaseModule/*.Release 42 | rm -rf ../LQDatabaseModule/Makefile 43 | rm -rf ../LQDatabaseModule/debug 44 | rm -rf ../LQDatabaseModule/release 45 | 46 | rm -rf ../LQModleAnalysModule/*.Debug 47 | rm -rf ../LQModleAnalysModule/*.Release 48 | rm -rf ../LQModleAnalysModule/Makefile 49 | rm -rf ../LQModleAnalysModule/debug 50 | rm -rf ../LQModleAnalysModule/release 51 | -------------------------------------------------------------------------------- /doc/project_frame.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/doc/project_frame.png -------------------------------------------------------------------------------- /screen/ColorProgress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/ColorProgress.png -------------------------------------------------------------------------------- /screen/Splashscreen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/Splashscreen.png -------------------------------------------------------------------------------- /screen/attitudemeter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/attitudemeter.png -------------------------------------------------------------------------------- /screen/bugs/build_error_tools.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/bugs/build_error_tools.png -------------------------------------------------------------------------------- /screen/build_setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/build_setting.png -------------------------------------------------------------------------------- /screen/customComBox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/customComBox.png -------------------------------------------------------------------------------- /screen/drawprogressbar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/drawprogressbar.png -------------------------------------------------------------------------------- /screen/gauge.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/gauge.gif -------------------------------------------------------------------------------- /screen/gauge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/gauge.png -------------------------------------------------------------------------------- /screen/homeWidget.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/homeWidget.png -------------------------------------------------------------------------------- /screen/ipAddress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/ipAddress.png -------------------------------------------------------------------------------- /screen/linux/Screenshot_2018-08-23.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/linux/Screenshot_2018-08-23.png -------------------------------------------------------------------------------- /screen/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/logo.png -------------------------------------------------------------------------------- /screen/messagebox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/messagebox.png -------------------------------------------------------------------------------- /screen/meter.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/meter.gif -------------------------------------------------------------------------------- /screen/meter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/meter.png -------------------------------------------------------------------------------- /screen/msgNotify.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/msgNotify.png -------------------------------------------------------------------------------- /screen/myCode.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/myCode.png -------------------------------------------------------------------------------- /screen/navlistview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/navlistview.png -------------------------------------------------------------------------------- /screen/nettool.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/nettool.png -------------------------------------------------------------------------------- /screen/perfmon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/perfmon.png -------------------------------------------------------------------------------- /screen/proCreate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/proCreate.png -------------------------------------------------------------------------------- /screen/qrcode_for_devstone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/qrcode_for_devstone.png -------------------------------------------------------------------------------- /screen/qzxing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/qzxing.png -------------------------------------------------------------------------------- /screen/roundPorgressbar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/roundPorgressbar.png -------------------------------------------------------------------------------- /screen/ruler.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/ruler.png -------------------------------------------------------------------------------- /screen/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/search.png -------------------------------------------------------------------------------- /screen/speed1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/speed1.png -------------------------------------------------------------------------------- /screen/speed2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/speed2.png -------------------------------------------------------------------------------- /screen/speedwatch.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/speedwatch.gif -------------------------------------------------------------------------------- /screen/speedwatch2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/speedwatch2.png -------------------------------------------------------------------------------- /screen/start.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/start.png -------------------------------------------------------------------------------- /screen/switch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/switch.png -------------------------------------------------------------------------------- /screen/tabwidget.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/tabwidget.png -------------------------------------------------------------------------------- /screen/toleranceBar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/toleranceBar.png -------------------------------------------------------------------------------- /screen/wavePro.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/screen/wavePro.gif -------------------------------------------------------------------------------- /test.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kevinlq/LQFramKit/eab16de602220e285da9a8c6bf21b82a2fd859d4/test.jpg --------------------------------------------------------------------------------