I already know about Ghostscript front end viewers; but I was wondering how gs
itself could be used for viewing PDF documents?
The closest I could get to, is to specify explicitly x11
window as output device, specify width and height of the window via -g
, and specify rasterization resolution via -r
; or, a command line like this:
gs -sDevice=x11 -g500x500 -r150x150 -dFirstPage=3 fontspec.pdf
... which results with something like:
... which is, in fact, all good - except, it starts at lower left corner; and there are no keyboard shortcuts (as far as I can see) here to move the viewport, or to perform some zooming.
I'm aware that ghostscipt
probably doesn't have mouse/keyboard interaction for navigating a x11 window output, given that something like that is reserved for front-end viewers like gv
. So, the closest thing to that (for me) in ghostscript would be - how to render a specific region of a page? Via -d
and -r
the most important parameters are already specified - I'd just want to, say, specify a different point than 0x0 (say, x=100 y=100) as a lower left corner when viewing.
(In other words, I'd like to say to ghostscript
: show page 3 of document.pdf, rasterized at 150x150, in a window of 500x500, starting from lower-left corner x,y=100,100).
How can this be done in ghostscript
? Are there command line switches for that - or would one have to use postscript
language commands in terminal, once ghostscript
has loaded?
Many thanks in advance for any answers,
Cheers!