summaryrefslogtreecommitdiff
path: root/prnt/hpijs/ljmono.cpp
diff options
context:
space:
mode:
authorDidier Raboud <odyx@debian.org>2016-01-04 16:48:19 +0100
committerDidier Raboud <odyx@debian.org>2016-01-04 16:48:19 +0100
commitd29ae37b4057a34a596da4ab070707b13ec89cef (patch)
tree1909db55dd48463527f419203313c9136b6a5c82 /prnt/hpijs/ljmono.cpp
parent98edb6065e3de2c6645f43ac36bbad5250399be3 (diff)
Imported Upstream version 2.8.10
Diffstat (limited to 'prnt/hpijs/ljmono.cpp')
-rw-r--r--prnt/hpijs/ljmono.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/prnt/hpijs/ljmono.cpp b/prnt/hpijs/ljmono.cpp
index c50700577..6c2473e13 100644
--- a/prnt/hpijs/ljmono.cpp
+++ b/prnt/hpijs/ljmono.cpp
@@ -199,10 +199,15 @@ DRIVER_ERROR HeaderLJMono::StartSend ()
strcpy (res, "@PJL SET DUPLEX=OFF\015\012");
#ifdef APDK_AUTODUPLEX
- if (thePrintContext->QueryDuplexMode ())
- {
- strcpy (res, "@PJL SET DUPLEX=ON\015\012");
- }
+ DUPLEXMODE dupmode = thePrintContext->QueryDuplexMode ();
+ if (dupmode != DUPLEXMODE_NONE)
+ {
+ strcpy (res, "@PJL SET DUPLEX=ON\015\012@PJL SET BINDING=");
+ if (dupmode == DUPLEXMODE_BOOK)
+ strcat (res, "LONGEDGE\015\012");
+ else
+ strcat (res, "SHORTEDGE\015\012");
+ }
#endif
err = thePrinter->Send ((const BYTE *) res, strlen (res));
ERRCHECK;