Arcgis silverlight-8 工具(Bookmark,Magnifier等)

     本节介绍Arcgis silverlight的工具,包括

Bookmarks,FeatureDataGrid,Magnifier,MagnifyingGlass,MapProgressBar,MapTip,Navigation,OverviewMap,TimeSlider,Toolbar。

1、Bookmarks(书签工具,定义一个书签指代一个地图范围,点击这个书签名称例如USA,就可以立马定位到地图上的美国位置)

2、FeatureDataGrid(显示图层的属性数据,可以实现地图和属性的连动,点击属性自动查询对应地物,点击地物自动查询对应属性)

3、Magnifier(放大镜功能)

4、MagnifyingGlass(与上个类似,放大镜功能)

5、MapProgressBar(进度条,地图事件处理时(缩放等),能显示剩余时间)

6、MapTip(鼠标放在地物上能显示地物属性)

7、Navigation(导航工具)

8、OverviewMap(鹰眼)

9、TimeSlider(滑动滚动栏,能显示地物的变化属性)

10、Toolbar(工具栏)

    

      下面分别具体描述下各个控件

直接引用即可使用的工具有:Bookmarks,Magnifier,MagnifyingGlassMapProgressBar,Navigation和OverviewMap6个控件

Bookmarks

xmal中直接引用,只要将Map属性绑定当前地图即可,Map="{Binding ElementName=MyMap}"

代码
< esri:Bookmark  x:Name ="MyBookmarks"  Width ="125"  HorizontalAlignment ="Right"  VerticalAlignment ="Top"  
             Margin
="0,10,10,0"  Background ="#99257194"  BorderBrush ="#FF92a8b3"  Foreground ="Black"  
             Map
=" {Binding ElementName=MyMap} "
             Loaded
="MyBookmarks_Loaded"   />

 

效果见http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Bookmarks

 

Magnifier

xmal中直接引用,只要将Map属性绑定当前地图即可,layers中绑定要放大的图层序列

代码

< Canvas >
  
< esri:Magnifier  x:Name ="MyMagnifier"  ZoomFactor ="3"  Canvas.ZIndex ="10"  Map =" {Binding ElementName=MyMap} "   >
     
< esri:Magnifier.Layers >
         
< esri:ArcGISTiledMapServiceLayer  ID ="MagnifyTopoLayer"
             Url
="http://server.arcgisonline.com/ArcGIS/rest/services/NGS_Topo_US_2D/MapServer"   />
      
</ esri:Magnifier.Layers >
  
</ esri:Magnifier >
</ Canvas >

 

效果见http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Magnify

 

MagnifyingGlass

xmal中直接引用,只要将Map属性绑定当前地图即可,layer中绑定要放大的图层

代码
< esri:MagnifyingGlass  x:Name ="MyMagnifyingGlass"  Visibility ="Visible"  
                                         HorizontalAlignment
="Left"  VerticalAlignment ="Top"
                                         Map
=" {Binding ElementName=MyMap} "   >
            
< esri:MagnifyingGlass.Layer >
                
< esri:ArcGISTiledMapServiceLayer  ID ="StreetMapLayer"  
                    Url
="http://services.arcgisonline.com/ArcGIS/rest/services/NPS_Physical_World_2D/MapServer" />
            
</ esri:MagnifyingGlass.Layer >
</ esri:MagnifyingGlass >

 

 

 

效果见http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#MagnifyingGlass

 

你可能感兴趣的:(silverlight)