Dear Richard,
It IS possible to put Ghostscript in the directory of YOUR choice and
still have it find its fonts. But it IS obscure!!
Maybe these batch files that I use will help you. There are
three - one each for screen and printer and one that will
give you the choice and select page numbers:
GS.BAT runs Ghostscript to display on the screen. Press RETURN after
each screenful to get the next. You won't get a text prompt
overwriting the display.
=== GS.BAT =======================
@echo off
c:
cd c:\graphics\gs
set GS_OPTIONS=-q -Ifonts -dNOPROMPT
call c:\graphics\gs\gs386 %1 -dBATCH
set GS_OPTIONS=
cls
==================================
GSPRINT.BAT sends it to a laser printer without needing you to
press RETURN after it sends each page.
=== GSPRINT.BAT ==================
@echo off
c:
cd c:\graphics\gs
set GS_DEVICE=ljet4
set GS_OPTIONS=-q -Ifonts -dFIXEDMEDIA -dNOPAUSE
call gs386 -r300 -sPAPERSIZE=a4 %1 -dBATCH
set GS_DEVICE=
set GS_OPTIONS=
pause
cls
==================================
SHOWPDF.BAT is a combination of the previous two. In addition, it
allows you to state start and end page numbers of the document.
It requires you to have CHOICE somewhere on your path. I think
that this came with MS-DOS 6.22, although I use it with
MS-DOS 5.00.
=== SHOWPDF.BAT ==================
@echo off
rem Ghostscript starter 1/2/2000
rem New, improved version.
rem Uses %TEMP%, so make sure it's big enough!
rem
cls
if "%2"=="" goto ERROR
if not "%3"=="" goto START
rem
rem Issue a message if starting and ending pages not
rem specified on command line.
rem
:ERROR
echo.
echo.
echo Invoke %0 thus:
echo %0 [filename.ext] [start page] [endpage]
echo.
pause
goto END
rem
rem Start by copying file to temporary directory.
rem
:START
copy %1 %TEMP% >nul
echo.
echo GhostScript control....
:CHOOSE
echo Processing %1,
echo Starting at page %2,
echo Ending at page %3.
choice /C:DPQ Display or Print file, or Quit
if not errorlevel 3 goto PRINTIT
del %TEMP%\%1
goto END
rem
rem Send file to printer.
rem
:PRINTIT
if not errorlevel 2 goto VIEWIT
c:
cd c:\graphics\gs
set GS_DEVICE=ljet4
set GS_OPTIONS=-q -Ifonts -dFIXEDMEDIA -dNOPAUSE
call gs386 -r300 -sPAPERSIZE=a4 -dFirstPage=%2 -dLastPage=%3 %TEMP%\%1 -dBATCH
set GS_DEVICE=
set GS_OPTIONS=
pause
cls
goto CHOOSE
rem
rem Send file to screen.
rem
:VIEWIT
c:
cd c:\graphics\gs
set GS_OPTIONS=-q -Ifonts -dNOPROMPT
call c:\graphics\gs\gs386 -dFirstPage=%2 -dLastPage=%3 %TEMP%\%1 -dBATCH
set GS_OPTIONS=
pause
cls
goto CHOOSE
:END
==================================
Hope that you can make some use of these!
All the best,
Ron.
=============================================================
On Sun, 13 Feb 2000 03:23:34 +0100, Richard Menedetter wrote:
> Although GhostScript is rather strange ...
> Searchpath for the fonts is hardcoded either to . or to c:\gs\fonts
> If ps files are viewed with it directly the font is so small, that I can't
> read it ... and there's a text saying press enter which overwrites some of
> the rendered ps file ...
> Maybe somebody can help ...
> PS: If you don't want to install it into c:\gs
> you have to move everything from gs/fonts to gs.
> (and you have to edit ps2ascii so that it enters the gs dir, because the
> search path is only . or c:/gs . I did it with the 4dos commands
> pushd/popd)