Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

NPFullPrint

« Gecko Plugin API Reference « Plug-in Side Plug-in API

Summary

Substructure of NPPrint that contains platform-specific information used during full-page mode printing.

Syntax

typedef struct _NPFullPrint
{
    NPBool pluginPrinted; /* true: print fullscreen */
    NPBool printOne;      /* true: print one copy */
                          /*       to default printer */
    void*  platformPrint; /* Platform-specific */
} NPFullPrint;

Fields

The data structure has the following fields:

pluginPrinted
Determines whether the plug-in prints in full-page mode. Values:
  • true: Plug-in takes complete control of the printing process and prints full-page.
  • false: (Default) Plug-in renders its area of the page only (for embedded plug-in).
printOne
Not currently in use. Should always be false.
  • true: Print single copy of page to the default printer.
  • false: Display print dialogs so user can choose printer, other options.
platformPrint
Platform-specific printing information.
  • Mac OS: THPrint
  • MS Windows: Printer's device context

Description

The NPP_Print function passes the plug-in a pointer to an NPPrint object (previously allocated by the browser). The NPFullPrint structure is used when the mode field of NPPrint is set to NP_Full.

The pluginPrinted field of this structure determines whether the plug-in prints in full-page mode or not. If you want the plug-in to take complete control of the printing process, it should print the full page and set the field pluginPrinted to true before returning.

If you want an embedded plug-in to simply render its area of the page, set pluginPrinted to false and return immediately; the browser calls NPP_Print again with the NPEmbedPrint substructure of NPPrint.

See Also

NPP_Print, NPPrint, NPEmbedPrint

Document Tags and Contributors

Tags: 
 Contributors to this page: teoli, Pmash
 Last updated by: Pmash,