Unoffical empeg BBS

Quick Links: Empeg FAQ | RioCar.Org | Hijack | BigDisk Builder | jEmplode | emphatic
Repairs: Repairs

Topic Options
#313216 - 26/08/2008 21:39 Simple (?) Adobe Acrobat question
tanstaafl.
carpal tunnel

Registered: 08/07/1999
Posts: 5549
Loc: Ajijic, Mexico
I know... every time I ask what I think is a simple question the answers turn out to be so complicated I have a hard time following them. But this one really should be simple.

I have a 15 page document that someone sent me, scanned in and saved as a single file of PDF pages. She had the pages rotated 180 degrees when she scanned them, so they display on my monitor upside down.

Is there a simple way to fix this, other than trying to balance my monitor on its top? I don't think I have any tools that can edit PDF files.

tanstaafl.
_________________________
"There Ain't No Such Thing As A Free Lunch"

Top
#313217 - 26/08/2008 21:50 Re: Simple (?) Adobe Acrobat question [Re: tanstaafl.]
Robotic
pooh-bah

Registered: 06/04/2005
Posts: 2026
Loc: Seattle transplant
I think there's an option to rotate the view of the document.
It might be hidden in a default setup and you'll have to 'customize' the toolbar.

Hmmm... (goes to look)

Yup! You can rotate the view from the 'View' menu in 90 degree increments.
Unfortunately, that only applies to a single viewing of the document- it doesn't change it for the next time you open it.

If you're quick with your keyboard, shft&ctrl&+ or - will rotate the view.


Edited by Robotic (26/08/2008 21:55)
_________________________
10101311 (20GB- backup empeg)
10101466 (2x60GB, Eutronix/GreenLights Blue) (Stolen!)

Top
#313225 - 27/08/2008 01:57 Re: Simple (?) Adobe Acrobat question [Re: Robotic]
gbeer
carpal tunnel

Registered: 17/12/2000
Posts: 2665
Loc: Manteca, California
Unless you have the full version of Acrobat. Then you may save it in that orientation.
_________________________
Glenn

Top
#313239 - 27/08/2008 16:36 Re: Simple (?) Adobe Acrobat question [Re: gbeer]
ricin
veteran

Registered: 19/06/2000
Posts: 1495
Loc: US: CA
Try this out.
I'm guessing you're in Windows. Just unzip this and run:

Code:
rotatePdf input.pdf output.pdf 180


Attachments
rotatePdf.zip (23 downloads)

_________________________
Donato
MkII/080000565
MkIIa/010101253
ricin.us

Top
#313240 - 27/08/2008 17:01 Re: Simple (?) Adobe Acrobat question [Re: tanstaafl.]
matthew_k
pooh-bah

Registered: 12/02/2002
Posts: 2298
Loc: Berkeley, California
This is one of those "it just works" things on a mac. Built into preview, the program used for opening most any standard file, you go to Tools>Rotate Left or Rotate Right, and then save it.

Matthew

Top
#313252 - 28/08/2008 03:27 Re: Simple (?) Adobe Acrobat question [Re: ricin]
tanstaafl.
carpal tunnel

Registered: 08/07/1999
Posts: 5549
Loc: Ajijic, Mexico
Quote:
Just unzip this and run:


That did the trick. Thank you.

I thought I'd be clever and use my "Print to PDF" utility, but that didn't work. I could change the orientation using the "View" tab in Acrobat, but if I selected the Print to File option, Acrobat wouldn't recognize it as valid format, and deselecting the Print to File option saved it as an Acrobat file -- but still inverted.

tanstaafl.
_________________________
"There Ain't No Such Thing As A Free Lunch"

Top
#313253 - 28/08/2008 03:31 Re: Simple (?) Adobe Acrobat question [Re: tanstaafl.]
Robotic
pooh-bah

Registered: 06/04/2005
Posts: 2026
Loc: Seattle transplant
I use PDFCreator, which acts like a printer, but I don't think that I can print a pdf to PDFCreator for some reason.

Glad you worked it out!
_________________________
10101311 (20GB- backup empeg)
10101466 (2x60GB, Eutronix/GreenLights Blue) (Stolen!)

Top
#313308 - 28/08/2008 19:52 Re: Simple (?) Adobe Acrobat question [Re: Robotic]
ricin
veteran

Registered: 19/06/2000
Posts: 1495
Loc: US: CA
Just in case anyone wants to do something else with this, here's the hack code...

Code:
import com.lowagie.text.DocumentException;
import com.lowagie.text.pdf.PdfNumber;
import com.lowagie.text.pdf.PdfReader;
import com.lowagie.text.pdf.PdfName;
import com.lowagie.text.pdf.PdfStamper;
import java.io.FileOutputStream;
import java.io.IOException;

public class RotatePages
{
    public static void main(String[] args)
    {
        String fileName = "";
        String outFileName = "";
        int degrees = 0;
        String usage = "usage: RotatePages <input> <output> <degrees>";

        if (args.length > 2)
        {
            fileName = args[0];
            outFileName = args[1];
            try
            {
                degrees = Integer.parseInt(args[2]);
                if (degrees != 90 && degrees != 180)
                {
                    System.out.println("Entered: " + degrees);
                    throw new NumberFormatException();
                }
            }
            catch (NumberFormatException e)
            {
                System.out.println(usage);
                System.out.println("Please specify either 90 or 180 degrees.");
                return;
            }
        }
        else
        {
            System.out.println(usage);
            return;
        }
        try
        {
            System.out.println("Rotating all pages in " + fileName + " by "
                + degrees + " degrees.");

            PdfReader reader = new PdfReader(fileName);

            for (int p = 1; p <= reader.getNumberOfPages(); ++p)
            {
                reader.getPageN(p).put(PdfName.ROTATE, new PdfNumber(degrees));
            }

            PdfStamper stp = new PdfStamper(reader, new FileOutputStream(
                outFileName));
            stp.close();
            System.out.println("Writing " + outFileName + " ...");
        }
        catch (DocumentException e)
        {
            e.printStackTrace();
        }
        catch (IOException e)
        {
            e.printStackTrace();
        }
    }
}
_________________________
Donato
MkII/080000565
MkIIa/010101253
ricin.us

Top