hlp:桂林国际齿轮泵代码
This commit is contained in:
@@ -0,0 +1,120 @@
|
||||
/****************************************************************************
|
||||
** Meta object code from reading C++ file 'PulseNumFix.h'
|
||||
**
|
||||
** Created by: The Qt Meta Object Compiler version 63 (Qt 4.8.5)
|
||||
**
|
||||
** WARNING! All changes made in this file will be lost!
|
||||
*****************************************************************************/
|
||||
|
||||
#include "../PulseNumFix.h"
|
||||
#if !defined(Q_MOC_OUTPUT_REVISION)
|
||||
#error "The header file 'PulseNumFix.h' doesn't include <QObject>."
|
||||
#elif Q_MOC_OUTPUT_REVISION != 63
|
||||
#error "This file was generated using the moc from 4.8.5. It"
|
||||
#error "cannot be used with the include files from this version of Qt."
|
||||
#error "(The moc has changed too much.)"
|
||||
#endif
|
||||
|
||||
QT_BEGIN_MOC_NAMESPACE
|
||||
static const uint qt_meta_data_PulseNumFix[] = {
|
||||
|
||||
// content:
|
||||
6, // revision
|
||||
0, // classname
|
||||
0, 0, // classinfo
|
||||
7, 14, // methods
|
||||
0, 0, // properties
|
||||
0, 0, // enums/sets
|
||||
0, 0, // constructors
|
||||
0, // flags
|
||||
1, // signalCount
|
||||
|
||||
// signals: signature, parameters, type, tag, flags
|
||||
13, 12, 12, 12, 0x05,
|
||||
|
||||
// slots: signature, parameters, type, tag, flags
|
||||
36, 12, 12, 12, 0x08,
|
||||
56, 12, 12, 12, 0x08,
|
||||
78, 12, 12, 12, 0x08,
|
||||
117, 12, 12, 12, 0x08,
|
||||
158, 12, 12, 12, 0x08,
|
||||
201, 12, 12, 12, 0x08,
|
||||
|
||||
0 // eod
|
||||
};
|
||||
|
||||
static const char qt_meta_stringdata_PulseNumFix[] = {
|
||||
"PulseNumFix\0\0pulseNuxFixDone(float)\0"
|
||||
"setUIEnableStatus()\0onButtonBoxAccepted()\0"
|
||||
"on_radioButtonAccordingRate_released()\0"
|
||||
"on_radioButtonAccordingLength_released()\0"
|
||||
"on_radioButtonAccordingPulseNum_released()\0"
|
||||
"on_radioButtonSynchonizerPara_released()\0"
|
||||
};
|
||||
|
||||
void PulseNumFix::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
|
||||
{
|
||||
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||
Q_ASSERT(staticMetaObject.cast(_o));
|
||||
PulseNumFix *_t = static_cast<PulseNumFix *>(_o);
|
||||
switch (_id) {
|
||||
case 0: _t->pulseNuxFixDone((*reinterpret_cast< float(*)>(_a[1]))); break;
|
||||
case 1: _t->setUIEnableStatus(); break;
|
||||
case 2: _t->onButtonBoxAccepted(); break;
|
||||
case 3: _t->on_radioButtonAccordingRate_released(); break;
|
||||
case 4: _t->on_radioButtonAccordingLength_released(); break;
|
||||
case 5: _t->on_radioButtonAccordingPulseNum_released(); break;
|
||||
case 6: _t->on_radioButtonSynchonizerPara_released(); break;
|
||||
default: ;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const QMetaObjectExtraData PulseNumFix::staticMetaObjectExtraData = {
|
||||
0, qt_static_metacall
|
||||
};
|
||||
|
||||
const QMetaObject PulseNumFix::staticMetaObject = {
|
||||
{ &QDialog::staticMetaObject, qt_meta_stringdata_PulseNumFix,
|
||||
qt_meta_data_PulseNumFix, &staticMetaObjectExtraData }
|
||||
};
|
||||
|
||||
#ifdef Q_NO_DATA_RELOCATION
|
||||
const QMetaObject &PulseNumFix::getStaticMetaObject() { return staticMetaObject; }
|
||||
#endif //Q_NO_DATA_RELOCATION
|
||||
|
||||
const QMetaObject *PulseNumFix::metaObject() const
|
||||
{
|
||||
return QObject::d_ptr->metaObject ? QObject::d_ptr->metaObject : &staticMetaObject;
|
||||
}
|
||||
|
||||
void *PulseNumFix::qt_metacast(const char *_clname)
|
||||
{
|
||||
if (!_clname) return 0;
|
||||
if (!strcmp(_clname, qt_meta_stringdata_PulseNumFix))
|
||||
return static_cast<void*>(const_cast< PulseNumFix*>(this));
|
||||
if (!strcmp(_clname, "ParaSettingUI"))
|
||||
return static_cast< ParaSettingUI*>(const_cast< PulseNumFix*>(this));
|
||||
return QDialog::qt_metacast(_clname);
|
||||
}
|
||||
|
||||
int PulseNumFix::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
|
||||
{
|
||||
_id = QDialog::qt_metacall(_c, _id, _a);
|
||||
if (_id < 0)
|
||||
return _id;
|
||||
if (_c == QMetaObject::InvokeMetaMethod) {
|
||||
if (_id < 7)
|
||||
qt_static_metacall(this, _c, _id, _a);
|
||||
_id -= 7;
|
||||
}
|
||||
return _id;
|
||||
}
|
||||
|
||||
// SIGNAL 0
|
||||
void PulseNumFix::pulseNuxFixDone(float _t1)
|
||||
{
|
||||
void *_a[] = { 0, const_cast<void*>(reinterpret_cast<const void*>(&_t1)) };
|
||||
QMetaObject::activate(this, &staticMetaObject, 0, _a);
|
||||
}
|
||||
QT_END_MOC_NAMESPACE
|
||||
Binary file not shown.
@@ -0,0 +1,146 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
|
||||
** Contact: http://www.qt-project.org/
|
||||
**
|
||||
** This file is part of the QtCore module of the Qt Toolkit.
|
||||
**
|
||||
** $QT_BEGIN_LICENSE:LGPL$
|
||||
** GNU Lesser General Public License Usage
|
||||
** This file may be used under the terms of the GNU Lesser General Public
|
||||
** License version 2.1 as published by the Free Software Foundation and
|
||||
** appearing in the file LICENSE.LGPL included in the packaging of this
|
||||
** file. Please review the following information to ensure the GNU Lesser
|
||||
** General Public License version 2.1 requirements will be met:
|
||||
** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
|
||||
**
|
||||
** In addition, as a special exception, Nokia gives you certain additional
|
||||
** rights. These rights are described in the Nokia Qt LGPL Exception
|
||||
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
|
||||
**
|
||||
** GNU General Public License Usage
|
||||
** Alternatively, this file may be used under the terms of the GNU General
|
||||
** Public License version 3.0 as published by the Free Software Foundation
|
||||
** and appearing in the file LICENSE.GPL included in the packaging of this
|
||||
** file. Please review the following information to ensure the GNU General
|
||||
** Public License version 3.0 requirements will be met:
|
||||
** http://www.gnu.org/copyleft/gpl.html.
|
||||
**
|
||||
** Other Usage
|
||||
** Alternatively, this file may be used in accordance with the terms and
|
||||
** conditions contained in a signed written agreement between you and Nokia.
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
** $QT_END_LICENSE$
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef QJSONDOCUMENT_H
|
||||
#define QJSONDOCUMENT_H
|
||||
|
||||
#include "qjsonvalue.h"
|
||||
|
||||
QT_BEGIN_HEADER
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QDebug;
|
||||
|
||||
namespace QJsonPrivate {
|
||||
class Parser;
|
||||
}
|
||||
|
||||
struct Q_JSONRPC_EXPORT QJsonParseError
|
||||
{
|
||||
enum ParseError {
|
||||
NoError = 0,
|
||||
UnterminatedObject,
|
||||
MissingNameSeparator,
|
||||
UnterminatedArray,
|
||||
MissingValueSeparator,
|
||||
IllegalValue,
|
||||
EndOfNumber,
|
||||
IllegalNumber,
|
||||
StringEscapeSequence,
|
||||
StringUTF8Scan,
|
||||
EndOfString,
|
||||
MissingObject
|
||||
};
|
||||
|
||||
int offset;
|
||||
ParseError error;
|
||||
};
|
||||
|
||||
class Q_JSONRPC_EXPORT QJsonDocument
|
||||
{
|
||||
public:
|
||||
#ifdef Q_LITTLE_ENDIAN
|
||||
static const uint BinaryFormatTag = ('q') | ('b' << 8) | ('j' << 16) | ('s' << 24);
|
||||
#else
|
||||
static const uint BinaryFormatTag = ('q' << 24) | ('b' << 16) | ('j' << 8) | ('s');
|
||||
#endif
|
||||
|
||||
QJsonDocument();
|
||||
explicit QJsonDocument(const QJsonObject &object);
|
||||
explicit QJsonDocument(const QJsonArray &array);
|
||||
~QJsonDocument();
|
||||
|
||||
QJsonDocument(const QJsonDocument &other);
|
||||
QJsonDocument &operator =(const QJsonDocument &other);
|
||||
|
||||
enum DataValidation {
|
||||
Validate,
|
||||
BypassValidation
|
||||
};
|
||||
|
||||
static QJsonDocument fromRawData(const char *data, int size, DataValidation validation = Validate);
|
||||
const char *rawData(int *size) const;
|
||||
|
||||
static QJsonDocument fromBinaryData(const QByteArray &data, DataValidation validation = Validate);
|
||||
QByteArray toBinaryData() const;
|
||||
|
||||
static QJsonDocument fromVariant(const QVariant &variant);
|
||||
QVariant toVariant() const;
|
||||
|
||||
static QJsonDocument fromJson(const QByteArray &json, QJsonParseError *error = 0);
|
||||
QByteArray toJson() const;
|
||||
|
||||
bool isEmpty() const;
|
||||
bool isArray() const;
|
||||
bool isObject() const;
|
||||
|
||||
QJsonObject object() const;
|
||||
QJsonArray array() const;
|
||||
|
||||
void setObject(const QJsonObject &object);
|
||||
void setArray(const QJsonArray &array);
|
||||
|
||||
bool operator==(const QJsonDocument &other) const;
|
||||
bool operator!=(const QJsonDocument &other) const { return !(*this == other); }
|
||||
|
||||
bool isNull() const;
|
||||
|
||||
private:
|
||||
friend class QJsonValue;
|
||||
friend class QJsonPrivate::Data;
|
||||
friend class QJsonPrivate::Parser;
|
||||
friend Q_JSONRPC_EXPORT QDebug operator<<(QDebug, const QJsonDocument &);
|
||||
|
||||
QJsonDocument(QJsonPrivate::Data *data);
|
||||
|
||||
QJsonPrivate::Data *d;
|
||||
};
|
||||
|
||||
#ifndef QT_NO_DEBUG_STREAM
|
||||
Q_JSONRPC_EXPORT QDebug operator<<(QDebug, const QJsonDocument &);
|
||||
#endif
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
QT_END_HEADER
|
||||
|
||||
#endif // QJSONDOCUMENT_H
|
||||
@@ -0,0 +1,49 @@
|
||||
#-------------------------------------------------
|
||||
#
|
||||
# Project created by QtCreator 2013-04-25T18:27:50
|
||||
#
|
||||
#-------------------------------------------------
|
||||
|
||||
QT += core gui
|
||||
|
||||
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
||||
|
||||
TARGET = 121
|
||||
TEMPLATE = app
|
||||
|
||||
|
||||
SOURCES +=\
|
||||
bitstream.cpp \
|
||||
mask.cpp \
|
||||
qrenc.cpp \
|
||||
qrencode.cpp \
|
||||
qrinput.cpp \
|
||||
qrspec.cpp \
|
||||
rscode.cpp \
|
||||
split.cpp \
|
||||
mainwindow.cpp
|
||||
|
||||
HEADERS += \
|
||||
bistream.h \
|
||||
mask.h \
|
||||
qrencode_inner.h \
|
||||
qrinput.h \
|
||||
qrspec.h \
|
||||
rscode.h \
|
||||
split.h \
|
||||
mainwindow.h
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
unix:!macx: LIBS += -L$$PWD/../../../../../../../usr/local/lib/ -lqrencode
|
||||
|
||||
INCLUDEPATH += $$PWD/../../../../../../../usr/local/include
|
||||
DEPENDPATH += $$PWD/../../../../../../../usr/local/include
|
||||
|
||||
unix:!macx: LIBS += -lpng12
|
||||
|
||||
FORMS += \
|
||||
mainwindow.ui
|
||||
@@ -0,0 +1,245 @@
|
||||
/*
|
||||
* PicWidget.h
|
||||
*
|
||||
* Created on: Jul 2, 2013
|
||||
* Author: yiyu
|
||||
* QQ:1036184468
|
||||
* Descriptoin:
|
||||
|
||||
*/
|
||||
|
||||
#ifndef PICWIDGET_H_
|
||||
#define PICWIDGET_H_
|
||||
|
||||
#include <QWidget>
|
||||
#include <QFile>
|
||||
#include <QPainter>
|
||||
#include <QPen>
|
||||
#include <QBrush>
|
||||
#include <QRect>
|
||||
#include <QImage>
|
||||
#include <QMouseEvent>
|
||||
#include <QColor>
|
||||
#include <QRgb>
|
||||
#include <QWSServer>
|
||||
#include "SysPara.h"
|
||||
#include "ParaSettingUI.h"
|
||||
|
||||
#define MAX_PIC_WIDGET_HEIGHT 60
|
||||
#define MAX_PIC_WIDGET_WIDTH 600*8
|
||||
#define MAX_WIDTH MAX_PIC_WIDGET_WIDTH-100
|
||||
#define MAX_HEIGHT MAX_PIC_WIDGET_HEIGHT
|
||||
#define MAXLINE 40
|
||||
|
||||
#define FVAR (1<<5)
|
||||
#define FCOL0 (1<<6)
|
||||
#define FLINE0 (1<<7)
|
||||
|
||||
#define CFONT 0
|
||||
#define CLINESPACE 1
|
||||
#define CFONTGAP 2
|
||||
#define CBOLD 3
|
||||
#define CHEIGHT 4
|
||||
|
||||
#define VTYPE 1
|
||||
#define VDIGIT 2
|
||||
#define VWIDTH 3
|
||||
#define VTYPE0 4
|
||||
#define VTYPE1 5
|
||||
//#define C 5
|
||||
|
||||
#define BIN0808 100
|
||||
#define BIN0809 1000
|
||||
#define BIN0810 2000
|
||||
#define BIN0812 3000
|
||||
#define BIN0816 5000
|
||||
#define BIN1616 7000
|
||||
#define BIN2424 11000
|
||||
//#define BIN1224 15000
|
||||
#define BIN0805 20000
|
||||
|
||||
//是否需要匹配字体能操作
|
||||
//#define FONTMATCH
|
||||
|
||||
typedef enum{
|
||||
ST05=0,
|
||||
ST07=1,
|
||||
ST09=2,
|
||||
ST12=3,
|
||||
ST16=4,
|
||||
HT16=5,
|
||||
ST24=6,
|
||||
HT24=7,
|
||||
ST32=8
|
||||
}PFONTNAME;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
bool DrawEn;// 绘图
|
||||
bool DrawGridEn; // 网格 checkBoxDrawGridEn
|
||||
int Width;// 字串长度
|
||||
unsigned char CharHeight; //字符高度
|
||||
unsigned char CharWidth; //字符宽度
|
||||
unsigned char FontGap; // 字符间隔
|
||||
PFONTNAME Font;// 字体
|
||||
bool CharCurrent; //光标类型,字符还是像素
|
||||
bool CurrentEn;
|
||||
unsigned char LineSpace;
|
||||
unsigned char Bold; // 字体加粗
|
||||
unsigned char LineHeight;
|
||||
bool insertMode;
|
||||
bool checkBoxControlChar;//控制符显示
|
||||
} t_charPara;
|
||||
|
||||
typedef struct{
|
||||
int width;
|
||||
int height;
|
||||
bool enable;
|
||||
} t_draw;
|
||||
|
||||
typedef struct{
|
||||
int Len;
|
||||
int yPos;
|
||||
int xPos;
|
||||
int minFont;
|
||||
int maxFont;
|
||||
int minLineHeight;
|
||||
int maxLineHeight;
|
||||
}t_line;
|
||||
|
||||
class PicWidget:public QWidget{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit PicWidget(QWidget *parent = 0);
|
||||
~PicWidget();
|
||||
|
||||
void resizeWidget(int w,int h);
|
||||
void initWidget(int w,int h);
|
||||
void loadImage(QString filename,bool forceSize = true);
|
||||
void insertImage(QString filename,bool forceSize = false);
|
||||
|
||||
void saveImage(QString filename);
|
||||
void enlargeDisplay();
|
||||
void reduceDisplay();
|
||||
void setScale(int scale);
|
||||
|
||||
void paintEvent(QPaintEvent *);
|
||||
|
||||
void mousePressEvent ( QMouseEvent * event );
|
||||
|
||||
void currPositionMove(int shiftX,int shiftY);
|
||||
void ensureCurrPos();
|
||||
int getScaleValue();
|
||||
bool isModified();
|
||||
int getHeight();
|
||||
int getWidth();
|
||||
void readAscDot(unsigned int asc, char *dot);
|
||||
void readZhDot(unsigned int ingb, char *dot);
|
||||
int inputTxtDot(QString txt,int *var);
|
||||
int inputRamDot(QString txt,unsigned char *pMap, vars_t *p_var);
|
||||
int charDotMap( char *dot,bool english );
|
||||
int varDotMap(char *dot,int *var);
|
||||
int picDelOneChar();
|
||||
int picDelNextChar();
|
||||
t_charPara charPara;
|
||||
t_draw drawPara;
|
||||
int picSetHome();
|
||||
int picSetEnd();
|
||||
void showVar(QString mode,char *var,int len);
|
||||
int getVarNum();
|
||||
int readVar(SysPara *sysPara, unsigned char alt2);
|
||||
void getPrintDat(unsigned char *dat,unsigned char alt2,SysPara *sysPara);
|
||||
void getCharRamData(SysPara *sysPara);
|
||||
|
||||
int resizePicRect(bool alt2);
|
||||
void movePicView();
|
||||
void bindSysPara(SysPara *sysPara);
|
||||
int altPrint;
|
||||
int startRow;
|
||||
int startCol;
|
||||
int heightPoint;
|
||||
int widthPoint;
|
||||
int scale;
|
||||
int currXpos;
|
||||
int currYpos;
|
||||
int endRow;
|
||||
int endCol;
|
||||
bool zkEditEn;
|
||||
bool isInput ;
|
||||
bool pEditMode;
|
||||
void zkEditNow();
|
||||
void zkEditSave();
|
||||
void disp();
|
||||
QString currentEditTxt;
|
||||
int resizePicWidth(bool rowEn);
|
||||
int getNextPos(int x, int n);
|
||||
int getLineEnd(int x);
|
||||
int getUpLine(int x);
|
||||
int getDownLine(int x);
|
||||
int getPrePos(int x, int n);
|
||||
int getBlandPos(int x, int n);
|
||||
int SiteStart(int x);
|
||||
void moveDots(int x1, int x2, int y1, int h, int w);
|
||||
int getFontHeight(int x, int y);
|
||||
|
||||
void VarGapSet(int x, int h);
|
||||
int VarGetWidth(int x,int y,unsigned char *c);
|
||||
int getLineHeight(int x, int y);
|
||||
int getInserEnable(int x, int y, int w, int h);
|
||||
void delDots(int x1, int x2, int y1, int h);
|
||||
int isVar(int x, int y);
|
||||
int getPicRealHeight();
|
||||
int getUpLineStart(int x, int y);
|
||||
int isCanDelete(int x, int y);
|
||||
void readPng(int x, int y, int w, int h);
|
||||
void insertImage1(QString filename, bool forceSize);
|
||||
void saveImage1(QString filename);
|
||||
void shows(QString s);
|
||||
public slots:
|
||||
void cursorFlash(); // 光标闪烁
|
||||
|
||||
|
||||
Q_SIGNALS:
|
||||
void picWidgetModify();
|
||||
void ShowKeybord( );
|
||||
void rowColChanged(QString);
|
||||
void currXYChanged(QString);
|
||||
void ChangeFont(int cc);
|
||||
private:
|
||||
unsigned char pointMap[MAX_PIC_WIDGET_HEIGHT * (MAX_PIC_WIDGET_WIDTH)];
|
||||
|
||||
bool modified;
|
||||
int varNum;
|
||||
t_line line;
|
||||
int linePara[MAXLINE];
|
||||
int lineNum;
|
||||
int lineMaxNum;
|
||||
//SysPara *sysPara1;
|
||||
void setModified(bool m);
|
||||
void saveZhDot();
|
||||
char getZkPic(char *dat);
|
||||
int charInsert(int w,bool txtMode);
|
||||
int isBlankCol();
|
||||
unsigned long zkOffset;
|
||||
unsigned char zkReadNum;
|
||||
unsigned int zkIncode;
|
||||
QFile *pzkEditFile;
|
||||
QString txt;
|
||||
/* 字库文件*/
|
||||
QFile zkAsc;
|
||||
char cal_currHeightEn;
|
||||
// char currMode; // ddddd
|
||||
QFile zkHz05;
|
||||
QFile zkHz07;
|
||||
QFile zkHz09;
|
||||
QFile zkHz12;
|
||||
QFile zkHz16;
|
||||
QFile zkHz24;
|
||||
QFile zkHz16H;
|
||||
QFile zkHz24H;
|
||||
//QFile zkHz32;
|
||||
QFile unitogb;
|
||||
};
|
||||
|
||||
#endif /* PICWIDGET_H_ */
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 4.1 KiB |
Reference in New Issue
Block a user