Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

FYI: converting a pdf file 2pages across into single page pdf

28 views
Skip to first unread message

root

unread,
Jan 8, 2012, 11:18:41 PM1/8/12
to
I hate to read come across a pdf file that has two pages across.
It is much harder to read than single pages. I spent the best
part of today trying to find a way to convert the pdf file
into single pages.

I hope I can save everyone the trouble I went through. Here
is what I found:

1. Forget about PDF split, and any tool that talks about
splitting the pdf. Splitting in this context refers
to separating the whole pdf file into individual pages.
2. Forget about anything that uses pdftk, although that
utility is useful for 1. above and cat-ting the results
back to a single file. [Aside: some people put crap in
pdf files as advertisements or whatever. They usually
say something like "If you have trouble reading this
file use xxx instead of Adobe Acrobat". pdftk can
be used to toss out that crap.]
3. The utility you want to use is briss. The current version
I use is briss-0.0.13

4. Start with a small book to work out the procedure. You
can use pdftk to select out, say, 10 pages and put
them back into a single test.pdf file. This small
file will make your learning time shorter.

5. You bring up briss by a command:
java -jar briss-0.0.13.jar ......
where .... is the rest of the command. It is easier if you
create an alias for the java part, and give the complete path
to the .jar file. That way you can invoke briss wherever you
are.

You have to be under X to do this stuff.

6. In the directory where you have the test.pdf file do:
briss test.pdf
It takes a while for briss to load in the file. Don't
worry, I just did a 476 page pdf file and it was done
in a few minutes.

7. Now here is the part that may be difficult to describe:
When the file is loaded you will see two pages of your
text, one above the other. The top page will be two pages
of the pdf file, say pages 0,1 (remember page 1 is always
on the right). The bottom two pages will be pages 2,3
of the pdf file.

8. The pages will be shown in blue. Using your mouse
go to the right hand side of the top two pages and
press down the left button and push the blue part to
the left so the right hand edge of the blue part is
at the middle of the page. Release the mouse button.

9. Go to the top of the second half of the top page, and
click on the upper left hand corner of the second
column of text. Hold the mouse button down and
move to the lower right of that column. You are
"marking" the second column. When you release the
mouse button the second column will be marked as 2.

To even up the margins of the two half pages
move the mouse into each of them and hold the
control key down and left click the mouse. A
black border will be written around the half page.

10. You then do the same as steps 8,9 for the second
two pages of text. There may be a way to simplify
this step, but I forget how.

My wife reminds me of the simple method for the
second. After you get the four pages as I mentioned
above, you push the bottom blue section all the
way off screen to the left.

You right click on each of pages 1,2 in the top
screen and select "select" from the menu. That
will draw the black borders. Then you right
click and select "copy".

Then you right click and select "paste" in the bottom
two pages. You right click when the mouse cursor
is in the bottom two pages.

11. Then right click and select "crop".

Almost instantaneously the file test_cropped.pdf pops
up. Close down the window and take a look at the
cropped file.

It took me all day to find and perfect this, maybe
it will help someone. It turns out to be easier
than it may seem to you now.

Jasen Betts

unread,
Jan 9, 2012, 3:08:04 AM1/9/12
to
On 2012-01-09, root <NoE...@home.org> wrote:
> I hate to read come across a pdf file that has two pages across.
> It is much harder to read than single pages. I spent the best
> part of today trying to find a way to convert the pdf file
> into single pages.
>
> I hope I can save everyone the trouble I went through. Here
> is what I found:
>
> 1. Forget about PDF split, and any tool that talks about
> splitting the pdf. Splitting in this context refers
> to separating the whole pdf file into individual pages.
> 2. Forget about anything that uses pdftk, although that
> utility is useful for 1. above and cat-ting the results
> back to a single file. [Aside: some people put crap in
> pdf files as advertisements or whatever. They usually
> say something like "If you have trouble reading this
> file use xxx instead of Adobe Acrobat". pdftk can
> be used to toss out that crap.]
> 3. The utility you want to use is briss. The current version
> I use is briss-0.0.13

I would have tried using ghostscript and psutils:

pdf2ps, psnup, pstopdf


--
⚂⚃ 100% natural

--- Posted via news://freenews.netfront.net/ - Complaints to ne...@netfront.net ---

root

unread,
Jan 9, 2012, 11:02:07 AM1/9/12
to
That reminds me, another thing that *didn't* work was
a small script called unpnup which uses pdftk, pdftops,
poster, and then epstopdf. It was the poster step that
I couldn't get to work.

I couldn't be happier with the result of briss. In spite
of my clumsy description of how to use it, a few minutes
of experiments will get you up to speed.

There is one problem with briss: the authors don't have
a clue about sizing the display to enable the user to
perform the necessary operations.

unruh

unread,
Jan 9, 2012, 11:44:42 AM1/9/12
to
As far as I can see, psnup goes the wrong way-- putting multiple pages
onto one sheet rather than breaking up multiple pages on one sheet into
many sheets.
The op had something perhaps created by psnup-- two pages on one sheet,
and wants them broken up into two pages on two sheets.


unruh

unread,
Jan 9, 2012, 11:49:45 AM1/9/12
to
The problem with your solution is that it requires a lot of hand work.
What would be much nicer would be an automated scheme The job is simple
enough that it should be automatable. What problem did you have with
poster?


root

unread,
Jan 9, 2012, 12:50:53 PM1/9/12
to
unruh <un...@invalid.ca> wrote:
>
> The problem with your solution is that it requires a lot of hand work.
> What would be much nicer would be an automated scheme The job is simple
> enough that it should be automatable. What problem did you have with
> poster?
>
>

It isn't *my* solution, I had nothing to do with briss. Neither is it
really a lot of work, you have to map out two pages of the input
and the program takes care of the rest of the book.

As far as poster goes, the first problem was which poster. There were
several candidates that came up for installation. When I finally
figured out which was the right one, it simply didn't work.

The steps in unpnup are:
pdftk "$1" burst
for file in pg*.pdf;
do
pdftops -eps $file
poster -v -pA4 -mA5 -c0% `basename $file .pdf`.eps > `basename $file .pdf`.tps
epstopdf `basename $file .pdf`.tps
done
pdftk pg*.pdf cat output ../`basename $1 .pdf`_unpnuped.pdf

The first line bursts the pdf into individual files of each
two-page images. Then, for each of those, the file is converted
into an eps ps file. I can look at that file and the conversion
worked. I used gv to see that file. The poster step is to
convert that file into a different ps format of two pages.
Using gv to view that .tps file the file was mostly blank
with some shreds of text as if torn from the page. The last
step, the epstopdf just yielded an image of the .tps file
which was junk.

It took me a while to understand the -p -m options of poster
and to find out that they didn't affect the outcome in that
the result still did not contain readable text.

I said my wife and I spent the good part of the day trying
to find something that worked. A good part of that good part
was wasted on the unpnup script.

unruh

unread,
Jan 9, 2012, 5:38:11 PM1/9/12
to
On 2012-01-09, root <NoE...@home.org> wrote:
> unruh <un...@invalid.ca> wrote:
>>
>> The problem with your solution is that it requires a lot of hand work.
>> What would be much nicer would be an automated scheme The job is simple
>> enough that it should be automatable. What problem did you have with
>> poster?
>>
>>
>
> It isn't *my* solution, I had nothing to do with briss. Neither is it

"your" solution as in "the solution you advocated", not "the program you
wrote"


> really a lot of work, you have to map out two pages of the input
> and the program takes care of the rest of the book.

Ah, I thought you had to go through the procedure for each and every
page.

>
> As far as poster goes, the first problem was which poster. There were
> several candidates that came up for installation. When I finally
> figured out which was the right one, it simply didn't work.

I agree, I cannot seem to get poster to work either. When I try to view
it via gv, I get a syntax error every time. Looks like it is either
very old, or some bugs have crept in ( version poster-0-0.20060221 which
is rather old (6 years old)).

root

unread,
Jan 9, 2012, 7:37:08 PM1/9/12
to
unruh <un...@invalid.ca> wrote:
>
>> really a lot of work, you have to map out two pages of the input
>> and the program takes care of the rest of the book.
>
> Ah, I thought you had to go through the procedure for each and every
> page.
>

I have successfully converted 4 books now, but on the 5th
I am having trouble. In the past it seems that briss needed
only for me to split the first two pages, thereafter it
was able to do the rest of the book. On this, my 6th book
that doesn't seem to be happening. I have tried teaching it
the first two pages, four pages, and six pages. Each time
it correctly splits the pages I split, but the rest of the
book comes up double. I am back to the learning phase.

I know that there are different kinds of pdf files, maybe
briss doesn't work for all of them.

John Hasler

unread,
Jan 9, 2012, 7:44:04 PM1/9/12
to
unruh writes:
> I agree, I cannot seem to get poster to work either. When I try to
> view it via gv, I get a syntax error every time. Looks like it is
> either very old, or some bugs have crept in ( version
> poster-0-0.20060221 which is rather old (6 years old)).

Debian has 20050907 which would seem older yet but it works fine here.
I recently used it for something close to its intended purpose.

root wrote:
> It took me a while to understand the -p -m options of poster and to
> find out that they didn't affect the outcome in that the result still
> did not contain readable text.

Poster gives you very little control of the positioning of the output.
I had to edit the bounding box in the Postscript file I fed it in order
to get it to put my long, narrow drawing on two sheets instead of eight
(most of which were empty). I used the "-s" option to get the exact
scale I wanted.
--
John Hasler
jha...@newsguy.com
Dancing Horse Hill
Elmwood, WI USA

root

unread,
Jan 9, 2012, 7:54:20 PM1/9/12
to
I found out what the problem was: The original pdf file
had the first five or six pages 2-across in landscape
mode. Then there was a page with two across in portrait
mode, i.e., turned sideways. briss found the irregular
page and presented all the text up to that page for
cutting.

For the record, if that happens to you, just delete
the rectangle on the irregular page and let briss
take off.

You will understand what is meant by delete the rectangle
when you are using briss. It means right click on the
rectangle and select delete: the blue goes away.


unruh

unread,
Jan 9, 2012, 10:01:29 PM1/9/12
to
Yes, I noticed that (from the output as it ran). I had a standard 8.5x11
page which I tried to poster, and I had to use -s 1.2 to get it onto two
pages. Anything larger and it put it onto 4 or 8 pages.
Maybe A4->A3 would work better.

John Hasler

unread,
Jan 9, 2012, 10:33:45 PM1/9/12
to
unruh writes:
> I had a standard 8.5x11 page which I tried to poster, and I had to use
> -s 1.2 to get it onto two pages. Anything larger and it put it onto 4
> or 8 pages. Maybe A4->A3 would work better.

I think that the problem is that most programs that generate Postscript
use the entire page as a bounding box and Poster does not know how to
trim off the white space. When I did so manually I got sensible
results.

unruh

unread,
Jan 10, 2012, 12:47:23 AM1/10/12
to
On 2012-01-10, John Hasler <jha...@newsguy.com> wrote:
> unruh writes:
>> I had a standard 8.5x11 page which I tried to poster, and I had to use
>> -s 1.2 to get it onto two pages. Anything larger and it put it onto 4
>> or 8 pages. Maybe A4->A3 would work better.
>
> I think that the problem is that most programs that generate Postscript
> use the entire page as a bounding box and Poster does not know how to
> trim off the white space. When I did so manually I got sensible
> results.

It was even worst when I used a file which had a
BoundingBox: 136 121 476 671
which certainly is not the whole page. When I told it I wanted it
doubled, I got 8 pages. (from the -v option of program)
(It always gave me a syntax error

Hm just tried it on a mandriva 2009.1 distro, and now it sort of
displays, except the page that is displayed by gv seems to change from
attempt to attempt. It produced 2 pages, 1,1 and 1,2 and if I click on
1,1 I sometimes get a blank page, sometime the left side of the orginal
and sometimes the right side. Something is very very confused.


0 new messages