Table Of Contents

Previous topic

GeoAdmin.PermalinkWindow

Next topic

OpenLayers.Control.Swipe

This Page

GeoAdmin.Print

Extends
xtype
ga_print
class GeoAdmin.Print(config)
param config:Object config
return:GeoAdmin.Print

Create a print action

Example Use

Sample code to create a print (see also Print):

map = new GeoAdmin.Map();
mapPanel = new GeoAdmin.MapPanel({
    region: 'center',
    map: map
});

new Ext.Panel({
    renderTo: "map",
    layout: "border",
    height: 400,
    width: 600,
    items: [
        mapPanel
    ],
    bbar: [
        new GeoAdmin.Print({
            text: OpenLayers.i18n('print map (popup)'),
            printPanelOptions: {
                mapPanel: mapPanel
            },
            windowOptions: {
                title: OpenLayers.i18n('print map')
            }
        }),
        new GeoAdmin.Print({
            printBaseUrl: '/print',
            text: OpenLayers.i18n('print map (panel)'),
            printPanelOptions: {
                renderTo: 'print',
                mapPanel: mapPanel
            }
        })
    ]
});

Public Properties

Public properties in addition to those listed for Ext.Action.

Print.configureFooter

boolean indicates if a footer is shown in the print form

Print.configureLegend

boolean indicates if the layer legends must be printed.

Print.configureTitle

boolean indicates if a title is shown in the print form

Print.mapFooter

String defines a custom footer

String defines a custom logo (this needs to be an URL)

Print.mapTitle

String defines a custom title

Print.popup

Ext.Window Window containing print form

Print.printBaseUrl

String Print base URL

Print.printPanel

GeoExt.ux.SimplePrint Panel containing the print form

Print.printPanelOptions

Object Options for the print panel

Print.windowOptions

Object Options for the popup