StyledText.Printing

The Printing class : printing of a range of text. An instance of <code>Printing</code> is returned in the StyledText#print(Printer) API. The run() method may be invoked from any thread.

Constructors

this
this(StyledText styledText, Printer printer, StyledTextPrintOptions printOptions)

Creates an instance of <code>Printing</code>. Copies the widget content and rendering data that needs to be requested from listeners. </p> @param parent StyledText widget to print. @param printer printer device to print on. @param printOptions print options

Members

Functions

cacheLineData
void cacheLineData(StyledText styledText)

Caches all line data that needs to be requested from a listener. </p> @param printerContent <code>StyledTextContent</code> to request line data for.

copyContent
StyledTextContent copyContent(StyledTextContent original)

Copies the text of the specified <code>StyledTextContent</code>. </p> @param original the <code>StyledTextContent</code> to copy.

dispose
void dispose()

Disposes of the resources and the <code>PrintRenderer</code>.

init_
void init_()
Undocumented in source. Be warned that the author may not have intended to support it.
print
void print()

Prints the lines in the specified page range.

printDecoration
void printDecoration(int page, bool header, TextLayout layout)

Print header or footer decorations.

printDecorationSegment
void printDecorationSegment(String segment, int alignment, int page, bool header, TextLayout layout)

Print one segment of a header or footer decoration. Headers and footers have three different segments. One each for left aligned, centered, and right aligned text.

printLine
void printLine(int x, int y, GC gc, Color foreground, Color background, TextLayout layout, TextLayout printLayout, int index)
Undocumented in source. Be warned that the author may not have intended to support it.
run
void run()

Starts a print job and prints the pages specified in the constructor.

Static variables

CENTER
int CENTER;
Undocumented in source.
LEFT
int LEFT;
Undocumented in source.
RIGHT
int RIGHT;
Undocumented in source.

Variables

clientArea
Rectangle clientArea;
Undocumented in source.
endLine
int endLine;
Undocumented in source.
endPage
int endPage;
Undocumented in source.
fontData
FontData fontData;
Undocumented in source.
gc
GC gc;
Undocumented in source.
lineSpacing
int lineSpacing;
Undocumented in source.
mirrored
bool mirrored;
Undocumented in source.
pageWidth
int pageWidth;
Undocumented in source.
printMargin
int printMargin;
Undocumented in source.
printOptions
StyledTextPrintOptions printOptions;
Undocumented in source.
printer
Printer printer;
Undocumented in source.
printerFont
Font printerFont;
Undocumented in source.
printerRenderer
StyledTextRenderer printerRenderer;
Undocumented in source.
resources
Resource[Resource] resources;
Undocumented in source.
selection
Point selection;
Undocumented in source.
singleLine
bool singleLine;
Undocumented in source.
startLine
int startLine;
Undocumented in source.
startPage
int startPage;
Undocumented in source.
tabLength
int tabLength;
Undocumented in source.

Meta