Class PrintViewer
- java.lang.Object
-
- org.eclipse.nebula.paperclips.widgets.PrintViewer
-
public class PrintViewer extends java.lang.Object
A JFace-stylePrint
viewer which displays a Print in a scrollable pane.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private class
PrintViewer.BackgroundUpdater
-
Field Summary
Fields Modifier and Type Field Description private PrintViewer.BackgroundUpdater
backgroundUpdater
private PrintPieceCanvas
canvas
private int
canvasWidth
private Print
print
private org.eclipse.swt.custom.ScrolledComposite
sc
-
Constructor Summary
Constructors Constructor Description PrintViewer(org.eclipse.swt.widgets.Composite parent, int style)
Constructs a PrintPreview with the given parent and style.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.eclipse.swt.widgets.Control
getControl()
Returns the viewer component wrapped by this PrintPreview.Print
getPrint()
Returns the Print being displayed.void
setPrint(Print print)
Sets the Print to be displayed.private void
setPrintPiece(PrintPiece piece, boolean updateMinHeight)
(package private) void
updateCanvas()
-
-
-
Field Detail
-
sc
private final org.eclipse.swt.custom.ScrolledComposite sc
-
canvas
private final PrintPieceCanvas canvas
-
print
private Print print
-
canvasWidth
private int canvasWidth
-
backgroundUpdater
private PrintViewer.BackgroundUpdater backgroundUpdater
-
-
Method Detail
-
getControl
public org.eclipse.swt.widgets.Control getControl()
Returns the viewer component wrapped by this PrintPreview.- Returns:
- the viewer component wrapped by this PrintPreview.
-
setPrint
public void setPrint(Print print)
Sets the Print to be displayed.- Parameters:
print
- the Print to display.
-
getPrint
public Print getPrint()
Returns the Print being displayed.- Returns:
- the Print being displayed.
-
updateCanvas
void updateCanvas()
-
setPrintPiece
private void setPrintPiece(PrintPiece piece, boolean updateMinHeight)
-
-