Skip to main content

MapOverlay.Padding Property

Gets or sets the map overlay’s padding in device-independent pixels (DIPs).

Namespace: DevExpress.XtraMap

Assembly: DevExpress.XtraMap.v24.2.dll

Declaration

public Padding Padding { get; set; }

Property Value

Type Description
Padding

A value that specifies the padding.

Remarks

The following example creates a map overlay and specifies its options such as content, alignment, indents, and size:

A map overlay of the specified size

using DevExpress.XtraMap;
    private void Form1_Load(object sender, EventArgs e) {
        MapOverlay overlayWithText = new MapOverlay {
            Alignment = ContentAlignment.BottomRight,
            JoiningOrientation = Orientation.Vertical,
            Margin = new Padding(0, 4, 8, 8),
            Padding = new Padding(7),
            Size = new Size(700, 40)
        };
        overlayWithText.Items.Add(new MapOverlayTextItem {
            Text = "Copyright © 2022. Microsoft and its suppliers. All rights reserved."
        });
        map.Overlays.Add(overlayWithText);
    }
See Also