1
0
mirror of https://github.com/pdewacht/brlaser synced 2025-04-08 21:36:44 +02:00

Merge f277899eecf82fe898086e80999b5513f7c8d825 into 2a49e3287c70c254e7e3ac9dabe9d6a07218c3fa

This commit is contained in:
QORTEC 2025-01-10 22:52:40 +00:00 committed by GitHub
commit a4923ed21d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 8 additions and 0 deletions

View File

@ -80,6 +80,10 @@ void job::write_page_header() {
if (page_params_.duplex) { if (page_params_.duplex) {
fputs("\033&l2S", out_); fputs("\033&l2S", out_);
} else if (page_params_.tumble) {
fputs("\033&l1S", out_);
} else {
fputs("\033&l0S", out_);
} }
} }

View File

@ -27,6 +27,7 @@ struct page_params {
int num_copies; int num_copies;
int resolution; int resolution;
bool duplex; bool duplex;
bool tumble;
bool economode; bool economode;
std::string sourcetray; std::string sourcetray;
std::string mediatype; std::string mediatype;
@ -36,6 +37,7 @@ struct page_params {
return num_copies == o.num_copies return num_copies == o.num_copies
&& resolution == o.resolution && resolution == o.resolution
&& duplex == o.duplex && duplex == o.duplex
&& tumble == o.tumble
&& economode == o.economode && economode == o.economode
&& sourcetray == o.sourcetray && sourcetray == o.sourcetray
&& mediatype == o.mediatype && mediatype == o.mediatype

View File

@ -111,6 +111,7 @@ page_params build_page_params(const cups_page_header2_t &header) {
p.economode = header.cupsInteger[10]; p.economode = header.cupsInteger[10];
p.mediatype = header.MediaType; p.mediatype = header.MediaType;
p.duplex = header.Duplex; p.duplex = header.Duplex;
p.tumble = header.Tumble;
if (header.MediaPosition < sources.size()) if (header.MediaPosition < sources.size())
p.sourcetray = sources[header.MediaPosition]; p.sourcetray = sources[header.MediaPosition];

View File

@ -21,6 +21,7 @@
#include <stdint.h> #include <stdint.h>
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <cstdint>
#include <vector> #include <vector>
class tempfile { class tempfile {