Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
FmTakeaway
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
shangshang.dai
FmTakeaway
Commits
c29f8552
Commit
c29f8552
authored
Nov 09, 2018
by
刘帅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改打印图像名称,以区别
parent
457b1067
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
fmPrinter/fmPrinter.cpp
+6
-2
No files found.
fmPrinter/fmPrinter.cpp
View file @
c29f8552
...
@@ -456,7 +456,7 @@ bool FmPrinter::_PrintBodyForShangmiPrinter(OrderObject *pData)
...
@@ -456,7 +456,7 @@ bool FmPrinter::_PrintBodyForShangmiPrinter(OrderObject *pData)
rlt
=
rlt
&&
m_beginPrint
(
0
)
==
HS_OK
?
true
:
false
;
rlt
=
rlt
&&
m_beginPrint
(
0
)
==
HS_OK
?
true
:
false
;
QString
apppath
=
QCoreApplication
::
applicationDirPath
();
QString
apppath
=
QCoreApplication
::
applicationDirPath
();
QString
helloBmp
=
apppath
+
"/Hello.bmp"
;
QString
helloBmp
=
apppath
+
"/Hello
_Sm
.bmp"
;
m_printBitmapFile
(
helloBmp
.
toLocal8Bit
().
data
(),
0
);
m_printBitmapFile
(
helloBmp
.
toLocal8Bit
().
data
(),
0
);
rlt
=
rlt
&&
m_beginPrint
(
7
)
==
HS_OK
?
true
:
false
;
rlt
=
rlt
&&
m_beginPrint
(
7
)
==
HS_OK
?
true
:
false
;
...
@@ -528,7 +528,7 @@ bool FmPrinter::_shangmiPrinter(OrderObject *pData)
...
@@ -528,7 +528,7 @@ bool FmPrinter::_shangmiPrinter(OrderObject *pData)
QString
apppath
=
QCoreApplication
::
applicationDirPath
();
QString
apppath
=
QCoreApplication
::
applicationDirPath
();
QString
titleBmp
=
apppath
+
"/Kitty.bmp"
;
QString
titleBmp
=
apppath
+
"/Kitty.bmp"
;
QString
bottomBmp
=
apppath
+
"/Look.bmp"
;
QString
bottomBmp
=
apppath
+
"/Look.bmp"
;
QString
qrBmp
=
apppath
+
"/qr.bmp"
;
QString
qrBmp
=
apppath
+
"/qr
_high
.bmp"
;
bool
rlt
=
true
;
bool
rlt
=
true
;
m_printBitmapFile
(
titleBmp
.
toLocal8Bit
().
data
(),
0
);
m_printBitmapFile
(
titleBmp
.
toLocal8Bit
().
data
(),
0
);
...
@@ -599,6 +599,7 @@ bool FmPrinter::_fmPrintData(OrderObject* pData)
...
@@ -599,6 +599,7 @@ bool FmPrinter::_fmPrintData(OrderObject* pData)
QString
titleBmp
=
apppath
+
"/Kitty.bmp"
;
QString
titleBmp
=
apppath
+
"/Kitty.bmp"
;
QString
bottomBmp
=
apppath
+
"/Look.bmp"
;
QString
bottomBmp
=
apppath
+
"/Look.bmp"
;
QString
helloBmp
=
apppath
+
"/Hello.bmp"
;
QString
helloBmp
=
apppath
+
"/Hello.bmp"
;
QString
qrBmp
=
apppath
+
"/qr_high.bmp"
;
m_pPrintHex
(
"
\x1B\x61
\x1"
,
3
);
//居中
m_pPrintHex
(
"
\x1B\x61
\x1"
,
3
);
//居中
m_pPrintBitmapFile
(
titleBmp
.
toLocal8Bit
().
data
(),
0
);
m_pPrintBitmapFile
(
titleBmp
.
toLocal8Bit
().
data
(),
0
);
...
@@ -670,8 +671,11 @@ bool FmPrinter::_fmPrintData(OrderObject* pData)
...
@@ -670,8 +671,11 @@ bool FmPrinter::_fmPrintData(OrderObject* pData)
m_pPrintHex
(
"
\x1B\x61
\x1"
,
3
);
//居中
m_pPrintHex
(
"
\x1B\x61
\x1"
,
3
);
//居中
m_pBeginPrint
(
0
);
m_pBeginPrint
(
0
);
m_pPrintBitmapFile
(
bottomBmp
.
toLocal8Bit
().
data
(),
0
);
m_pPrintBitmapFile
(
bottomBmp
.
toLocal8Bit
().
data
(),
0
);
m_pPrintBitmapFile
(
qrBmp
.
toLocal8Bit
().
data
(),
0
);
m_pPrintHex
(
"
\x0A
"
,
1
);
m_pPrintHex
(
"
\x0A
"
,
1
);
m_pPrintHex
(
"
\x0A
"
,
1
);
m_pPrintHex
(
"
\x0A
"
,
1
);
m_pBeginPrint
(
0
);
m_pBeginPrint
(
0
);
m_pCutPaper
(
0
);
m_pCutPaper
(
0
);
m_pClosePrinter
();
m_pClosePrinter
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment