Languages
PostScript
Installing PostScript tools on Ubuntu in TIDE
PostScript
PostScript is a stack-based page description language and programming language used extensively in desktop publishing, graphics processing, and printing.
Installation
On Ubuntu, PostScript files can be rendered, interpreted, and processed using Ghostscript (gs).
Run the following command in TIDE's terminal:
sudo apt update
sudo apt install -y ghostscriptVerification
Check the Ghostscript version:
gs --versionWriting and Running Code
Create a file named hello.ps:
%!PS
(Hello, World from PostScript!\n) print
quitRun the PostScript program using Ghostscript in batch quiet mode:
gs -q -ND -dBATCH hello.psVisual Output Example
If you are rendering graphical text into a PNG or PDF file:
%!PS
/Helvetica findfont 24 scalefont setfont
100 500 moveto
(Hello, World from PostScript!) show
showpageConvert it to a PNG image:
gs -sDEVICE=png16m -o output.png hello_page.ps