ghostscript

Converting PDF to CMYK (with identify recognizing CMYK)

风流意气都作罢 提交于 2019-11-28 02:57:59
I am having much trouble to get ImageMagick's identify to, well, identify a PDF as CMYK. Essentially, let's say I'm building this file, test.tex , with pdflatex : \documentclass[a4paper,12pt]{article} %% https://tex.stackexchange.com/questions/13071 \pdfcompresslevel=0 %% http://compgroups.net/comp.text.tex/Making-a-cmyk-PDF %% ln -s /usr/share/color/icc/sRGB.icm . % \immediate\pdfobj stream attr{/N 4} file{sRGB.icm} % \pdfcatalog{% % /OutputIntents [ << % /Type /OutputIntent % /S/GTS_PDFA1 % /DestOutputProfile \the\pdflastobj\space 0 R % /OutputConditionIdentifier (sRGB IEC61966-2.1) % /Info

Ghostscript for PDF: how to fit 4 pages into 1?

对着背影说爱祢 提交于 2019-11-28 02:08:25
I need to use ghostscript for concatenating several PDFs into a single pdf file. The help I need from you is what command do I have to use, in order to edit the output page, so that it fits 4 pages of the input files, into 1 of the output. What I am using so far is this command: gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite \ -sOutputFile=ALL.pdf plot_1.pdf plot_n.pdf Input files are A4 landscape, and the output have to be the same format. Thanks to all, Cristian This is a program I wrote some time back to do 2-up imposition from PDF. This is not a general purpose PostScript program, it will only

How can I add a footer to the bottom of each page of a postscript or pdf file in linux?

偶尔善良 提交于 2019-11-28 00:54:05
问题 So I'd like to add a "footer" (an attribution) to the bottom of every page of a pdf file I am generating via postscript with groff in linux. I am converting the file from ps to pdf myself, with the ps2pdf tool, so I have access to both formats. These two posts have been somewhat helpful: How to add page numbers to Postscript/PDF How can I make a program overlay text on a postscript file? I'm not against using the first method, but I don't have access to the pdflatex utility mentioned in the

Is it possible in Ghostscript to add watermark to every page in PDF

房东的猫 提交于 2019-11-28 00:01:50
I convert PDF -> many JPEG and many JPEG -> many PDF using ghostscript . I need to add watermark text on every converted JPEG (PDF) page. Is it possible using only Ghostscript and PostScript? The only way I found: gswin32c -q -sDEVICE=pdfwrite -dBATCH -dNOPAUSE -sOutputFile=output.pdf watermark.ps input.pdf But this will insert watermark.ps watermark on first separate page in output.pdf . Can I do this on output PDF pages directly? Can I do this on output JPEG pages directly? << /BeginPage { gsave /Helvetica_Bold 120 selectfont .85 setgray 130 70 moveto 50 rotate (Sample) show grestore } bind

ghostscript: convert PDF into CMYK preserving pure Black for text

有些话、适合烂在心里 提交于 2019-11-27 23:18:23
I need to convert RGB PDF into CMYK PDF. I need to have pure black color for texts. It seems (thanks to comments below) term "black point compensation" is wrong. I took it from Adobe Acrobat where it works exactly how i need. I thought gs has same feature. I use ghostscript 9.16 If i got it right there is -dBlackPtComp option, but it does not work for me. Ghostscript command I have tried is: "c:/Program Files/gs/gs9.16/bin/GSWIN64C.EXE" -o testing_black_cmyk.pdf -sColorConversionStrategy=CMYK -sDEVICE=pdfwrite -dOverrideICC=true -sOutputICCProfile=c:/Windows/System32/spool/drivers/color

How to determine string height in PostScript?

寵の児 提交于 2019-11-27 22:14:00
问题 I need to determine the height of a string (in given scale and font) in postscript. /Helvetic-Oblique findfont 10 scalefont setfont 10 10 1 0 360 arc fill 10 10 moveto (test) dup stringwidth pop 2 div neg 0 rmoveto show will print test centered horizontally (but not yet vertically) at (10,10). (to see this, I also show a small circle at 10,10). I also need to determine the string height to center the text vertically as well, but I cant find a function for it. 回答1: Are you familiar with the

How do I embed fonts in an existing PDF?

此生再无相见时 提交于 2019-11-27 20:27:54
Background: I have PDF's I am programmatically generating. I need to be able to send the PDF directly to a printer from the server (not through an intermediate application). At the moment I can do all of the above (generate PDF, send to printer), but because the fonts aren't embedded in the PDF the printer is doing font substitution. Why the fonts aren't embedded when generated: I am creating PDF's using SQL Reporting Services 2008. There is a known issue with SQL Reporting Services in that it will not embed fonts (unless a series of requirements are met - http://technet.microsoft.com/en-us

Script (or some other means) to convert RGB to CMYK in PDF?

情到浓时终转凉″ 提交于 2019-11-27 18:37:52
Is it possible to write a script for Adobe Illustrator or some other tool that will read the contents of a number of PDF files and convert all the RGB colours to CMYK? If so, could somebody please point out some of the steps involved, or where to find more information on this? This answer is not for Illustrator, but for 'some other tool' , namely Ghostscript (download gs871w32.exe or gs871w64.exe ). Ghostscript allows you to 're-distill' PDFs ( without an intermediate conversion to PostScript, the dreaded 'refrying' detour). Try this command: gswin32c.exe ^ -o c:/path/to/output-cmyk.pdf ^

Optimize PDF files (with Ghostscript or other)

巧了我就是萌 提交于 2019-11-27 16:48:06
Is Ghostscript the best option if you want to optimize a PDF file and reduce the file size? I need to store alot of PDF files and therefore I need to optimize and reduce the file size as much as possible Does anyone have any experience with Ghostscript and/or other? command line exec('gs -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -sOutputFile='.$file_new.' '.$file); Kurt Pfeifle If you looking for a Free (as in 'libre') Software, Ghostscript is surely your best choice. However, it is not always easy to use -- some of its (very powerful) processing

How can I merge PDF files (or PS if not possible) such that every file will begin in a odd page?

余生长醉 提交于 2019-11-27 14:52:10
问题 I am working on a UNIX system and I'd like to merge thousands of PDF files into one file in order to print it. I don't know how many pages they are in advance. I'd like to print it double sided, such that two files will not be on the same page. Therefore it I'd the merging file to be aligned such that every file will begin in odd page and a blank page will be added if the next place to write is an even page. 回答1: Here's the solution I use (it's based on @Dingo's basic principle, but uses an