Class: Poppler::PSFile

Inherits:
Object
  • Object
show all
Defined in:
(unknown)

Instance Method Summary collapse

Constructor Details

#initialize(document, fd, first_page, n_pages) ⇒ Poppler::PSFile

Create a new postscript file to render to. Note that this function takes ownership of fd; you must not operate on it again, nor close it.

Parameters:

  • document (Poppler::Document)

    a Poppler::Document

  • fd (Integer)

    a valid file descriptor open for writing

  • first_page (Integer)

    the first page to print

  • n_pages (Integer)

    the number of pages to print

Instance Method Details

#duplex=(duplex) ⇒ nil

Enable or disable Duplex printing.

Parameters:

  • duplex (Boolean)

    whether to force duplex printing (on printers which support this)

Returns:

  • (nil)

#freenil

Frees ps_file

Returns:

  • (nil)

#set_paper_size(width, height) ⇒ nil

Set the output paper size. These values will end up in the DocumentMedia, the BoundingBox DSC comments and other places in the generated PostScript.

Parameters:

  • width (Float)

    the paper width in 1/72 inch

  • height (Float)

    the paper height in 1/72 inch

Returns:

  • (nil)