com.aspose.words
Class AsposeWordsPrintDocument

java.lang.Object
    extended by com.aspose.words.AsposeWordsPrintDocument
All Implemented Interfaces:
java.awt.print.Pageable, java.awt.print.Printable

public class AsposeWordsPrintDocument 
extends java.lang.Object

Provides a default implementation for printing of a Document within the Java printing framework.

To learn more, visit the Printing a Document Programmatically or Using Dialogs documentation article.

AsposeWordsPrintDocument overrides both java.awt.print.Printable and java.awt.print.Pageable.

A single Aspose.Words document can consist of multiple sections that specify pages with different sizes, orientation and paper trays. AsposeWordsPrintDocument should be used as java.awt.print.Pageable to properly print each of the different paper size, orientation, etc.

On the other hand, if the document consists of a single section only, the developer can use AsposeWordsPrintDocument as java.awt.print.Printable to improve printing performance.


Constructor Summary
AsposeWordsPrintDocument(Document document)
           Initializes a new instance of this class.
 
Property Getters/Setters Summary
intgetColorMode()
voidsetColorMode(int value)
           Gets or sets how non-colored pages are printed if the device supports color printing. The value of the property is ColorPrintMode integer constant.
intgetColorPagesPrinted()
           Gets the number of pages printed in color (i.e. with Color set to true).
 

Constructor Detail

AsposeWordsPrintDocument

public AsposeWordsPrintDocument(Document document)
Initializes a new instance of this class.
Parameters:
document - The document to print.

Property Getters/Setters Detail

getColorMode/setColorMode

public int getColorMode() / public void setColorMode(int value)
Gets or sets how non-colored pages are printed if the device supports color printing. The value of the property is ColorPrintMode integer constant. Doesn't affect booklet printing.

getColorPagesPrinted

public int getColorPagesPrinted()
Gets the number of pages printed in color (i.e. with Color set to true).

See Also:
          Aspose.Words Documentation - the home page for the Aspose.Words Product Documentation.
          Aspose.Words Support Forum - our preferred method of support.