MiniMap.Alignment Property

Gets or sets the alignment of a mini map.

Namespace: DevExpress.XtraMap

Assembly: DevExpress.XtraMap.v20.1.dll

Declaration

[DefaultValue(MiniMapAlignment.BottomLeft)]
public MiniMapAlignment Alignment { get; set; }
<DefaultValue(MiniMapAlignment.BottomLeft)>
Public Property Alignment As MiniMapAlignment

Property Value

Type Default Description
MiniMapAlignment

BottomLeft

A MiniMapAlignment enumeration value.

Examples

To customize a mini map's alignment, set the MiniMap.Alignment property to the MiniMapAlignment enumeration value.

List<MiniMapBehavior> behaviors = new List<MiniMapBehavior> { 
    new FixedMiniMapBehavior(), 
    new DynamicMiniMapBehavior()
};

private void Form1_Load(object sender, EventArgs e) {
    cbAlignment.DataSource = Enum.GetValues(typeof(MiniMapAlignment));
    cbBehavior.DataSource = behaviors;
}
private void cbAlignment_SelectedIndexChanged(object sender, EventArgs e) {
    MiniMapAlignment alignment = (MiniMapAlignment)cbAlignment.SelectedValue;
    if (mapControl.MiniMap == null) return;
    mapControl.MiniMap.Alignment = alignment;
}
See Also