Class PrintGraphicalViewerOperation

java.lang.Object
org.eclipse.draw2d.PrintOperation
org.eclipse.draw2d.PrintFigureOperation
org.eclipse.gef.print.PrintGraphicalViewerOperation

public class PrintGraphicalViewerOperation extends org.eclipse.draw2d.PrintFigureOperation
  • Field Summary

    Fields inherited from class org.eclipse.draw2d.PrintFigureOperation

    FIT_HEIGHT, FIT_PAGE, FIT_WIDTH, TILE
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor for PrintGraphicalViewerOperation
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the viewer.
    protected void
     
    protected void
     
    void
    Sets the viewer.

    Methods inherited from class org.eclipse.draw2d.PrintFigureOperation

    getPrintMode, getPrintSource, printPages, setPrintMode, setPrintSource, setupPrinterGraphicsFor

    Methods inherited from class org.eclipse.draw2d.PrintOperation

    cleanup, createGraphics, getFreshGraphics, getFreshPrinterGraphics, getPrinter, getPrintRegion, run, setPrinter, setPrintMargin, setupGraphicsForPage, setupGraphicsForPage

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PrintGraphicalViewerOperation

      public PrintGraphicalViewerOperation(Printer p, GraphicalViewer g)
      Constructor for PrintGraphicalViewerOperation
      Parameters:
      p - The Printer to print to
      g - The viewer containing what is to be printed NOTE: The GraphicalViewer to be printed must have a Layer with the PRINTABLE_LAYERS key.
  • Method Details

    • getViewer

      public GraphicalViewer getViewer()
      Returns the viewer.
      Returns:
      GraphicalViewer
    • preparePrintSource

      protected void preparePrintSource()
      Overrides:
      preparePrintSource in class org.eclipse.draw2d.PrintFigureOperation
      See Also:
      • PrintOperation.preparePrintSource()
    • restorePrintSource

      protected void restorePrintSource()
      Overrides:
      restorePrintSource in class org.eclipse.draw2d.PrintFigureOperation
      See Also:
      • PrintOperation.restorePrintSource()
    • setViewer

      public void setViewer(GraphicalViewer viewer)
      Sets the viewer.
      Parameters:
      viewer - The viewer to set