如何获取 .Net Maui 地图的中心位置?

huangapple go评论119阅读模式
英文:

How do you get a .Net Maui Map Center Location?

问题

如果用户滚动地图,我想获取地图中心下方的位置。我知道有Map.Frame.Center,但那是地图控件渲染的中心,而不是地图位置。

如果该属性不可用,是否有关于用户将地图移动到何处的任何信息可用?

英文:

If a user scrolls the map I'd like to get the location under the center of the map. I know there's the Map.Frame.Center, but that's the center of the map control rendering, not the map location.

If that property is not available is there any information available as to where the user has moved the map to?

答案1

得分: 2

使用 mymap.VisibleRegion.Center

英文:

Use mymap.VisibleRegion.Center

huangapple
  • 本文由 发表于 2023年2月27日 09:58:16
  • 转载请务必保留本文链接:https://go.coder-hub.com/75576217.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定