Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
how to print multiple pages on one with cups - easy :)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
LGW
n00b
n00b


Joined: 02 Oct 2002
Posts: 60

PostPosted: Sun Jan 16, 2005 12:20 pm    Post subject: how to print multiple pages on one with cups - easy :) Reply with quote

after using mpage on .ps-files manually quite a while, I wanted an EASY way to print multiple pages on one, preferably by using different printers, one for normal printing, one for 2-page printing.

After a bit of whining and googling I found this VERY simple solution requiring no extra packages at all:

1. add your printer *again* in cups so you have two printers pointing to the same device, i.e.
Kyocera
Kyocera2page

2. as root (or, if you want this per-user, as the user), do:
lpoptions -p Kyocera2page -o number-up=2
this adds the parameter to the file /etc/cups/lpoptions or $HOME/.lpoptions

valid numbers seem to be 1,2,4.

I should have used google a year ago :(

have fun with it :)
that's it. go printing!
Back to top
View user's profile Send private message
AlterEgo
Veteran
Veteran


Joined: 25 Apr 2002
Posts: 1619

PostPosted: Sun Jan 16, 2005 1:11 pm    Post subject: Reply with quote

I have a Brother HL1430 printer, and use the HL1250 driver as recommended.
With your trick, it does print 2 pages per sheet, but it leaves the first page blank: the first paper sheet is half filled: the left side is blank, the right side is printed with "page 2". Pages 3 and further are OK.

I am not sure if this is caused by this specific printer, but suggestions are welcome.
Back to top
View user's profile Send private message
BlackEdder
Advocate
Advocate


Joined: 26 Apr 2004
Posts: 2588
Location: Dutch enclave in Egham, UK

PostPosted: Sun Jan 16, 2005 4:03 pm    Post subject: Reply with quote

Code:
#!/usr/bin/ruby
if File.ftype(ARGV[0]) != "file"
        puts "#{ARGV[0]} is not a file"
else
        file=ARGV[0]
        `lp -o outputorder=reverse -o page-set=even -o number-up=2 -o page-border=double #{file}`
        puts "Turn paper (text down, title to the left) and press enter"
  tmp=$stdin.gets
        `lp -o page-set=odd -o number-up=2 -o page-border=double #{file}`
end


I made this ruby script ome time ago. It also allows for double sided printing. Feel free to use it. It only works with pdf and ps files though AFAIK
Back to top
View user's profile Send private message
LGW
n00b
n00b


Joined: 02 Oct 2002
Posts: 60

PostPosted: Fri Feb 04, 2005 12:18 pm    Post subject: Reply with quote

AlterEgo, I have the same problem with some documents too. Seems to be a pstools problem, though :(
Back to top
View user's profile Send private message
spockpv
n00b
n00b


Joined: 26 May 2004
Posts: 22

PostPosted: Mon Apr 04, 2005 9:55 am    Post subject: Re: how to print multiple pages on one with cups - easy :) Reply with quote

LGW wrote:
after using mpage on .ps-files manually quite a while, I wanted an EASY way to print multiple pages on one, preferably by using different printers, one for normal printing, one for 2-page printing.

After a bit of whining and googling I found this VERY simple solution requiring no extra packages at all:

1. add your printer *again* in cups so you have two printers pointing to the same device, i.e.
Kyocera
Kyocera2page

2. as root (or, if you want this per-user, as the user), do:
lpoptions -p Kyocera2page -o number-up=2
this adds the parameter to the file /etc/cups/lpoptions or $HOME/.lpoptions

valid numbers seem to be 1,2,4.

I should have used google a year ago :(

have fun with it :)
that's it. go printing!


Using this method, can you print .doc files in openoffice, or .pdf files in acrobat reader, 2 pages in one sheet? Or does it work only with text and ps files, from the command line?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum