private ILayer InitDataFrame(string gxfile, IElement ele, bool isLoadGeoGridLayer) { IDataFrame df = ele as IDataFrame; df.BorderColor = (ele as IDataFrame).BorderColor; df.BorderWidth = (ele as IDataFrame).BorderWidth; df.Location = (ele as IDataFrame).Location; df.Size = (ele as IDataFrame).Size; df.Angle = (ele as IDataFrame).Angle; df.Update(this); IDataFrameDataProvider provider = df.Provider as IDataFrameDataProvider; ILayer gridLayer = null; if (df.GeoGridXml != null) { gridLayer = LoadGeoGridLayerExecutor(df.GeoGridXml); } if (provider != null) { ICanvas c = provider.Canvas; if (c != null) { if (c.CanvasSetting != null) { if (c.CanvasSetting.RenderSetting != null) { c.CanvasSetting.RenderSetting.BackColor = Color.White; } } if (df.Data != null && LoadDataFrameExecutor != null) { LoadDataFrameExecutor(gxfile, this, df, df.Data as XElement); } } } return(gridLayer); }