| Home | Research | Requirements | Architecture | Design | [Modules] | Reference | [Team] | GeoConnections Project Schedule |
|---|
The perspective of printing is all about data flow. Things that were easy for rendering (like WMS requests) become difficult as we lose the safety of a target raster.
Use Cases
- User hits "print"
- User selects Print
- User selects [Printer] and [PageLayout]
- System obtains a PrintContext - a modified version of Context that is optimized for the printing side
- System obtains a net.refractions.udig.printing.template
- Calls the net.refractions.udig.printing
- net.refractions.udig.printing obtains a Graphics2D object from
- net.refractions.udig.printing passes the Graphics2D object to rending system
- Rendering system returns a finished Graphics2D object
- Paper comes out of printer
- User defines a layout with things like legend, north arrow, title and scale
- User prints to PDF
- User selects information to be highlighted in their report
- User prints a map book based on a single layout multiple bbox
- User saves their context+layout to disk for later reuse
- User loads a context+layout
Modules
- net.refractions.udig.project.context
- net.refractions.udig.printing.context
- net.refractions.udig.render.features
- net.refractions.udig.catalog.grid
- net.refractions.udig.render.decorator - north arrow, scale, legend, title
- net.refractions.udig.printing.wizard - walks through the process of setting up a Page
- net.refractions.udig.printing.page - persistence (saves context, decorators & printing selection?)
- net.refractions.udig.printing.template - maintains the look of a Page
- net.refractions.udig.printing - Prints a Page
Diagram

Design Notes
The printing pipeline is similar in execution to the rendering pipeline. Several key differences have appeared:
- additional decorators such as a scalebar, compass, and legend
- need to completely render presents a different spin than the "continual update" required for screen
- connect renderer directly with a Graphics2D object provided by a Printer/PDF
General idea is to call each renderer:
- in reverse order
- for selection in reverse order
- for each decoration (legend, title, etc...)
We may have issues with "draw through" that we do not on screen, and PDF file size (depending on the amount of linework saved).
Context will be extended with additional "layers" for page decorators