                    Open Page

The "Open Page ..." menu item is used to open
and display individual pages from a PostScript
file.  After the menu is clicked, the file
selector is presented and the selected file is
scanned to determine how many pages it
contains.

It is impossible to determine the number of
pages from the PostScript code itself, but
properly structured PS programs contain
comments noting the page boundaries.  If these
comments are missing, Atari GS will display an
error dialog, and then open the selected file
as if "Open File ..." had been used.

If the number of pages can be successfully
determined, Atari GS will open a window
containing a button for each page, and then
execute a prolog which defines procedures used
by all pages.

From this point, individual pages may be
viewed by clicking on the button corresponding
to the desired page.  The selected page will
be copied into a file named gs_pg?.ps (?  is
the page number) and then executed.  These
scratch files will be removed when GS exits.

The "Next Page" and "Prev Page" menu items may
also be used to navigate through individual
pages.  Note that the page numbers in the
buttons are absolute, and may not correspond
to the actual page numbering of the document.
