update loadLegend function

This commit is contained in:
wyq 2021-03-30 11:05:06 +08:00
parent 4187d0c674
commit 9925af5a1b
4 changed files with 16 additions and 53 deletions

View File

@ -623,7 +623,7 @@ package org.meteoinfo.geometry.graphic;
case CHART_BREAK:
ChartBreak aChB = new ChartBreak(ChartTypes.BAR_CHART);
try {
ChartTypes chartType = ChartTypes.valueOf(legendNode.getAttributes().getNamedItem("ChartType").getNodeValue());
ChartTypes chartType = ChartTypes.valueOfBack(legendNode.getAttributes().getNamedItem("ChartType").getNodeValue());
aChB = new ChartBreak(chartType);
aChB.setShapeIndex(Integer.parseInt(legendNode.getAttributes().getNamedItem("ShapeIndex").getNodeValue()));
List<Float> cData = new ArrayList<Float>();

View File

@ -1,11 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<MeteoInfo File="milconfig.xml" Type="configurefile">
<Path OpenPath="D:\Working\MIScript\Jython\mis\map">
<RecentFolder Folder="D:\Working\MIScript\mywork\aqi_data"/>
<RecentFolder Folder="D:\Working\MIScript\cuace"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\dataframe"/>
<RecentFolder Folder="D:\Working\MIScript\cuace\script\verification"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\chart\subplot"/>
<Path OpenPath="D:\Working\MIScript\Jython\mis\toolbox\miml\deep_learning\classification">
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\common_math"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\array"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\common_math\interpolate"/>
@ -14,19 +9,24 @@
<RecentFolder Folder="D:\Working\MIScript\cuace\script"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\chart"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\map"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\toolbox"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\toolbox\miml\classification"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\toolbox\miml"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\toolbox\miml\deep_learning"/>
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\toolbox\miml\deep_learning\classification"/>
</Path>
<File>
<OpenedFiles>
<OpenedFile File="D:\Working\MIScript\cuace\script\plot_pm25_3d_particles_relief.py"/>
<OpenedFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\contourf_1.py"/>
<OpenedFile File="D:\Working\MIScript\Jython\mis\map\add_curveline.py"/>
<OpenedFile File="D:\Working\MIScript\Jython\mis\toolbox\miml\deep_learning\classification\moon.py"/>
</OpenedFiles>
<RecentFiles>
<RecentFile File="D:\Working\MIScript\cuace\script\plot_pm25_3d_particles_relief.py"/>
<RecentFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\contourf_1.py"/>
<RecentFile File="D:\Working\MIScript\Jython\mis\map\add_curveline.py"/>
<RecentFile File="D:\Working\MIScript\Jython\mis\toolbox\miml\deep_learning\classification\moon.py"/>
</RecentFiles>
</File>
<Font>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<MeteoInfo File="config.xml" Type="configurefile">
<Path OpenPath="D:\Temp\Map"/>
<Path OpenPath="D:\KeyData\PMMUL\analysis"/>
<Font>
<TextFont FontName="YaHei Consolas Hybrid" FontSize="14"/>
<LegendFont FontName="宋体" FontSize="12"/>
@ -8,5 +8,5 @@
<ScriptLanguage Language="Jython"/>
<LookFeel LafDecorated="true" Name="FlatLightLaf"/>
<Figure DoubleBuffering="true"/>
<Startup MainFormLocation="0,-2" MainFormSize="1280,680" ShowMeteoDataDlg="true"/>
<Startup MainFormLocation="0,-2" MainFormSize="1280,680" ShowMeteoDataDlg="false"/>
</MeteoInfo>

View File

@ -8,7 +8,7 @@
<MaskOut MaskLayer="china.shp" SetMaskLayer="false"/>
<Projection IsLonLatMap="true" ProjStr="+title=long/lat:WGS84 +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees "/>
<GroupLayer>
<Layer AvoidCollision="false" Expanded="false" FileName="..\..\..\..\Distribution\Java\MeteoInfo\MeteoInfo\map\cn_province.shp" Handle="1" IsMaskout="false" LayerDrawType="Map" LayerName="cn_province.shp" LayerType="VectorLayer" ShapeType="POLYGON_Z" TransparencyPerc="0" Visible="true">
<Layer AvoidCollision="false" Expanded="false" FileName="..\..\..\..\Distribution\Java\MeteoInfo\MeteoInfo\map\cn_province.shp" Handle="1" IsMaskout="false" LayerDrawType="MAP" LayerName="cn_province.shp" LayerType="VECTOR_LAYER" ShapeType="POLYGON_Z" TransparencyPerc="0" Visible="true">
<LegendScheme BreakNum="1" FieldName="" HasNoData="false" LegendType="SINGLE_SYMBOL" MaxValue="0.0" MinValue="0.0" ShapeType="POLYGON_Z" UNDEF="-9999.0">
<Breaks>
<Break BackColor="0x00ffffff" Caption="" Color="0xfffffbc3" DrawFill="false" DrawOutline="true" DrawShape="true" EndValue="0" OutlineColor="0xff808080" OutlineSize="1.0" StartValue="0" Style="NONE" StyleSize="8" Tag=""/>
@ -24,7 +24,7 @@
<ChartGraphics/>
<VisibleScale EnableMaxVisScale="false" EnableMinVisScale="false" MaxVisScale="0.0" MinVisScale="0.0"/>
</Layer>
<Layer AvoidCollision="false" Expanded="false" FileName="..\..\..\..\..\Temp\Map\country1.shp" Handle="2" IsMaskout="false" LayerDrawType="Map" LayerName="country1.shp" LayerType="VectorLayer" ShapeType="POLYGON" TransparencyPerc="0" Visible="true">
<Layer AvoidCollision="false" Expanded="false" FileName="..\..\..\..\..\Temp\Map\country1.shp" Handle="2" IsMaskout="false" LayerDrawType="MAP" LayerName="country1.shp" LayerType="VECTOR_LAYER" ShapeType="POLYGON" TransparencyPerc="0" Visible="true">
<LegendScheme BreakNum="1" FieldName="" HasNoData="false" LegendType="SINGLE_SYMBOL" MaxValue="0.0" MinValue="0.0" ShapeType="POLYGON" UNDEF="-9999.0">
<Breaks>
<Break BackColor="0x00ffffff" Caption="" Color="0xfffffbc3" DrawFill="false" DrawOutline="true" DrawShape="true" EndValue="0" OutlineColor="0xff000000" OutlineSize="1.0" StartValue="0" Style="NONE" StyleSize="8" Tag=""/>
@ -41,49 +41,12 @@
<VisibleScale EnableMaxVisScale="false" EnableMinVisScale="false" MaxVisScale="0.0" MinVisScale="0.0"/>
</Layer>
</GroupLayer>
<Graphics>
<Graphic>
<Shape Selected="false" ShapeType="CURVE_LINE" Visible="true">
<Points>
<Point X="118.55421447753906" Y="54.82384490966797"/>
<Point X="109.51807403564453" Y="44.703365325927734"/>
<Point X="97.59036254882812" Y="35.66722106933594"/>
<Point X="68.3132553100586" Y="17.956377029418945"/>
<Point X="43.37349319458008" Y="10.004569053649902"/>
<Point X="9.75903606414795" Y="4.582882404327393"/>
</Points>
</Shape>
<Legend Color="0xffff0000" DrawSymbol="false" LegendType="POLYLINE_BREAK" Size="2.0" Style="STATIONARY_FRONT" SymbolColor="0xff000000" SymbolInterval="1" SymbolSize="8.0" SymbolStyle="UP_TRIANGLE"/>
</Graphic>
<Graphic>
<Shape Selected="false" ShapeType="CURVE_LINE" Visible="true">
<Points>
<Point X="60.361446380615234" Y="54.46240234375"/>
<Point X="43.37349319458008" Y="45.06481170654297"/>
<Point X="22.048192977905273" Y="37.11300277709961"/>
<Point X="1.0843373537063599" Y="34.221435546875"/>
<Point X="-16.265060424804688" Y="36.751556396484375"/>
</Points>
</Shape>
<Legend Color="0xffff0000" DrawSymbol="false" LegendType="POLYLINE_BREAK" Size="2.0" Style="OCCLUDED_FRONT" SymbolColor="0xff000000" SymbolInterval="1" SymbolSize="8.0" SymbolStyle="UP_TRIANGLE"/>
</Graphic>
</Graphics>
<Graphics/>
</MapFrame>
</MapFrames>
<Layout BackColor="0xffffffff" ForeColor="0xff000000" Landscape="true" PaperSizeHeight="750" PaperSizeName="Custom" PaperSizeWidth="500" SmoothingMode="false">
<LayoutElements>
<LayoutMap DrawBackColor="false" DrawDegreeSymbol="false" DrawGridLabel="true" DrawGridLine="false" DrawNeatLine="true" ElementType="LayoutMap" GridFontName="Arial" GridFontSize="12" GridLabelPosition="LEFT_BOTTOM" GridLineColor="0xff808080" GridLineSize="1.0" GridLineStyle="DASH" GridXDelt="10.0" GridXOrigin="-180.0" GridYDelt="10.0" GridYOrigin="-90.0" Height="404" Left="48" NeatLineColor="0xff000000" NeatLineSize="1.0" Top="30" Width="592"/>
<LayoutGraphic ElementType="LayoutGraphic" Height="0" IsTitle="false" Left="362" Top="23" Width="0">
<Graphic>
<Shape Selected="false" ShapeType="POINT" Visible="true">
<Points>
<Point X="362.0" Y="23.0"/>
</Points>
</Shape>
<Legend Color="0xff000000"/>
</Graphic>
</LayoutGraphic>
<LayoutLegend BackColor="0x00000000" ColumnNumber="1" DrawBackColor="false" DrawChartBreaks="true" DrawNeatLine="false" ElementType="LayoutLegend" FontName="Arial" FontSize="10" ForceDrawOutline="true" Height="349" LayerUpdateType="FirstMeteoLayer" LayoutMapIndex="0" Left="650" LegendLayer="" LegendStyle="Bar_Vertical" NeatLineColor="0xff000000" NeatLineSize="1.0" Top="63" Width="39"/>
<LayoutMap DrawBackColor="false" DrawDegreeSymbol="false" DrawGridLabel="true" DrawGridLine="false" DrawNeatLine="true" ElementType="MAP" GridFontName="Arial" GridFontSize="12" GridLabelPosition="LEFT_BOTTOM" GridLineColor="0xff808080" GridLineSize="1.0" GridLineStyle="DASH" GridXDelt="10.0" GridXOrigin="-180.0" GridYDelt="10.0" GridYOrigin="-90.0" Height="404" Left="48" NeatLineColor="0xff000000" NeatLineSize="1.0" Top="30" Width="592"/>
</LayoutElements>
</Layout>
</MeteoInfo>