GeoPrisma logo

Toolbar (deprecated)

Add a navigation MapFish.widget.Toolbar in the UI. The toolbar contains the following button by default:

  • Zoom to maximum map extent
  • Zoom in
  • Zoom out
  • Navigation
  • Last extent
  • Next extent

Beside the default buttons, it’s possible to add other button in the toolbar by using the widgets <options> node.

Note

This widget must be added to the first widgets of the first resource or else it won’t be drawn. It is a bug that should be corrected in future releases.

Note

This widget must be defined only once.

Warning

This widget is deprecated. You should use the GeoExtToolbar widget instead.

XML Sample

Sample configuration of a toolbar with no widgets added.

<toolbar>
  <name>W_MyToolbar</name>
  <options>
  </options>
</toolbar>

Toolbar with more widgets added.

<toolbar>
  <name>W_MyToolbar</name>
  <options>
    <widgets>
      <widget>W_MyQuery</widget>
      <widget>W_MyMeasureTool</widget>
    </widgets>
  </options>
</toolbar>

drawWidget Sample

The toolbar widget must be drawn inside the GeoExt.MapPanel object. Here’s an example :

oMapComponent = new GeoExt.MapPanel({
  region: 'center',
  title: 'Map',
  layout: "anchor",
  border: true,
  <xsl:if test="count(/geoprisma/widgets/widget[./type = 'toolbar']) > 0 ">
    tbar:
    <xsl:for-each select="/geoprisma/widgets/widget[./type = 'toolbar']">
      <xsl:call-template name="toolbar:drawWidget">
        <xsl:with-param name="pWidgetName" select="./name" />
      </xsl:call-template>
    </xsl:for-each>,
  </xsl:if>
  map: oMap
});

Mandatory Options

N/A

Optional Options

widgets:Contains <widget> tags
widget:Must be in the <widgets> tag. Name of a widget to add in the toolbar.

Service Type

N/A

Widget Action

read

Table Of Contents

Previous topic

Split

Next topic

EditFeature_Update

This Page