InteractiveClusterModeBase.ExpandedClusterLayout Property
Gets or sets the layout of expanded cluster items.
Namespace: DevExpress.XtraMap
Assembly: DevExpress.XtraMap.v21.2.dll
Declaration
Property Value
Type | Default | Description |
---|---|---|
IExpandedClusterLayout | null |
An object of a class that implements the IExpandedClusterLayout interface. |
Remarks
Users can hover over a cluster to expand it and see all nested map items. To enable this functionality, follow the steps below:
Create a MouseHoverInteractiveClusterMode object and assign it to the MapControl.InteractiveClusterMode property.
Select a layout algorithm that defines how to position nested map items when a cluster is expanded. To do this, assign one of the following objects to the InteractiveClusterModeBase.ExpandedClusterLayout property:
- ExpandedClusterAdaptiveLayout – Items are positioned in a circle or spiral depending on the item count in the cluster.
- ExpandedClusterCircularLayout – Items are positioned in a circle.
- ExpandedClusterSourceLocationLayout – Items are positioned based on their source locations.
- ExpandedClusterSpiralLayout – Items are positioned in a spiral.
After a user moves the mouse cursor out of the cluster, clustered items are repositioned based on their actual locations. Then, clustered items are collapsed into the cluster.
The following example selects an optimal view (circular or spiral) for nested cluster items depending on their count in the cluster:
MouseHoverInteractiveClusterMode interactiveMode = new MouseHoverInteractiveClusterMode();
interactiveMode.ExpandedClusterLayout = new ExpandedClusterAdaptiveLayout();
map.InteractiveClusterMode = interactiveMode;