Skip to content

定位

定位

ts
// 根据点坐标定位,平移
gis.goTo({ x: 118.135, y: 24.677 })
gis.goTo([118.155, 24.677])

缩放

ts
// 根据点坐标定位,缩放
gis.goTo({ x: 118.135, y: 24.677 }, 16)
gis.goTo([118.155, 24.677], 15)


gis.goTo('118.135,24.6770', 16)

四至

ts
gis.goTo('118.13,24.67,118.135,24.6770')

根据图层定位

ts
gis.goTo('temp')

shape 中调用

ts
gis
  .shape()
  .withPoint({
    x: 118.1354454882645,
    y: 24.67703265536293
  })
  .withSymbol(32, 'http://192.168.3.91/ui/user/1.png')
  .build()
  .goTo(14)

根据 shape 定位

ts
let shape = gis
  .shape()
  .withPoint({ x: 118.1354454882645, y: 24.67703265536293 })


gis.goTo(shape, 15)