* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 0:09 [gentoo-user] Scanning double sided documents and printing them the same Dale
@ 2020-12-10 0:46 ` thelma
2020-12-10 1:29 ` thelma
2020-12-10 8:27 ` Neil Bothwick
` (2 subsequent siblings)
3 siblings, 1 reply; 17+ messages in thread
From: thelma @ 2020-12-10 0:46 UTC (permalink / raw
To: gentoo-user
On 12/09/2020 05:09 PM, Dale wrote:
> Howdy,
>
> I have a flatbed scanner. It's a old HP 4570. I been using Skanlite to
> scan pictures etc and it does a great job. On occasion tho I have a
> double sided document. I know how to scan them, scan one side, flip
> over and scan the back. That's easy enough. How do I print them the
> same way tho? Sometimes I use it like a copying machine basically.
> Scan in, then print. I'm not quite sure how to print the double sided
> stuff in one go tho.
>
> If someone does the same as me, can you share how you print them two
> sided? My printer is duplex so I just need to import both sides and
> tell it to print. I'm just not sure what software does that and makes
> it easy.
>
> Thoughts??
>
> Dale
>
> :_) :-)
>
Do you use XSane to scan it? You setup the printer in Setup menu under
"Copy" and scan in duplex mode. If you printer is setup by default to
print duplex it will print it correctly, in duplex. If not you will get
two pages, it prints directly to a printer (the print windows doesn't
pop-up).
I suggest to scan it first to a document and print it in duplex.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 0:46 ` thelma
@ 2020-12-10 1:29 ` thelma
2020-12-10 2:16 ` Dale
0 siblings, 1 reply; 17+ messages in thread
From: thelma @ 2020-12-10 1:29 UTC (permalink / raw
To: gentoo-user
On 12/09/2020 05:46 PM, thelma@sys-concept.com wrote:
> On 12/09/2020 05:09 PM, Dale wrote:
>> Howdy,
>>
>> I have a flatbed scanner. It's a old HP 4570. I been using Skanlite to
>> scan pictures etc and it does a great job. On occasion tho I have a
>> double sided document. I know how to scan them, scan one side, flip
>> over and scan the back. That's easy enough. How do I print them the
>> same way tho? Sometimes I use it like a copying machine basically.
>> Scan in, then print. I'm not quite sure how to print the double sided
>> stuff in one go tho.
>>
>> If someone does the same as me, can you share how you print them two
>> sided? My printer is duplex so I just need to import both sides and
>> tell it to print. I'm just not sure what software does that and makes
>> it easy.
>>
>> Thoughts??
>>
>> Dale
>>
>> :_) :-)
>>
>
> Do you use XSane to scan it? You setup the printer in Setup menu under
> "Copy" and scan in duplex mode. If you printer is setup by default to
> print duplex it will print it correctly, in duplex. If not you will get
> two pages, it prints directly to a printer (the print windows doesn't
> pop-up).
>
> I suggest to scan it first to a document and print it in duplex.
Correction. You have mentioned it is a flatbed scanner so you can not
scan in duplex mode. Just create "multipage document" scan both sides,
save it and you should be able to print it in duplex mode. I mostly use
PDF format for documents.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 1:29 ` thelma
@ 2020-12-10 2:16 ` Dale
0 siblings, 0 replies; 17+ messages in thread
From: Dale @ 2020-12-10 2:16 UTC (permalink / raw
To: gentoo-user
thelma@sys-concept.com wrote:
> On 12/09/2020 05:46 PM, thelma@sys-concept.com wrote:
>> On 12/09/2020 05:09 PM, Dale wrote:
>>> Howdy,
>>>
>>> I have a flatbed scanner. It's a old HP 4570. I been using Skanlite to
>>> scan pictures etc and it does a great job. On occasion tho I have a
>>> double sided document. I know how to scan them, scan one side, flip
>>> over and scan the back. That's easy enough. How do I print them the
>>> same way tho? Sometimes I use it like a copying machine basically.
>>> Scan in, then print. I'm not quite sure how to print the double sided
>>> stuff in one go tho.
>>>
>>> If someone does the same as me, can you share how you print them two
>>> sided? My printer is duplex so I just need to import both sides and
>>> tell it to print. I'm just not sure what software does that and makes
>>> it easy.
>>>
>>> Thoughts??
>>>
>>> Dale
>>>
>>> :_) :-)
>>>
>> Do you use XSane to scan it? You setup the printer in Setup menu under
>> "Copy" and scan in duplex mode. If you printer is setup by default to
>> print duplex it will print it correctly, in duplex. If not you will get
>> two pages, it prints directly to a printer (the print windows doesn't
>> pop-up).
>>
>> I suggest to scan it first to a document and print it in duplex.
> Correction. You have mentioned it is a flatbed scanner so you can not
> scan in duplex mode. Just create "multipage document" scan both sides,
> save it and you should be able to print it in duplex mode. I mostly use
> PDF format for documents.
>
>
>
Since I was wanting to get a copy made somewhat quick, I used
Libreoffice, LOo, to do it a bit ago. Thing is, it takes a bit to get
it to size correctly. It wants to shrink it and it is stubborn about
doing it that way. I just don't know of a easier way so I asked. I
figure there is a tool for this.
I have XSane installed but only used it a couple times. Skanlite was so
much quicker and easier to use that I stuck with it. I tried XSane and
I see a option for multi-page documents. I may play with that and see
how it does.
Another reason I'd like to be able to do this, pictures with names etc
on the back. It would be nice to get both the front and back of those.
Just need a easy tool to do it with. Maybe I can get XSane to do this
too.
Still open to ideas. Thanks for the info tho. ;-D
Dale
:-) :-)
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 0:09 [gentoo-user] Scanning double sided documents and printing them the same Dale
2020-12-10 0:46 ` thelma
@ 2020-12-10 8:27 ` Neil Bothwick
2020-12-10 9:20 ` Michael
2020-12-10 9:28 ` [gentoo-user] " J. Roeleveld
2020-12-10 15:37 ` Rich Freeman
3 siblings, 1 reply; 17+ messages in thread
From: Neil Bothwick @ 2020-12-10 8:27 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 1263 bytes --]
On Wed, 9 Dec 2020 18:09:29 -0600, Dale wrote:
> I have a flatbed scanner. It's a old HP 4570. I been using Skanlite to
> scan pictures etc and it does a great job. On occasion tho I have a
> double sided document. I know how to scan them, scan one side, flip
> over and scan the back. That's easy enough. How do I print them the
> same way tho? Sometimes I use it like a copying machine basically.
> Scan in, then print. I'm not quite sure how to print the double sided
> stuff in one go tho.
>
> If someone does the same as me, can you share how you print them two
> sided? My printer is duplex so I just need to import both sides and
> tell it to print. I'm just not sure what software does that and makes
> it easy.
I use gscan2pdf, although it sans to many more file formats. Scan to 2
page PDF and your printer can print in duplex.
Gscan2pdf has lots of nice features, I used to use it with an ADF and it
would scan all the sheets, then I'd turn the stack over and feed it back
in and it would scan the other sides and then put all the pages in the
correct order.
I have a duplex scanner now, but that was a real time saver.
--
Neil Bothwick
Evolution stops when stupidity is no longer fatal!
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 8:27 ` Neil Bothwick
@ 2020-12-10 9:20 ` Michael
2020-12-10 9:26 ` Neil Bothwick
2020-12-10 15:21 ` [gentoo-user] " Grant Edwards
0 siblings, 2 replies; 17+ messages in thread
From: Michael @ 2020-12-10 9:20 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 1827 bytes --]
On Thursday, 10 December 2020 08:27:33 GMT Neil Bothwick wrote:
> On Wed, 9 Dec 2020 18:09:29 -0600, Dale wrote:
> > I have a flatbed scanner. It's a old HP 4570. I been using Skanlite to
> > scan pictures etc and it does a great job. On occasion tho I have a
> > double sided document. I know how to scan them, scan one side, flip
> > over and scan the back. That's easy enough. How do I print them the
> > same way tho? Sometimes I use it like a copying machine basically.
> > Scan in, then print. I'm not quite sure how to print the double sided
> > stuff in one go tho.
> >
> > If someone does the same as me, can you share how you print them two
> > sided? My printer is duplex so I just need to import both sides and
> > tell it to print. I'm just not sure what software does that and makes
> > it easy.
>
> I use gscan2pdf, although it sans to many more file formats. Scan to 2
> page PDF and your printer can print in duplex.
>
> Gscan2pdf has lots of nice features, I used to use it with an ADF and it
> would scan all the sheets, then I'd turn the stack over and feed it back
> in and it would scan the other sides and then put all the pages in the
> correct order.
>
> I have a duplex scanner now, but that was a real time saver.
Alternatively, on the CLI you could use imagemagick to convert your png, tiff,
jpg, etc., to pdf:
convert scan1.png scan1.pdf
convert scan2.png scan2.pdf
Then join the two pdf documents into one with two pages, using poppler's
pdfunite:
pdfunite scan1.pdf scan2.pdf scanned.pdf
Then print them.
A simple script could batch up the conversion for you, e.g.:
for file in $(ls -t *.png | head -8); do
convert $file $file.pdf
done
The above will convert 8 png files to pdf, which you can then pdfunite into a
single multipage pdf document before you print it.
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 9:20 ` Michael
@ 2020-12-10 9:26 ` Neil Bothwick
2020-12-10 15:21 ` [gentoo-user] " Grant Edwards
1 sibling, 0 replies; 17+ messages in thread
From: Neil Bothwick @ 2020-12-10 9:26 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 1387 bytes --]
On Thu, 10 Dec 2020 09:20:22 +0000, Michael wrote:
> > Gscan2pdf has lots of nice features, I used to use it with an ADF and
> > it would scan all the sheets, then I'd turn the stack over and feed
> > it back in and it would scan the other sides and then put all the
> > pages in the correct order.
> >
> > I have a duplex scanner now, but that was a real time saver.
>
> Alternatively, on the CLI you could use imagemagick to convert your
> png, tiff, jpg, etc., to pdf:
>
> convert scan1.png scan1.pdf
> convert scan2.png scan2.pdf
>
> Then join the two pdf documents into one with two pages, using
> poppler's pdfunite:
>
> pdfunite scan1.pdf scan2.pdf scanned.pdf
>
> Then print them.
>
> A simple script could batch up the conversion for you, e.g.:
>
> for file in $(ls -t *.png | head -8); do
> convert $file $file.pdf
> done
>
> The above will convert 8 png files to pdf, which you can then pdfunite
> into a single multipage pdf document before you print it.
That's pretty much what I used to do. The nice thing about gscan2pdf's
way of doing it is that it copes with the second sides being scanned in
reverse order if you use an ADF. You could script that, but when someone
has already done it, laziness... I mean efficiency, wins.
--
Neil Bothwick
Anything is possible if you don't know what
you are talking about.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* [gentoo-user] Re: Scanning double sided documents and printing them the same.
2020-12-10 9:20 ` Michael
2020-12-10 9:26 ` Neil Bothwick
@ 2020-12-10 15:21 ` Grant Edwards
2020-12-10 17:36 ` Michael
1 sibling, 1 reply; 17+ messages in thread
From: Grant Edwards @ 2020-12-10 15:21 UTC (permalink / raw
To: gentoo-user
On 2020-12-10, Michael <confabulate@kintzios.com> wrote:
> On Thursday, 10 December 2020 08:27:33 GMT Neil Bothwick wrote:
[...]
>> I use gscan2pdf, although it sans to many more file formats. Scan to 2
>> page PDF and your printer can print in duplex.
>>
>> Gscan2pdf has lots of nice features, I used to use it with an ADF and it
>> would scan all the sheets, then I'd turn the stack over and feed it back
>> in and it would scan the other sides and then put all the pages in the
>> correct order.
>>
>> I have a duplex scanner now, but that was a real time saver.
>
> Alternatively, on the CLI you could use imagemagick to convert your png, tiff,
> jpg, etc., to pdf:
>
> convert scan1.png scan1.pdf
> convert scan2.png scan2.pdf
>
> Then join the two pdf documents into one with two pages, using poppler's
> pdfunite:
>
> pdfunite scan1.pdf scan2.pdf scanned.pdf
There's no need for the two-step process:
$ convert scan1.png scan2.png scanned.pdf
--
Grant
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Re: Scanning double sided documents and printing them the same.
2020-12-10 15:21 ` [gentoo-user] " Grant Edwards
@ 2020-12-10 17:36 ` Michael
2020-12-10 22:25 ` Grant Edwards
0 siblings, 1 reply; 17+ messages in thread
From: Michael @ 2020-12-10 17:36 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 1518 bytes --]
On Thursday, 10 December 2020 15:21:05 GMT Grant Edwards wrote:
> On 2020-12-10, Michael <confabulate@kintzios.com> wrote:
> > On Thursday, 10 December 2020 08:27:33 GMT Neil Bothwick wrote:
> [...]
>
> >> I use gscan2pdf, although it sans to many more file formats. Scan to 2
> >> page PDF and your printer can print in duplex.
> >>
> >> Gscan2pdf has lots of nice features, I used to use it with an ADF and it
> >> would scan all the sheets, then I'd turn the stack over and feed it back
> >> in and it would scan the other sides and then put all the pages in the
> >> correct order.
> >>
> >> I have a duplex scanner now, but that was a real time saver.
> >
> > Alternatively, on the CLI you could use imagemagick to convert your png,
> > tiff, jpg, etc., to pdf:
> >
> > convert scan1.png scan1.pdf
> > convert scan2.png scan2.pdf
> >
> > Then join the two pdf documents into one with two pages, using poppler's
> > pdfunite:
> >
> > pdfunite scan1.pdf scan2.pdf scanned.pdf
>
> There's no need for the two-step process:
>
> $ convert scan1.png scan2.png scanned.pdf
>
> --
> Grant
There was some vulnerability in ghostscript[1] which disabled the above
conversion - but I can't find the BGO number. I thought it had been patched
since then, but my system appears to not have been fixed:
$ convert scan1.jpg scan2.jpg scan.pdf
convert: attempt to perform an operation not allowed by the security policy
`PDF' @ error/constitute.c/IsCoderAuthorized/422.
[1] https://www.kb.cert.org/vuls/id/332928/
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* [gentoo-user] Re: Scanning double sided documents and printing them the same.
2020-12-10 17:36 ` Michael
@ 2020-12-10 22:25 ` Grant Edwards
2020-12-11 0:00 ` Dale
0 siblings, 1 reply; 17+ messages in thread
From: Grant Edwards @ 2020-12-10 22:25 UTC (permalink / raw
To: gentoo-user
On 2020-12-10, Michael <confabulate@kintzios.com> wrote:
>
>> There's no need for the two-step process:
>>
>> $ convert scan1.png scan2.png scanned.pdf
>
> There was some vulnerability in ghostscript[1] which disabled the above
> conversion - but I can't find the BGO number. I thought it had been patched
> since then, but my system appears to not have been fixed:
>
> $ convert scan1.jpg scan2.jpg scan.pdf
> convert: attempt to perform an operation not allowed by the security policy
> `PDF' @ error/constitute.c/IsCoderAuthorized/422.
>
> [1] https://www.kb.cert.org/vuls/id/332928/
You're right. You have to adjust the ImageMagick config files to allow
converting to pdf. AFAICT, it's safe as long as you trust the input
you're converting. I figure photos I've taken are OK.
--
Grant
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Re: Scanning double sided documents and printing them the same.
2020-12-10 22:25 ` Grant Edwards
@ 2020-12-11 0:00 ` Dale
2020-12-11 0:04 ` Dale
0 siblings, 1 reply; 17+ messages in thread
From: Dale @ 2020-12-11 0:00 UTC (permalink / raw
To: gentoo-user
Grant Edwards wrote:
> On 2020-12-10, Michael <confabulate@kintzios.com> wrote:
>>> There's no need for the two-step process:
>>>
>>> $ convert scan1.png scan2.png scanned.pdf
>> There was some vulnerability in ghostscript[1] which disabled the above
>> conversion - but I can't find the BGO number. I thought it had been patched
>> since then, but my system appears to not have been fixed:
>>
>> $ convert scan1.jpg scan2.jpg scan.pdf
>> convert: attempt to perform an operation not allowed by the security policy
>> `PDF' @ error/constitute.c/IsCoderAuthorized/422.
>>
>> [1] https://www.kb.cert.org/vuls/id/332928/
> You're right. You have to adjust the ImageMagick config files to allow
> converting to pdf. AFAICT, it's safe as long as you trust the input
> you're converting. I figure photos I've taken are OK.
>
> --
> Grant
>
I tried this in XSane but couldn't figure out how to get it to scan two
pages with me clicking something when the second page is ready. It
scanned first page, then scanned the second without giving me a chance
to flip it over. So, XSane didn't work this time. Maybe I'm doing
something wrong.
So, convert was my next test. I scanned in both sides, cd'd to the
directory where the files were and issued the command Grant provided.
At first, I got the security error. I dug around a bit and figured out
how to tell it to ignore that and tried again. YEPPIE!!! It worked. I
opened it in a pdf viewer and it was two pages. I don't need to print
this one but I can send it to a friend since it is her mail, sort of.
If I needed to print it, it should print duplex just fine.
It's command line but it works. It's awesome. Still open to
suggestions but for now, I got something working. It's easier than
using LOo for sure.
Dale
:-) :-)
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Re: Scanning double sided documents and printing them the same.
2020-12-11 0:00 ` Dale
@ 2020-12-11 0:04 ` Dale
0 siblings, 0 replies; 17+ messages in thread
From: Dale @ 2020-12-11 0:04 UTC (permalink / raw
To: gentoo-user
Dale wrote:
> Grant Edwards wrote:
>> On 2020-12-10, Michael <confabulate@kintzios.com> wrote:
>>>> There's no need for the two-step process:
>>>>
>>>> $ convert scan1.png scan2.png scanned.pdf
>>> There was some vulnerability in ghostscript[1] which disabled the above
>>> conversion - but I can't find the BGO number. I thought it had been patched
>>> since then, but my system appears to not have been fixed:
>>>
>>> $ convert scan1.jpg scan2.jpg scan.pdf
>>> convert: attempt to perform an operation not allowed by the security policy
>>> `PDF' @ error/constitute.c/IsCoderAuthorized/422.
>>>
>>> [1] https://www.kb.cert.org/vuls/id/332928/
>> You're right. You have to adjust the ImageMagick config files to allow
>> converting to pdf. AFAICT, it's safe as long as you trust the input
>> you're converting. I figure photos I've taken are OK.
>>
>> --
>> Grant
>>
>
> I tried this in XSane but couldn't figure out how to get it to scan two
> pages with me clicking something when the second page is ready. It
> scanned first page, then scanned the second without giving me a chance
> to flip it over. So, XSane didn't work this time. Maybe I'm doing
> something wrong.
>
> So, convert was my next test. I scanned in both sides, cd'd to the
> directory where the files were and issued the command Grant provided.
> At first, I got the security error. I dug around a bit and figured out
> how to tell it to ignore that and tried again. YEPPIE!!! It worked. I
> opened it in a pdf viewer and it was two pages. I don't need to print
> this one but I can send it to a friend since it is her mail, sort of.
> If I needed to print it, it should print duplex just fine.
>
> It's command line but it works. It's awesome. Still open to
> suggestions but for now, I got something working. It's easier than
> using LOo for sure.
>
> Dale
>
> :-) :-)
>
Oh, forgot this. File to change: /etc/ImageMagick-7/policy.xml and
change this line to look like this:
<policy domain="coder" rights="read|write" pattern="PDF" />
I'm not sure how important the spaces in front are so I'm including
them. I'd make sure it matches the other lines above and below that one.
I'm not sure how to put comments in this file either.
Dale
:-) :-)
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 0:09 [gentoo-user] Scanning double sided documents and printing them the same Dale
2020-12-10 0:46 ` thelma
2020-12-10 8:27 ` Neil Bothwick
@ 2020-12-10 9:28 ` J. Roeleveld
2020-12-10 10:49 ` Dr Rainer Woitok
2020-12-10 15:37 ` Rich Freeman
3 siblings, 1 reply; 17+ messages in thread
From: J. Roeleveld @ 2020-12-10 9:28 UTC (permalink / raw
To: gentoo-user
On Thursday, December 10, 2020 1:09:29 AM CET Dale wrote:
> Howdy,
>
> I have a flatbed scanner. It's a old HP 4570. I been using Skanlite to
> scan pictures etc and it does a great job. On occasion tho I have a
> double sided document. I know how to scan them, scan one side, flip
> over and scan the back. That's easy enough. How do I print them the
> same way tho? Sometimes I use it like a copying machine basically.
> Scan in, then print. I'm not quite sure how to print the double sided
> stuff in one go tho.
>
> If someone does the same as me, can you share how you print them two
> sided? My printer is duplex so I just need to import both sides and
> tell it to print. I'm just not sure what software does that and makes
> it easy.
>
> Thoughts??
>
> Dale
>
> :_) :-)
My old printer/scanner can scan directly to PDF using the sheetfeeder.
For double-sided, I always ended up with 1 PDF with odd-pages and 1 with even.
There used to be tools available (python-old) that could shuffle these
together and merge them into a single PDF, which would allow for easy reading/
printing.
Currently, I would have to manually convert these to single-pages and then
merge them, again, manually.
This is the downside of single-sided sheetfeeders.
If you do the scans manually (eg. no sheetfeeders) you should be able to get
them all in the correct order in a PDF. The PDF can then be printed double-
sided and you get them the same way. (Just scan them "dummy-mode" and add
white-pages when the back of the sheet is white)
--
Joost
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 9:28 ` [gentoo-user] " J. Roeleveld
@ 2020-12-10 10:49 ` Dr Rainer Woitok
2020-12-10 13:09 ` J. Roeleveld
0 siblings, 1 reply; 17+ messages in thread
From: Dr Rainer Woitok @ 2020-12-10 10:49 UTC (permalink / raw
To: gentoo-user, J. Roeleveld
Joost,
On Thursday, 2020-12-10 10:28:05 +0100, you wrote:
> ...
> My old printer/scanner can scan directly to PDF using the sheetfeeder.
> For double-sided, I always ended up with 1 PDF with odd-pages and 1 with even.
>
> There used to be tools available (python-old) that could shuffle these
> together and merge them into a single PDF, which would allow for easy reading/
> printing.
$ pdftk odd.pdf even.pdf shuffle output all.pdf
Command "pdftk" comes with package "app-text/pdftk".
Sincerely,
Rainer
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 10:49 ` Dr Rainer Woitok
@ 2020-12-10 13:09 ` J. Roeleveld
0 siblings, 0 replies; 17+ messages in thread
From: J. Roeleveld @ 2020-12-10 13:09 UTC (permalink / raw
To: gentoo-user
Please do not include me in list-replies. I am subscribed.
On Thursday, December 10, 2020 11:49:06 AM CET Dr Rainer Woitok wrote:
> Joost,
>
> On Thursday, 2020-12-10 10:28:05 +0100, you wrote:
> > ...
> > My old printer/scanner can scan directly to PDF using the sheetfeeder.
> > For double-sided, I always ended up with 1 PDF with odd-pages and 1 with
> > even.
> >
> > There used to be tools available (python-old) that could shuffle these
> > together and merge them into a single PDF, which would allow for easy
> > reading/ printing.
>
> $ pdftk odd.pdf even.pdf shuffle output all.pdf
>
> Command "pdftk" comes with package "app-text/pdftk".
>
> Sincerely,
> Rainer
That's a java-port of the original pdftk.
I actually solved the issue by getting a double-sided ADF scanner.
--
Joost
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 0:09 [gentoo-user] Scanning double sided documents and printing them the same Dale
` (2 preceding siblings ...)
2020-12-10 9:28 ` [gentoo-user] " J. Roeleveld
@ 2020-12-10 15:37 ` Rich Freeman
2020-12-10 17:58 ` J. Roeleveld
3 siblings, 1 reply; 17+ messages in thread
From: Rich Freeman @ 2020-12-10 15:37 UTC (permalink / raw
To: gentoo-user
On Wed, Dec 9, 2020 at 7:09 PM Dale <rdalek1967@gmail.com> wrote:
>
> How do I print them the
> same way tho?
I didn't see much discussion on the printing side of this - how to
print two-sided on a one-sided printer.
Step 1 (optional): I created a CUPS queue for such jobs that just
outputs everything into PDF in a directory. This lets you easily
print stuff that isn't already PDF from various computers/OSes and
accumulate a bunch as printing this way is easier in bulk since it
involves a bit of manual manipulation.
Step 2 (optional): I have a script that takes each PDF and adds a
blank page if needed to result in an even number of pages, then
concatenates all the PDFs into a single file. I probably stole this
from somewhere:
#!/bin/bash
for file in *.pdf
do
#get the number of pages
numberofpages=`pdftk "$file" dump_data | sed -e
'/NumberOfPages/!d;s/NumberOfPages: //'`
echo -n "$file" 'has' $numberofpages 'pages, '
uneven=$(($numberofpages % 2))
if [ $uneven == 1 ]
then
echo 'which is uneven - added 1 more'
tempfile=`mktemp`
pdftk A="$file" B=/usr/local/share/blank.pdf cat A B1 output "$tempfile"
mv $tempfile $file
else
echo 'which is even'
fi
done
pdftk *.pdf cat output out.pdf
Step 3: To print a single PDF double-sided follow this guide:
http://duramecho.com/ComputerInformation/HowToDoTwoSidedPrinting/index.html
So the idea is that I accumulate a bunch of documents to print this
way, combine them such that they can be printed all at once, and then
do the page flip technique in that guide. No need to worry about
individual pages as long as you ID which type of printer you have and
follow the appropriate process. However, to print multiple documents
at once this way they all have to have an even number of pages, which
is why I have the script. Concatenating the files with blank pages
added means that you can just print the whole thing once, flip, then
print it again, and it all works.
--
Rich
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [gentoo-user] Scanning double sided documents and printing them the same.
2020-12-10 15:37 ` Rich Freeman
@ 2020-12-10 17:58 ` J. Roeleveld
0 siblings, 0 replies; 17+ messages in thread
From: J. Roeleveld @ 2020-12-10 17:58 UTC (permalink / raw
To: gentoo-user
On 10 December 2020 16:37:31 CET, Rich Freeman <rich0@gentoo.org> wrote:
>On Wed, Dec 9, 2020 at 7:09 PM Dale <rdalek1967@gmail.com> wrote:
>>
>> How do I print them the
>> same way tho?
>
>I didn't see much discussion on the printing side of this - how to
>print two-sided on a one-sided printer.
>
>Step 1 (optional): I created a CUPS queue for such jobs that just
>outputs everything into PDF in a directory. This lets you easily
>print stuff that isn't already PDF from various computers/OSes and
>accumulate a bunch as printing this way is easier in bulk since it
>involves a bit of manual manipulation.
>
>Step 2 (optional): I have a script that takes each PDF and adds a
>blank page if needed to result in an even number of pages, then
>concatenates all the PDFs into a single file. I probably stole this
>from somewhere:
>
>#!/bin/bash
>for file in *.pdf
>do
> #get the number of pages
> numberofpages=`pdftk "$file" dump_data | sed -e
>'/NumberOfPages/!d;s/NumberOfPages: //'`
> echo -n "$file" 'has' $numberofpages 'pages, '
>
> uneven=$(($numberofpages % 2))
> if [ $uneven == 1 ]
> then
> echo 'which is uneven - added 1 more'
> tempfile=`mktemp`
>pdftk A="$file" B=/usr/local/share/blank.pdf cat A B1 output
>"$tempfile"
> mv $tempfile $file
> else
> echo 'which is even'
> fi
>done
>
>pdftk *.pdf cat output out.pdf
>
>Step 3: To print a single PDF double-sided follow this guide:
>http://duramecho.com/ComputerInformation/HowToDoTwoSidedPrinting/index.html
>
>So the idea is that I accumulate a bunch of documents to print this
>way, combine them such that they can be printed all at once, and then
>do the page flip technique in that guide. No need to worry about
>individual pages as long as you ID which type of printer you have and
>follow the appropriate process. However, to print multiple documents
>at once this way they all have to have an even number of pages, which
>is why I have the script. Concatenating the files with blank pages
>added means that you can just print the whole thing once, flip, then
>print it again, and it all works.
I used to do that manually.
Printing from PDF is supported by my printer directly from USB stick, so never did have to play around with scripts like that.
They may come in handy in future though.
--
Joost
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
^ permalink raw reply [flat|nested] 17+ messages in thread