Bug 691399 - Trying to print landscape instead of portrait using pdf2pcl
Summary: Trying to print landscape instead of portrait using pdf2pcl
Status: RESOLVED INVALID
Alias: None
Product: Ghostscript
Classification: Unclassified
Component: Other Driver (show other bugs)
Version: master
Hardware: PC Windows 2000
: P4 normal
Assignee: Henry Stiles
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-17 09:55 UTC by Colin Murray
Modified: 2013-04-30 17:55 UTC (History)
1 user (show)

See Also:
Customer:
Word Size: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Colin Murray 2010-06-17 09:55:56 UTC
Hi There. I am trying to print landscape using pdf2pcl. It keeps printing portrait. Please see below. I am not a programmer so if I can have some advice that would be great. A Dummies guide would be ideal. Hopefully just a simple config change to my command. Thanks in advance.

#!/bin/sh
# $Id: pdf2pcl 6300 2005-12-28 19:56:24Z giles $
# Convert PDF to PCL.

# 

This definition is changed on install to match the
# executable name set in the makefile
GS_EXECUTABLE=gs

OPTIONS=""
while true
do
	case "$1" in
	-?*) OPTIONS="$OPTIONS $1" 

;;
	*)  break ;;
	esac
	shift
done

if [ $# -eq 2 ] 
then
    outfile=$2
elif [ $# 

-eq 1 ]
then
    outfile=`basename "$1" \.pdf`.pcl
else
    echo "Usage: `basename $0` 

[-dASCII85EncodePages=false] [-dLanguageLevel=1|2|3] input.pdf [output.pcl]" 1>&2
    exit 

1
fi

# Doing an initial 'save' helps keep fonts from being flushed between pages.
# We have 

to include the options twice because -I only takes effect if it
# appears before other 

options.
exec $GS_EXECUTABLE $OPTIONS -dQUIET -dNOPAUSE -dBATCH -sDEVICE=ljet4 

"-sOutputFile=$outfile" $OPTIONS -c save pop -f "$1"
Comment 1 Hin-Tak Leung 2013-01-02 22:20:10 UTC
It appears the ljet4 driver have the paper size hard coded to be either letter or A4 (and nothing else), and possibly orientation also. Does -dFIXEDMEDIA work?

Anyway, this has nothing to do with PXL driver...
Comment 2 Henry Stiles 2013-04-30 17:55:50 UTC
We do have an open bug (693715) about printing in landscape orientation, which might effect you, if that is the issue here please add a description of your problem into that bug.  

If you are just asking about how to set a command line option for paper sizes or related parameters we recommend reading the documentation, gs/doc/Use.htm should be useful.  If that doesn't answer your question use http://stackoverflow.com/questions/tagged/ghostscript.  Here at bugzilla we deal with defects and enhancements in ghostscript, stackoverflow is a good place for general usage questions.