[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

rpms/cups/devel textonly.filter, NONE, 1.1 textonly.ppd, NONE, 1.1 cups.spec, 1.280, 1.281



Author: twaugh

Update of /cvs/dist/rpms/cups/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv3253

Modified Files:
	cups.spec 
Added Files:
	textonly.filter textonly.ppd 
Log Message:
* Tue Oct 31 2006 Tim Waugh <twaugh redhat com>
- Added filter and PPD for text-only printer (bug #213030).
- Resolves: rhbz#213030



--- NEW FILE textonly.filter ---
#!/bin/bash
## Copyright (C) 2003-2006 Red Hat, Inc.
## Copyright (C) 2003-2006 Tim Waugh <twaugh redhat com>

## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
## the Free Software Foundation; either version 2 of the License, or
## (at your option) any later version.

## This program is distributed in the hope that it will be useful,
## but WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
## GNU General Public License for more details.

## You should have received a copy of the GNU General Public License
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

if [ $# == 0 ]; then
  echo >&2 "ERROR: $0 job-id user title copies options [file]"
  exit 1
fi

# Extract the papersize
SENDFF=`grep '^\*DefaultSendFF' "$PPD" | cut -d\  -f2`
COPIES=1
if [ $# -ge 4 ]; then
  COPIES="$4"
fi

if [ "$COPIES" -gt 1 ] && [ $# -lt 6 ]; then
  unset TMPFILE
  trap -- 'rm -f "$TMPFILE"' EXIT
  TMPFILE=$(mktemp ${TMPDIR:-/tmp}/textonly.XXXXXX)
  cat > "$TMPFILE"
else
  TMPFILE="$6"
fi

while [ "$COPIES" -gt 0 ]; do
  # Just translate LF->CRLF at the moment, until the PPD has options added.
  sed -e 's/$/'`echo -ne '\r'`'/g' "$TMPFILE"

  if [ "$SENDFF" == "True" ]
    then
    echo -ne \\14
  fi

  COPIES=$(($COPIES - 1))
done


--- NEW FILE textonly.ppd ---
*PPD-Adobe: "4.3"
*%
*% Text-only printer definition
*%
*FormatVersion:	"4.3"
*FileVersion:	"1.1"
*LanguageVersion: English
*LanguageEncoding: ISOLatin1
*PCFileName:	"TEXTONLY.PPD"
*Manufacturer:	"Generic"
*Product:	"(Generic)"
*cupsVersion:   1.0
*cupsManualCopies: True
*cupsModelNumber:  2
*cupsFilter:    "text/plain 0 textonly"
*ModelName:     "Generic text-only printer"
*ShortNickName: "Generic text-only printer"
*NickName:      "Generic text-only printer"
*PSVersion:	"(2017.000) 0"
*LanguageLevel:	"2"
*ColorDevice:	False
*DefaultColorSpace: Gray
*FileSystem:	False
*Throughput:	"8"
*LandscapeOrientation: Plus90
*VariablePaperSize: False
*TTRasterizer:	Type42
*DefaultImageableArea: Letter
*ImageableArea Letter/US Letter:	"18 36 594 756"
*DefaultPaperDimension: Letter
*PaperDimension Letter/Letter:		"612 792"
*OpenUI *PageSize/Media Size: PickOne
*OrderDependency: 10 AnySetup *PageSize
*DefaultPageSize: Letter
*PageSize Letter/Letter:	"<</PageSize[612 792]/ImagingBBox null>>setpagedevice"
*CloseUI: *PageSize
*OpenUI *PageRegion: PickOne
*OrderDependency: 10 AnySetup *PageRegion
*DefaultPageRegion: Letter
*PageRegion Letter/Letter:	"<</PageSize[612 792]/ImagingBBox null>>setpagedevice"
*CloseUI: *PageRegion

*OpenUI *SendFF: Boolean
*DefaultSendFF: False
*SendFF True/True:        ""
*SendFF False/False:   ""
*CloseUI: *SendFF


Index: cups.spec
===================================================================
RCS file: /cvs/dist/rpms/cups/devel/cups.spec,v
retrieving revision 1.280
retrieving revision 1.281
diff -u -r1.280 -r1.281
--- cups.spec	30 Oct 2006 16:50:17 -0000	1.280
+++ cups.spec	31 Oct 2006 13:37:46 -0000	1.281
@@ -22,6 +22,8 @@
 Source11: cups.conf
 Source12: cups.cron
 Source13: pdftops.conf
+Source14: textonly.filter
+Source15: textonly.ppd
 Patch1: cups-1.1.15-initscript.patch
 Patch2: cups-no-gzip-man.patch
 Patch3: cups-1.1.16-system-auth.patch
@@ -206,6 +208,8 @@
 install -c -m 755 %{SOURCE10} $RPM_BUILD_ROOT%{cups_serverbin}/backend/ncp
 install -c -m 755 %{SOURCE12} $RPM_BUILD_ROOT%{_sysconfdir}/cron.daily/cups
 install -c -m 644 %{SOURCE13} $RPM_BUILD_ROOT%{_sysconfdir}/cups/pdftops.conf
+install -c -m 755 %{SOURCE14} $RPM_BUILD_ROOT%{cups_serverbin}/filter/textonly
+install -c -m 644 %{SOURCE15} $RPM_BUILD_ROOT%{_datadir}/cups/model/textonly.ppd
 ln -s ../doc/%{name}-%{version} $RPM_BUILD_ROOT%{_datadir}/%{name}/doc
 
 # Ship pstopdf for LSPP systems to deal with malicious postscript
@@ -420,6 +424,9 @@
 %{cups_serverbin}/daemon/cups-lpd
 
 %changelog
+* Tue Oct 31 2006 Tim Waugh <twaugh redhat com>
+- Added filter and PPD for text-only printer (bug #213030).
+
 * Mon Oct 30 2006 Tim Waugh <twaugh redhat com> 1:1.2.5-4
 - Fixed support for /dev/ttyUSB devices (bug #212577, STR #2061).
 - Fixed parallel backend (bug #213021, STR #2056).


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]