Back to Devexpress

DxMap.AutoAdjust Property

blazor-devexpress-dot-blazor-dot-dxmap-47cdfe0b.md

latest1.8 KB
Original Source

DxMap.AutoAdjust Property

Specifies whether the component automatically adjusts the map center and zoom level to display all markers and routes.

Namespace : DevExpress.Blazor

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
[DefaultValue(true)]
[Parameter]
public bool AutoAdjust { get; set; }

Property Value

TypeDefaultDescription
Booleantrue

true to adjust map settings automatically; otherwise, false.

|

Remarks

The DxMap control automatically adjusts the map center and zoom level on the initial load and when a collection of markers or routes changes. The adjustments include the following:

  • The control decreases the Zoom property to the maximum value that allows all markers and routes to be displayed. If the current zoom level allows all routes and markers to be displayed on the map, it remains unchanged.
  • The control changes the map center to align markers and routes with the control’s center.

Set the AutoAdjust property to false to disable this behavior.

razor
<DxMap Zoom="14"
       Provider="MapProvider.Azure"
       Width="100%"
       Height="600px"
       AutoAdjust="false" >
    <DxMapApiKeys Azure="@MapApiKeyProvider.GetAzureProviderKey()" />
    <DxMapCenter GeoPosition="40.7061, -73.9969" />
    @* ... *@
</DxMap>

See Also

DxMap Class

DxMap Members

DevExpress.Blazor Namespace