天津政府应急系统之GIS一张图(arcgis api for flex)讲解(七)地图打印模块

config.xml文件的配置如下:

1         <widget label="地图打印" 
2             icon="assets/images/map_print.png" config="widgets/Print/PrintWidget.xml"
3             url="widgets/Print/PrintWidget.swf" />

源代码目录如下:

模块的源代码原理解析,详细的代码在下载的开源flexviewer自带的:

大概的思路如下:地图打印主要是调用了arcgis server默认的地图打印服务方式来实现的,地图导出图片格式主要是用

var imageSnap:ImageSnapshot = ImageSnapshot.captureImage(hostBaseWidget.map, 0, pngEnc , false);
fileReference.save(imageSnap.data, "mapSnapShot.jpg");

备注:

GIS技术交流QQ群:432512093

原文地址:https://www.cnblogs.com/giserhome/p/5060296.html