Skip to main content

MapOverlay.Size Property

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

Namespace: DevExpress.XtraMap

Assembly: DevExpress.XtraMap.v23.2.dll

NuGet Package: DevExpress.Win.Map

Declaration

public Size Size { get; set; }

Property Value

Type Description
Size

A value that specifies size.

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