mapchart使用说明

合集下载

高德企业地图 产品操作手册说明书

高德企业地图 产品操作手册说明书

高德企业地图产品操作手册v1.0发布日期2020年3月产品操作手册目录1.高德企业地图产品简介 (3)1.1基础功能模块 (3)1.2地图工具 (3)1.3组织内部协作 (4)2.登录高德企业地图 (5)3.产品功能介绍 (6)3.1点位上图 (6)3.2区块上图 (12)3.3空间检索 (20)1.高德企业地图产品简介首先,欢迎您使用高德企业地图产品。

高德企业地图,全称Map Enterprise,是基于高德自主研发的核心算法能力、及丰富多元的活地图数据之上,面向企业(或政府)提供的一套空间数据叠加分析及可视化服务能力,产品形态以在线SaaS组件、PaaS接口、或离线部署等能力输出,能够将企业的业务数据(指与点、线、面等空间位置相关的业务数据),以GIS 空间多图层叠加的方式呈现出来,帮助政企客户进行便捷的可视化查询、计算和分析。

高德企业地图产品是一套安全、可靠、灵活的产品服务。

1.1 基础功能模块高德企业地图的基础功能模块如下:点位上图 -将企业的点位数据(包括网点、商户、企业、用户、门店等),进行空间多图层叠加显示,包括对点位数据和属性字段的存储、编辑,点位纠偏、可视化样式设置(颜色/大小/透明度、自定义图标、单色图、海量点、聚合、热力、格网等)等,支持通过名称快速查询具体点位。

区块上图-将企业所需的区块数据(包括网点辐射范围、小区AOI、商圈、标准四级行政区划、自定义圆形、自定义矩形、自定义多边形、沿路自定义区块等),进行空间多图层叠加显示,包括对区块数据的围栏编辑、合并拆分,以及属性字段的存储、编辑,可视化样式设置(填充色、边框色、标签)等,支持通过名称快速查询具体区块。

空间检索–基于地图空间视图的拉框查询,支持通过圆选、框选、多边形选、四级行政区划选等,对客户一方数据或高德POI分类数据进行检索、并且支持基于客户点位数据的周边检索等。

1.2 地图工具底图切换–支持不同风格底图之间的切换,以及高德自定义地图的接入,不影响地图上的点线面数据展示。

map用法python

map用法python

map用法pythonMap是一个在Python里面被广泛使用的函数。

它的作用是将一个函数应用于一个Iterable对象的所有元素,然后将结果作为新的Iterable对象返回。

在这篇文章中,我们将会介绍map函数的用法和解释一些map函数的内部工作原理。

## Map函数的基础用法Map函数可以接受两个或多个参数。

第一个参数是用于应用于所有元素的函数,第二个参数是可迭代的对象。

除了这两个参数外,map()函数还可以接受其他参数,这些参数可以传递给函数。

```python def square(x): return x * xnumbers = [1, 2, 3, 4, 5] squared = map(square, numbers)print(list(squared)) # Output: [1, 4, 9, 16, 25] ```在这个例子中,我们定义了一个函数square(x),用于计算x * x的值。

然后将这个函数应用到numbers列表的所有元素上,通过将map函数的结果存储在squared变量中,我们可以看到squared列表中有numbers列表中各元素的平方值。

在Python 3中,map()函数返回一个可迭代对象,它可以使用list()函数转换为列表。

如果没有转换,它将在下一次迭代中被消耗。

```python def square(x): return x * xnumbers = [1, 2, 3, 4, 5] squared = map(square, numbers) print(squared) # Output: <map object at0x7f4af94b4f10># Use list to consume the map objectsquared_list = list(squared) print(squared_list) # Output: [1, 4, 9, 16, 25]# Try to get the squared values using squared object again, but it is empty squared_again =list(squared) print(squared_again) # Output: [] ```在这个例子中,我们还看到了另一个重要的概念,那就是在Python 3中,map函数返回的是一个“map”对象。

mapx学习笔记资料手册

mapx学习笔记资料手册

MAPX学习使用笔记资料Mapxtreme 下面应该有三种图层一种是固定图层当你新建一个固定图层的时候会生成*.tab等文件一种是临时图层不生成*.tab文件一种是用户绘制图层用户自己使用CDC(Graphics)进行绘图如果你想对多边形进行编辑至少你要响应Mapxtreme的鼠标事件通过鼠标事件来确定当前用户在进行何种操作。

一般的过程是这样的:1.新建一个图层(建议临时图层或者用户绘制图层)2.根据多边形的点的位置绘制图元或者用CDC绘制过变形同时确定各个点在Mapxtreme地图窗口的位置建立各个点的鼠标响应区域3.通过鼠标落下的时候通过各个点的响应区域判断那个点被选中鼠标移动和抬起时要做响应的处理来改变多边形选中点的位置重重新给多边形的点赋值如果使用临时图层需要对临时图层里面的多边形图元的点参数进行更改如果是CDC绘图的话只要更改CDC绘图即可整个过程中需要考虑到地图坐标与Mapxtreme窗口坐标之间的转化。

{通过对象编辑工具,用户可以在地图图层中创建和修改图元。

有四种标准的对象创建工具:“添加点”、“添加线条”、“添加折线”和“添加区域”。

注:若要设置所使用的工具,请设置Map.CurrentTool 属性。

对象编辑工具将新图元添加到在Layers.InsertionLayer 属性中指定的任何图层中。

只能有一个插入图层,并且默认情况下是没有插入图层。

在没有任何插入图层时将当前工具设置为对象创建工具将导致错误。

MapX 还支持对现有地图图元的修改。

若要编辑图元,则对于您要更改的任何图层,必须将Layer.Editable 属性设置为真。

然后,可以使用内置的“箭头”工具,在当前选择中移动图元或调整图元的大小。

若要移动选定图元,只需单击并在选}lyrnew:CMapxLayer;ds: CMapxDataset;rvs: CMapxRowvalues;rv: CMapxRowvalue;ptNew: CMapXpoint;ftrNew: CmapXFeature;beginlyrNew := yers.item(1);ds := Map1.Datasets.Add(miDataSetLayer, lyrNew,emptyparam,emptyparam,emptyparam,emptypara m,emptyparam,emptyparam);//rvs := ds.Rowvalues[1].Clone ;rv:= CoRowvalue.Create;rvs:=CoRowvalues.Create;rv.Dataset:=ds;rv.Field:=ds.Fields.Item(1); //假设mi表有两个字段,填充之rv.value :='item1';rvs.Add(rv);rv.Field:=ds.Fields.Item(2);rv.value :='item2';rvs.Add(rv);ptNew:=CoPoint.Create;ptNew.Set_(map1.centerx, map1.centery);ftrNew := map1.FeatureFactory .CreateSymbol(ptNew,emptyparam);ftrNew := lyrNew.AddFeature(ftrNew, rvs); // 图元+属性,即feature+Rowvalues//ftrNew = lyrNew.AddFeature(ftrNew);//ftrNew.Update (True, rvs);end.作者/收集者:zlx开发环境:Delphi + MapX代码:MapX图元分三种类型:1、线(Line),即miFeatureTypeLine2、区域(Region),即miFeatureTypeRegion3、点符号(Symbol),即miFeatureTypeSymbol加入一个时钟控件,并在时钟控件中实现以下代码:procedure TMapFrm.tmFlashSelectTimer(Sender: TObject);varft: CMapXFindFeature;lyr: CMapXLayer;bExist: Boolean;i: Integer;str: String;ds: CMapXDataset;beginbExist := False;for i := 1 to yers.Count dobeginif yers.Item[i].Name = m_strSelLyr thenbeginbExist := True;break;end;end;if not bExist thenbegintmFlashSelect.Enabled := False;MsgFrm := TMsgFrm.Create(Self);MsgFrm.m_strMsg := Format('图层[%s]信息不存在!',[m_strSelLyr]);MsgFrm.ShowModal;MsgFrm.Free;Exit;end;lyr := yers._Item(m_strSelLyr);ds := mapCity.Datasets.Add(miDataSetLayer, lyr ,EmptyParam, EmptyParam, EmptyParam, EmptyPa ram,EmptyParam, EmptyParam);lyr.Find.FindDataset := ds;lyr.Find.FindField := ds.Fields.Item[1];str := Format('%d',[m_nSelID]);ft := lyr.Find.Search(str,EmptyParam);if ft.FindRC mod 10 <> 1 thenbegintmFlashSelect.Enabled := False;MsgFrm := TMsgFrm.Create(Self);MsgFrm.m_strMsg := Format('单位点[%s]信息不存在!',[m_strCorpName]);MsgFrm.ShowModal;MsgFrm.Free;Exit;end;case ft.type_ ofmiFeatureTypeLine:beginif ft.Style.LineColor = miColorWhite then ft.Style.LineColor := miColorRedelseft.Style.LineColor := miColorWhite;end;miFeatureTypeRegion:beginif ft.Style.RegionColor = miColorGreen then ft.Style.RegionColor := miColorRedelseft.Style.RegionColor := miColorGreen;end;miFeatureTypeSymbol:beginif not m_bFlashSel thenlyr.Selection.Replace(ft)elselyr.Selection.ClearSelection;m_bFlashSel := not m_bFlashSel;end;end;ft.Update(EmptyParam, EmptyParam);if not m_bCenter thenbeginm_bCenter := True;mapCity.CenterX := ft.CenterX;mapCity.CenterY := ft.CenterY;mapCity.Refresh;end;end;我这里是把选中的图元实现闪烁,并把图元居中实现图元闪烁的另一个方法:假设图元原大小是20,改变后大小是15if ft.Style.SymbolBitmapSize=20 thenft.Style.SymbolBitmapSize:=15elseft.Style.SymbolBitmapSize:=20;ft.Update(EmptyParam, EmptyParam);ft是symbol类型的代码名称:画多边形、直线1,画多边形,画线procedure TForm1.Map1PolyToolUsed(Sender: TObject; ToolNum: Smallint; Flags: I nteger; const Points: IDispatch;bShift, bCtrl: WordBool; var EnableDefault: WordBool);varStyle: CMapXStyle;f: CMapXFeature;begincase Flags ofmiPolyToolBegin: ;{ 某些用户开始使用 PolyTool.. }miPolyToolEnd:{ 用户通过双击完成 PolyTool 的使用 }if ToolNum = MY_POLYGON_TOOL thenbegin{ 它们使用 MY_POLYGON_TOOL!制作新的区域图元并将其添加到第一个图层 }Style := Map1.DefaultStyle.Clone;Style.RegionPattern := miPatternSolid;Style.RegionColor := 255;Style.RegionBorderColor := 0;Style.RegionBorderWidth := 2;Style.RegionBorderStyle := 1;{ 使用由事件为我提供的点。

地图与地图标注API用户手册

地图与地图标注API用户手册
当再次点击时执行点击动作。当第二次点击别的点或空区域时, 焦点丢失。 线是多个地理坐标点的集合。 线中某个点位于地图中心时展开 Label。 触摸屏当点击线段中某个点时,展开 Label。 地图模块可以对地图进行放大缩小移动等功能。 地图模块可以根据经纬度定位地图中心点。 试图框架模块具有 Symbian 简单的架构,用户可以根据自身需 求覆盖其绘制,事件处理等方法。 为了便于移植,将 Symbian 一些类和变量在 map_common.h 文件中从新命名。 了便于移植,Overlay,OverlayItem 以及地图 MapController 所 有数据都为 UTF-8 格式编码以 char[] 数组形势保存字符串。在 具体的绘制方法中,绘制时需要将 UTF-8 转码。
OverlayBundle 已封装到了 MapView 中,请使用 MapView 对 OverlayBundle 进行操作。 每个 Overlay 可以管理多个 OverlayItem,并且有自己的 事件
3 / 29
高德软件
处理模块和绘制方法,用户可以覆盖重写。 OverlayItem 是纯虚类,需要有此派生出点,线面等。 每个层里用户可以通过函数添加多个 OverlayItem。 点位于地图中心时展开 Label。 当点位于地图中心时,按 OK 按钮将点设置为所在层的焦点,
4 / 29
高德软件
1.3 定义
1.3.1 EAnchorRectLocationType 锚点定义
锚点只一个点的中心点在具体图表的什么位置。以下为具体定义,默认点 Item 锚点为 EAnchorTypeDownMid,即 7 enum EAnchorRectLocationType { /*

mapchart使用流程

mapchart使用流程

mapchart使用流程MapChart 是一个简单易用的在线地图制作工具,它可以帮助用户快速创建、自定义和共享地理信息数据的地图。

无论你是想要制作一个区域分布图、显示业务数据的地图,还是在报告、演示或教学中使用地图来说明某个概念,MapChart 都能满足你的需求。

下面是使用MapChart 的一般流程:1. 访问MapChart 网站首先,打开你的浏览器并访问MapChart 的官方网站(2. 选择地图类型在MapChart 的主页上,你会看到不同的地图类型供选择。

根据你的需求,选择适合你的地图类型。

MapChart 提供的地图类型包括世界地图、大区地图、国家地图、省份地图、州地图、县地图、市地图和自定义区域地图等。

3. 自定义地图一旦选择了地图类型,你将进入地图编辑界面。

在这里,你可以自定义地图的外观、添加文本标签和图例等。

首先,你可以选择地图的背景颜色。

MapChart 提供了几种预设的颜色主题供选择,你也可以自己选择一个颜色。

然后,你可以选择地图的数据颜色方案。

MapChart 提供了多种数据颜色方案,如单色、渐变色、调色板、随机色等。

根据你的数据类型和需求,选择一个适合的颜色方案。

此外,你还可以对地图的边界线进行自定义,比如修改线条颜色、粗细和透明度等。

如果你想为特定区域添加文本标签,可以通过点击地图上的区域并输入相应的标签来实现。

4. 导入地理信息数据当你完成地图的外观调整后,你可以开始导入地理信息数据。

MapChart 支持多种数据导入方式,包括手动输入数据、复制粘贴数据、从文件导入数据等。

如果你选择手动输入数据,可以在地图编辑界面的右侧的数据面板中输入地理信息数据。

每个地理区域对应一个数据输入框,你需要按照指定的格式输入数据。

如果你选择复制粘贴数据,可以将你的数据从Excel 表格或其他数据源中复制,并粘贴到地图编辑界面的数据面板中。

同样,确保你的数据格式正确。

如果你选择从文件导入数据,可以点击数据面板中的“从文件导入”按钮,并选择合适的数据文件来导入数据。

MapSmart Android快速使用指南说明书

MapSmart Android快速使用指南说明书

M AP S MART®FOR ANDROID QUICK START GUIDE©LTI217MapSmart®Android144938Rev.1The quick reference guide instructions are sectioned by specifi c LTI lasers as used with a ruggedized Android tablet (shown below).For other Android tablets, set up may be different. Refer to your device’s manual for more information on connecting to Wifi , email accounts, and Bluetooth® enabled devices.TruPulse® 360˚/B survey laser (yellow);TruPulse® 360˚ R survey laser (black)TruPulse® 200X survey laser (red)Tablet running Android 4.1 or later TruPoint™ 300 survey laser (red)[1st Step for All] WLAN, MapSmart App, Licensing:[1] Turn on tablet, tap , tap to set SLEEP to NEVER.[2] Tap to select a wifi network and complete process.[3] T ap then tap to add a Google account or get assistance fromyour IT department to set up a dedicated email account for your reports.[4] Tap, then Search for: “LaserSoft MapSmart” and INSTALL the app.[5] From the main screen, tap , then tap to open app.[6] Tap and hold to copy or notate Machine ID on paper.[7] T ap link, then log in with your email and temporarypassword sent from LTI. [8] Paste or type the Machine ID into .[9] From the Purchases Table, copy and paste or type in your purchase ID into[10] Tap , then copy or notate the License Key. [11]Tap , then paste or type in the License Key and then tap . [12] Charge tablet. [13] Go to [2nd Step] depending upon your laser set up: TruPulse 360B/R, TruPulse 200X + TruAngle, or TruPoint 300.[3rd Step] Change Units of Measure to Feet (if necessary):[1] Long pressuntil().[2]P ressthen press until (). [3] Press , then pressagain toaccept feet/degrees and units of measurement.[1] Press to power the unit on. [2] Long press until().[3] Press until(). [4] Pressthen pressuntil ().[5] Pressto confi rm.[2nd Step for TruPulse 360B/R] Toggle On BluetoothLink:[4th Step] Connect TruPulse 360B/R with Android Device:[1] Tap, then tap. [2] Turn on tablet Bluetooth link.[3] Tap the laser model/serial number under A V AILABLE DEVICES.[4] Enter PIN number: 1111 or accept any passkey. [5]Exit to main screen.[1] Power on all components.[2] Perform the laser compass calibration routine.[3] Tap, then tap . [4] Enter fi le name, then tapand select equipment.[5] Tap, then select units that match the laser. [6] Measure from center of laser to ground and enter value.[7] M easure from center of prism to ground and enter value, then tap . Leave value 0.00 if not using a prism.[8] Leave all origin values at zero (unless known equipment position) and tap . [9] Wait forto becomeat the top of the MapSmart screen.[10] Aim and presson the laser and add the fi rst data point.[11]Enter a description and tap.[12] Finish the survey.[Final Step for TruPulse 360B/R] Set Up & Get a Shot:*For standard survey with no GPS or Resection options selected.[1] Press to power the unit on. [2] Pressuntil(). [3] Pressuntil(). [4] Pressto accept.[2nd Step for TruPulse 200X + TruAngle] Toggle On Bluetooth link:[1] Pressuntil(). [2] Press to scroll through unit options() or(). [3] Pressto accept the units of measurement().[3rd Step] Change Units of Measure to Feet (if necessary):[1] Pressuntil(). [2] Pressto choose(). [3] Presstoaccept selection. [4] Apply the mechanical fi lterto the front lens.[4th Step] Toggle On Electronic Filter (if using a refl ective target):[1] Tap , then tap . [2] Turn on tablet Bluetooth link.[3] Tap the laser model/serial number under A V AILABLE DEVICES. [4] Enter the PIN number: 1234 or accept any passkey. [5] Exit to main screen.[5th Step] Sync Tabl et’s Blue tooth link with TruP ulse 200X:[1] Power on all components. [2] Tap , then tap.[3] Enter fi le name, then tap and select equipment.[4] Tap, then select Units that match the laser.[5] Measure from center of laser to ground and enter value . [6] M easure from center of prism to ground and enter value, then tap. Leave value 0.00 if not using a prism.[7] Leave all origin values at zero and tap. [8] On TruAngle, rotate 360 degrees until becomes fl ashing[9] Aim laser at desired reference point (or prism), then tighten the TruAngle brakeand presson laser and stops fl ashing.[10] Press again to add the reference data point to your map.[11] Enter “REF” for thedescription and tapNotice that turns into at the top of the MapSmart screen. Tap to refresh connection if necessary [12] Finish the survey.[Final Step for TruPulse 200X] Set Up & Get a Shot:*For standard survey with no GPS or Resection options selected.[1] Press to power the unit on. [2] Press, then tap.[3] Taptwice, then activate WLAN connectivity . [4] Pressto accept.[2nd Step for TruPoint 300] Activate WLAN:[1] Press then tap. [2] Taptwice, then change unit of measurement.[3] Short pressto return to the main screen.[3rd Step] Change Units of Measure to Feet (if necessary):[4th Step] Connect TruPoint 300 to Tablet:[1] Tap, then tap.[2] Tap the laser model/serial number listed in available networks. [3]Laser will display as connected.[1] Power ON all components. [2] Check tablet settings to verify TruPoint is connected. [3] Tap, then tap.[4] Enter fi le name, then tap and select equipment.[5] Enter Units that match the laser.[6] Measure from center of laser to ground and enter value.[7] I f using a non-refl ective target, measure center of target to ground and enter value, then tap. If not using a target, leave value at 0.00[8] Tap, wait until the icon becomes. [9] On TruPoint, follow leveling directions.[10] On tablet, leave all origin values at zero and tap . [11] Aim laser at desiredreference point (target), then tap to zero laser, and tap.[12] Tapto add the reference data point to your map.[13] Enter “REF” for the description and tap. [14] Finish the survey.[Final Step for TruPoint 300]Set Up & Get A Shot:*For standard survey with no GPS or Resection options selected.Access MapSmart Help:[1] Tap and choose Help.Get help with:• Laser/tablet Bluetooth connection or WLAN connection*Low voltage on tablet or laser can hinder wireless connections.**Pair laser to only one device at a time.• Available mapping methods• Corrections to data point heights, notes, and orientation• Moving control point and equipment to a new position• Converting inches to decimal feet for height entries• Sending program diagnostics and/or survey *.MS4D fi le to LTI technical support (while on WiFi only).R a d i a l w i t h A n g l e M a p p i n g P a c k a g e A s s e m b l y f o r T r u P o i n t 30T r u P o i n t ™ 300#7006880L a s er A i m in g A ssist#3255094C T 7 R u g g e d i z e d A n d r o i d T a b l e t#3255095C l a w M o u n t i n g B a s e#3255097X G r i p f o r 7” T a b l e t s#3255096T r i p o d#3504683R a d i a l w i t h A n g l e M a p p i n g P a c k a g e A s s e m b l y f o r T P 200XL a s e r M o u n t i ng B r a c k e t#7024867T r u P u l s e ® 200XM a p S t a r ®T r u A n g l e ®(M S T A )#7006000(2) L a s e r B r a c k e t s f o r M S T A(I n c l u d e d w i t h #7006000)T r i B r a c h (O p t i o n a l )#3003255T r i B r a c h A d a p t o r (O p t i o n a l )#3004670L a s e r I n t e r f a c e C a b l e(I n c l u d e d w i t h #7006000)M e c h a n i c a l F i l t e r#7035142T a b l e t X G r i p C r a d l e#3255096M o u n t i n g B a s e A r m#3255097S u r v e y T r i p o d#3504630C T 7 A n d r o i d T a b l e t #3255095DataCollectorCradleClamp#354631CedarTabletMapSmartwithVolumePackage#3219MountingBracket#724866TruPulse®36/B,lasermaybesubstitutedalongwithbracket#724736LTIStaff#354236andBi-PodLegs#3542727in.TabletX-GripCradle#325596LasertoDataCollectorDownloadCable#325567(OptionalifBluetoothnotavailable) TruPulse®36RYokeLBracket#724746(optional)(optional)CedarCT7DataCollector#325595RadialwithAngleMappingPackageAssemblyforTP36Re Bluetooth® word mark and logos are registered trademarks owned by Bluetooth SIG, Inc. and any use of such marks by Laser Technology, Inc. is under license. Other trademarks and trade names are those of their respective owners.LTI Technical Support:Toll Free: 1.877.696.2584Phone: 1.303.649.1000Email:*********************Web: LTI Hours of Operation: Monday through Friday 8:00 am to 5:00 pm (MST)(Excluding Holidays)LTI Corporate Headquarters: 6912 South Quentin StreetCentennial, CO 80112 USA。

MapXtreme的一些基础概念

MapXtreme的一些基础概念

地图(MapControl):地图作为地图绘制中的核心元素,其他所有元素的操作都会在地图上,这就是地图。

图元:包括三种基本图元类型:●区域:指覆盖给定区域的闭合对象。

可以想像为一个面,其中包括多边形、椭圆和矩形。

区域包括国界、邮政编码边界和销售区域等。

●点对象:表示数据的单一位置。

就是一个点,不能缩放,其示例包括客户位置、饭店和停车计时器等。

●线对象:覆盖给定距离的开放对象。

包括直线、折线和弧线等。

其示例有街道、河流和电力线路等。

不同类型的对象可以放在同一个图层中,最常见的是每种对象放在一个单独的图层中,单独放置时,使用起来比较方便。

图层:地图绘制里的图层和Photoshop中的图片操作里的图层可以类比,在这里,地图绘制里的地图相当于图片里的图片,地图绘制里的图层相当于图片里的图层,在操作的过程中,对某些画面都可以分层进行绘制,最后会重叠在一块,白色的部分视为透明的重叠方式。

表:表包含要显示在地图上的数据。

表保存描述图元信息的行和列,这些图元包括它们的几何体、样式和属性。

MapXtreme 2005支持各种数据源中的表,包括本地表(MapInfo .TAB)、关系数据库管理系统(RDBMS)、dBase、MS Access、ASCII文件和ESRI ShapeFile。

特性表包括光栅、网络、无缝、视图、WMS和。

表通常表示一个图层的所有信息包括"几何信息"和"属性信息" ,mapinfo使用( .tab)格式,可以用文本编辑器打开MapInfo的.tab 文件可以组织成为一组用于构建图层的文件。

MapInfo 表包含以下类型的关联文件:*.tab:此文件说明 MapInfo 表的结构。

这是一个说明数据文件格式的小文本文件。

*.dat(.mdb, .dbf, .txt, .xls or .wks):这些文件包含制表数据。

*.map:此文件说明图形对象(如果表没有地图对象,则该文件将不存在)。

chart标签使用说明

chart标签使用说明

安装部署1、indigotaglib.jar为标签封装类,FusionCharts Free的各种类型的2D和3D图形对象和属性都定义在该jar包中,放在app\web\WEB-INF\lib路径下。

供业务在web层调用。

2、charts文件夹,里面包含FusionCharts Free的相关js以及各种图形的swf文件,放置路径为web\common。

Chart标签属性示例详解Jsp<indy:Chart javaScriptBase="/common/charts/" type="Column3D"name="column3Obj" width="600" height="400" />说明:1、indy:Chart chart标签。

2、javaScriptBase="/common/charts/" FusionCharts.js和各种图形的swf文件的存放路径。

一般规定是放在/common/charts/下。

3、type="Column3D" 显示图形的类型,此例为3D柱形图。

4、name="column3Obj" 该图形的唯一标识,也是从java里传过来的xml数据对象。

request.setAttribute("column3Obj", column3D);5、width="600" 图形显示的宽度。

6、height="400" 图形显示的高度。

Action以3D柱形图为例说明:创建3D柱形图xml格式数据需要引入以下类:(并不是所有类需要引入,用到什么对象就引入什么对象,看实际使用情况而定)import com.longshine.indigo.chart.fusion.column3d.Column3D;import com.longshine.indigo.chart.fusion.column3d.Line;import com.longshine.indigo.chart.fusion.column3d.Set;import com.longshine.indigo.chart.fusion.column3d.TrendLines;import com.longshine.indigo.chart.fusion.column3d.VLine;public ActionForward init(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)throws Exception {// 3D柱形图// 生成chart对象Column3D column3D = new Column3D();column3D.setCaption("每月销售额柱形图");// 主标题column3D.setXAxisName("月份");// X轴名字column3D.setYAxisName("销售额");// Y轴名字column3D.setNumberPrefix("$");// 轴刻度数值前缀,如"$12"column3D.setNumberSuffix("%A5");// 轴刻度数值后缀,"%A5"为"¥",如"12¥"column3D.setBgColor("154F67");// 设置背景颜色column3D.setFormatNumberScale("0");// 是否自动格式化单位,如12k,默认是1开启格式化column3D.setDecimals("2");// 小数点精确位数,四舍五入// 生成set对象// 第一条柱形Set s1 = column3D.createSetNode();s1.setLabel("一月");// 柱形名称s1.setValue("10000.123");// 柱形值s1.setColor("FF45FF");// 柱形颜色s1.setShowValue("0");// 是否显示该柱形上的数值,默认是1显示// 垂直分割线,垂直分割线对象非必须的,可以不创建,根据实际需求VLine vline1 = column3D.createVLineNode();vline1.setColor("FF5904");// 颜色vline1.setThickness("1");// 粗细vline1.setDashed("1");// 是否虚线// 第二条柱形Set s2 = column3D.createSetNode();s2.setLabel("二月");s2.setValue("20000.456");// 第三条柱形Set s3 = column3D.createSetNode();s3.setLabel("三月");s3.setValue("5000.789");// 垂直分割线VLine vline3 = column3D.createVLineNode();vline3.setColor("455904");// 颜色vline3.setThickness("1");// 粗细vline3.setDashed("1");// 是否虚线// 第四条柱形Set s4 = column3D.createSetNode();s4.setLabel("四月");s4.setValue("30000.321");s4.setLink("n-");// 柱形鼠标点击事件(新窗口打开百度,原窗口打开只需把"n-"去掉)// 生成trendLines趋势线,趋势线是非必须的,可以不创建,根据实际需求TrendLines t = column3D.createTrendLinesNode();// 第一条趋势线Line l1 = t.createLineNode();l1.setStartValue("12000");// 趋势线值l1.setDisplayValue("及格");// 趋势线名称// 第二条趋势线Line l2 = t.createLineNode();l2.setStartValue("20000");l2.setDisplayValue("优秀");l2.setColor("FF5904");// 趋势线颜色// 把生成图形的XML数据赋值给column3Obj对象request.setAttribute("column3Obj", column3D);return mapping.findForward("chartTest");}生成的column3D的XML数据格式如下:可以通过System.out.println(column3D.toString());把生成的xml 数据对象打印出来检查一下。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
相关文档
最新文档