Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Provides a means of displaying the current layer and gives the user the ability to turn on/off the layer visibility.

The ToC view provide a place holder to display the layers that are available on the map, but it doesn't actually describe the layers that are available, to do that you need to setup a toc model.

ID

com.cohga.html.client.main.tocView

weave.toc

Sub-tags

Name

type

cardinality

description

label

String

0..1

Label to display in tab

location

String

1..1

Which region to add the view to

toolbar

 

0..1

A toolbar of items to appear at the top of the view

statusbar 0..1A toolbar of items to appear at the bottom of the view
contextmenu 0..1a right-click context menu
Example ToC view will all available items
<view id="com.cohga.html.client.map.tocView">
	<label>Layers</label>
	<location>west</location>
	<toolbar>
		<item action="weave.toc.expandAll"/>
		<item action="weave.toc.collapseAll"/>
		<item action="weave.toc.save"/>
		<item action="weave.toc.load"/>
		<item>-&gt;</item>
		<item component="weave.toc.filter"/>
	</toolbar>
	<contextmenu>
		<item action="weave.toc.styleLayer"/>
		<item action="weave.toc.selectLayer"/>
		<item action="weave.toc.zoomToLayer"/>
		<item action="weave.toc.zoomSelection"/>
		<item action="weave.toc.zoomToMinScale"/>
		<item action="weave.toc.zoomToMaxScale"/>
		<item action="weave.toc.clearSelection"/>
		<item action="weave.toc.lockLayer"/>
	</contextmenu>
</view>

Toolbar and statusbar Items

weave.toc.expandAll

Expands all the groups/folders within the ToC view.

weave.toc.collapseAll

Collapses all the groups/folders within the ToC view.

weave.toc.save

Saves the current ToC state so it can later be restored, note that only a single ToC state can be saved at once, using the save button will replace the currently saved ToC state.

weave.toc.load

Load the previously saved ToC state.

weave.toc.filter

Refine the layers listed in the ToC.

Context Menu Items

weave.toc.styleLayer

If the layer supports multiple styles then this allows the user to switch between the available styles.

weave.toc.selectLayer

If the layer is associated with an entity this allows the user to change the active entity. Requires that the entity attribute is specified for the layer in the toc model.

weave.toc.zoomToLayer

Changes the current map extent to match that of the layer.

weave.toc.zoomSelection

If the layer is associated with an entity this allows the user to change the map view based on the extent of the current selection for that entity. Requires that the entity attribute is specified for the layer in the toc model.

weave.toc.zoomToMinScale

Change the current map extent to match the minimum scale range for the layer (if a minimum scale for the layer can be determined by Weave).

weave.toc.zoomToMaxScale

Change the current map extent to match the maximum scale range for the layer (if a maximum scale for the layer can be determined by Weave).

weave.toc.clearSelection

If the layer is associated with an entity this allows the user to clear the selection for the entity. Requires that the entity attribute is specified for the layer in the toc model.

weave.toc.lockLayer

If the layer is lockable this allows the user to toogle the state of the locking for the layer. A lockable layer is a layer that has the ability to disable the scale ranges that are applied to a layers display, allowing a user to view the layer outside of it's normal scale ranges. To create a lockable layer you need to duplicate the layer in the underlying map engine, rename the new layer to include UNLOCKED as a prefix (or :UNLOCKED as a suffix) and remove any scale ranges that are attached to the symbology for the new layer. Then when Weave attempts to display the layer in an unlocked state it will display the unlocked version of the layer rather than the original. Note, you should not include the unlocked version of the layer in the ToC model.

  • No labels