IMapTopobaseShape.ImageOriginOffset

Syntax

ImageOriginOffset: IGxPointF;

Description

The ImageOriginOffset property determines parameters of the icon indicator anchor point.

Example

Executing the example requires a form with the following components: the Button component named Button1, the MapBox component named MapBox1, and the UiMap component named UiMap1. UiMap1 is a data source for MapBox1. The UiMap1 component must have the connected map. The map must have icon indicators set up.

The example is a handler of the OnClick event for the Button1 component.

Add links to the Drawing, ExtCtrls, Forms, and Map system assemblies.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
    M: IMap;
    Point: IGxPointF;
    Layer: IMapLayer;
    Shape: IMapTopobaseShape;
Begin
    M := UiMap1.Map;
    Layer := M.Layers.FindByName("Regions");
    Shape := Layer.Shapes.Item(0);
    Point := Shape.ImageOriginOffset;
    Point.Offset(0.10.3);
    Shape.ImageOriginOffset:= Point;
End Sub Button1OnClick;

After executing the example, on clicking the button the icon indicator of the first area is offset by 0.1 along the X axis and by 0.3 along the Y axis.

See also:

IMapTopobaseShape