Метод AddGlues (Объект IIngeoMapEditorsSink)


Вызывается для получения от обработчика дополнительных элементов подравнивания.

Синтаксис

ЯзыкОписание
VBScript, JavaScriptSubAddGlues(aX, aY, aRadius, aGlues)
Visual BasicSub AddGlues(ByVal aX As Double, ByVal aY As Double, ByVal aRadius As Double, ByVal aGlues As IIngeoGlues)
Delphiprocedure AddGlues(aX: Double; aY: Double; aRadius: Double; aGlues: IIngeoGlues);
C, C++HRESULT AddGlues(double aX, double aY, double aRadius, IIngeoGlues* aGlues);

Параметры

aX
X координата точки указателя мыши (в мировой системе координат).
aY
Y координата точки указателя мыши (в мировой системе координат).
aRadius
Радиус окружности, в пределах которой производится поиск элементов подравнивания.
aGlues
Объект для добавления элементов подравнивания.

Пример

sub PaintPoint(x, y) 
  Dim theSurface, theContour, theContourPart
  Dim theParam
  Set theSurface = Application.MainWindow.MapWindow.Surface
  theSurface.Pen.Color = 0
  Set theContour = Application.CreateObject(0, theParam)
  Set theContourPart = theContour.Insert(0)
  theContourPart.InsertVertex 0, x, y, 0
  theContourPart.InsertVertex 1, x+1, y+1, 0
  theSurface.PaintContour theContour, true
end sub

' Добавление точек подравнивания 
sub MapEditors_AddGlues(aX, aY, aRadius, aGlues)
  Dim i, j
  Dim theSurface
  Set theSurface = Application.MainWindow.MapWindow.Surface
  for i=0 to 1000
    for j=0 to 1000
      aGlues.AddVertexGlue i, j, ""
      PaintPoint i, j
      j = j+100
    next
    i = i+100
  next
end sub

См.также

IIngeoMapEditorsSink, IIngeoGlues