Heron

Table Of Contents

Previous topic

Heron.widgets.OpenLSSearchCombo

Next topic

Heron.widgets.ScaleSelectorCombo

Heron.widgets.PrintPreviewWindow

Extends
xtype
hr_printpreviewwindow
class Heron.widgets.PrintPreviewWindow(config)

An ExtJS Window that contains a GeoExt.ux PrintPreview Container. PrintPreview is synced from https://github.com/GeoNode/PrintPreview.

he Window can be opened through the Toolbar (see example) or directly.

 // Via Toolbar printer icon.
{type: "printdialog",
 options: {url: 'http://kademo.nl/print/pdf28992'}
}

// Create PrintPreviewWindow directly.
var printWindow = new Heron.widgets.PrintPreviewWindow({
              title: 'My Title',
              modal: true,
              border: false,
              resizable: false,
              width: 360,
              autoHeight: true,

              hropts: {
                      mapTitle: 'My Map Title',
                      comment: 'My Comment text',
                      method: 'POST',
                      includeLegend: true,
                      legendDefaults:{
                              useScaleParameter : false,
                              baseParams: {FORMAT: "image/png"}
                      },
                              url: 'http://kademo.nl/print/pdf28992',
                      mapPanel: mapPanel
              }
      });

Events

Events in addition to those listed for Ext.Window.

printexception

Triggered when using the POST method, when the print backend returns an exception.

Listener arguments:

  • printProvider - GeoExt.data.PrintProvider this

rintProvider * response - Object the response object of the XHR