nsIPrintSettings
| IID: | 3e097aba-c1d6-425d-9c52-b371d5da964a |
| Inherits From: | nsISupports |
| Status: | UNDER_REVIEW |
Simplified graphics interface for JS rendering.
Constants
Properties
PRUnichar* colorspace
PRUnichar* docURL
PRBool downloadFonts
double edgeBottom
double edgeLeft
double edgeRight
double edgeTop
The edge defines the area at the border of the paper outside of which the printer cannot print. The headers and footers will be placed inside.
PRInt32 endPageRange
PRUnichar* footerStrCenter
PRUnichar* footerStrLeft
PRUnichar* footerStrRight
PRUnichar* headerStrCenter
PRUnichar* headerStrLeft
PRUnichar* headerStrRight
PRInt16 howToEnableFrameUI
PRBool isCancelled
PRBool isInitializedFromPrefs
This attribute tracks whether the PS has been initialized from prefs. If a different name is set into the "printerName" attribute than the one it was initialized with the PS will then get intialized from prefs again.
PRBool isInitializedFromPrinter
This attribute tracks whether the PS has been initialized from a printer specified by the "printerName" attr. If a different name is set into the "printerName" attribute than the one it was initialized with the PS will then get intialized from that printer.
double marginBottom
double marginLeft
double marginRight
double marginTop
The margins define the area of the paper to print the content to. The headers and footers are placed outside, but still inside the border defined by the edge attributes above.
PRInt32 numCopies
PRInt32 orientation
PRInt16 outputFormat
PRInt16 paperData
double paperHeight
PRUnichar* paperName
PRInt16 paperSizeType
PRInt16 paperSizeUnit
double paperWidth
PRUnichar* plexName
PRBool printBGColors
PRBool printBGImages
PRUnichar* printCommand
PRUnichar* printerName
PRInt16 printFrameType
PRInt16 printFrameTypeUsage
PRBool printInColor
PRInt32 printPageDelay
PRInt16 printRange
PRBool printReversed
nsIPrintSession printSession
Data Members
PRBool printSilent
PRBool printToFile
PRUnichar* resolutionName
double scaling
PRBool showPrintProgress
PRBool shrinkToFit
PRInt32 startPageRange
PRUnichar* title
PRUnichar* toFileName
Methods
void assign ( nsIPrintSettings PS )
nsIPrintSettings clone ( )
[noscript] void GetEdgeInTwips ( nsNativeMarginRef edge )
void GetEffectivePageSize ( out double width , out double height )
[noscript] void GetMarginInTwips ( nsNativeMarginRef margin )
PRBool GetPrintOptions ( PRInt32 type )
PRInt32 GetPrintOptionsBits ( )
[noscript] void SetEdgeInTwips ( nsNativeMarginRef edge )
[noscript] void SetMarginInTwips ( nsNativeMarginRef margin )
void SetPrintOptions ( PRInt32 type , PRBool turnOnOff )
[noscript] void SetupSilentPrinting ( )
void assign ( nsIPrintSettings PS )
Assigns the internal values from the "in" arg to the current object
- Arguments:
- PS
void GetEffectivePageSize ( out double width , out double height )
Get the page size in twips, considering the orientation (portrait or landscape).
- Arguments:
- width
- height
We call this function so that anything that requires a run of the event loop can do so safely. The print dialog runs the event loop but in silent printing that doesn't happen.
Either this or ShowPrintDialog (but not both) MUST be called by the print engine before printing, otherwise printing can fail on some platforms.
References
This interface is the type of the following properties:
nsIPrintSettingsService.globalPrintSettings, nsIPrintSettingsService.newPrintSettings, nsIWebBrowserPrint.currentPrintSettings, nsIWebBrowserPrint.globalPrintSettings
This interface is passed as an argument to the following methods:
nsIContentViewer.setPageMode, nsIContentViewerFile.print, nsIContentViewerFile.printWithParent, nsIMsgPrintEngine.startPrintOperation, nsIPrintOptions.ShowPrintSetupDialog, nsIPrintOptions.displayJobProperties, nsIPrintOptions.getPrinterPrefInt, nsIPrintSettings.assign, nsIPrintSettingsService.initPrintSettingsFromPrefs, nsIPrintSettingsService.initPrintSettingsFromPrinter, nsIPrintSettingsService.savePrintSettingsToPrefs, nsIPrinterEnumerator.displayPropertiesDlg, nsIPrinterEnumerator.initPrintSettingsFromPrinter, nsIPrintingPrompt.showPageSetup, nsIPrintingPrompt.showPrintDialog, nsIPrintingPrompt.showPrinterProperties, nsIPrintingPrompt.showProgress, nsIPrintingPromptService.showPageSetup, nsIPrintingPromptService.showPrintDialog, nsIPrintingPromptService.showPrinterProperties, nsIPrintingPromptService.showProgress, nsIWebBrowserPrint.print, nsIWebBrowserPrint.printPreview
This interface is returned from the following methods:
nsIPrintOptions.CreatePrintSettings, nsIPrintSettings.clone
Reference documentation is generated from Mozilla's source.
