protected override Style GetDefaultStyleCore() { int alpha = 255; AreaStyle areaStyle = StyleCandidates.OfType <AreaStyle>().FirstOrDefault(); alpha = areaStyle != null ? areaStyle.FillSolidBrush.Color.AlphaComponent : 255; var fillColor = new GeoColor(alpha, GeoColorHelper.GetRandomColor()); var outlineColor = new GeoColor(alpha, GeoColor.SimpleColors.Black); return(AreaStyles.CreateSimpleAreaStyle(fillColor, outlineColor)); }
protected override Style GetDefaultStyleCore() { int alpha = 255; LineStyle style = StyleCandidates.OfType <LineStyle>().FirstOrDefault(); if (style != null) { alpha = style.OuterPen.Color.AlphaComponent; } var outerColor = new GeoColor(alpha, GeoColorHelper.GetRandomColor(RandomColorType.Bright)); return(new LineStyle(new GeoPen(outerColor))); }
protected override Style GetDefaultStyleCore() { int alpha = 255; PointStyle style = StyleCandidates.OfType <PointStyle>().FirstOrDefault(); if (style != null) { alpha = style.SymbolSolidBrush.Color.AlphaComponent; } var fillColor = new GeoColor(alpha, GeoColorHelper.GetRandomColor()); var outlineColor = new GeoColor(alpha, GeoColor.StandardColors.Black); return(PointStyles.CreateSimpleCircleStyle(fillColor, 8, outlineColor)); }
protected override Style GetDefaultStyleCore() { int alpha = 255; WellPointStyle style = StyleCandidates.OfType <WellPointStyle>().FirstOrDefault(); if (style != null) { alpha = style.SymbolSolidBrush.Color.AlphaComponent; } var fillColor = new GeoColor(alpha, GeoColorHelper.GetRandomColor()); var outlineColor = new GeoColor(alpha, GeoColor.StandardColors.Black); return(new WellPointStyle(1, new GeoSolidBrush(fillColor), new GeoPen(outlineColor), 8)); }
protected override Style GetDefaultStyleCore() { int alpha = 255; LineStyle style = StyleCandidates.OfType <LineStyle>().FirstOrDefault(); if (style != null) { alpha = style.OuterPen.Color.AlphaComponent; } GeoColor outerColor = new GeoColor(alpha, GeoColorHelper.GetRandomColor(RandomColorType.Bright)); LineStyle lineStyle = new LineStyle(new GeoPen(outerColor)); lineStyle.OuterPen.StartCap = DrawingLineCap.Round; lineStyle.OuterPen.EndCap = DrawingLineCap.Round; return(lineStyle); }
public SimpleAreaStylePlugin() : base() { IsDefault = true; Name = GisEditor.LanguageManager.GetStringResource("SimpleAreaStyleName"); Description = GisEditor.LanguageManager.GetStringResource("SimpleAreaStylePluginDescription"); SmallIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simplearea.png", UriKind.RelativeOrAbsolute)); LargeIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simplearea.png", UriKind.RelativeOrAbsolute)); StyleCategories = StyleCategories.Area; Index = StylePluginOrder.SimpleStyle; AreaStyle areaStyle = new AreaStyle { Name = GisEditor.LanguageManager.GetStringResource("MapElementsListPluginAreaHeader"), FillSolidBrush = new GeoSolidBrush(GeoColor.FromHtml("#C0C0C0")), OutlinePen = new GeoPen(GeoColor.FromHtml("#808080"), 1), }; StyleCandidates.Add(areaStyle); areaStyleOption = new StyleSetting(this); }
public SimpleLineStylePlugin() : base() { IsDefault = true; Name = GisEditor.LanguageManager.GetStringResource("SimpleLineStyleName"); Description = GisEditor.LanguageManager.GetStringResource("SimpleLineStylePluginDescription"); SmallIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simpleline.png", UriKind.RelativeOrAbsolute)); LargeIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simpleline.png", UriKind.RelativeOrAbsolute)); Index = StylePluginOrder.SimpleStyle; StyleCategories = StyleCategories.Line; LineStyle lineStyle = new LineStyle { Name = GisEditor.LanguageManager.GetStringResource("AnnotationStylesRibbonGroupLineStyleLabel"), OuterPen = new GeoPen(GeoColor.SimpleColors.Black, 1), InnerPen = new GeoPen(GeoColor.StandardColors.Transparent, 1), CenterPen = new GeoPen(GeoColor.StandardColors.Transparent, 1), }; StyleCandidates.Add(lineStyle); lineStyleOption = new StyleSetting(this); }
public WellPointStylePlugin() : base() { Name = "Well Point Style"; Description = "The Well Point Style provides robust control over the symbol that you want to use for your point features. You can select a symbol type and size, fill and outline colors, outline thickness and more."; SmallIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simplepoint.png", UriKind.RelativeOrAbsolute)); LargeIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simplepoint.png", UriKind.RelativeOrAbsolute)); StyleCategories = StyleCategories.Point; Index = StylePluginOrder.WellPointStyle; WellPointStyle pointStyle = new WellPointStyle { Name = "Well Point Style", WellPointIndex = 1, SymbolSize = 8, SymbolSolidBrush = new GeoSolidBrush(GeoColor.FromHtml("#FF4500")), SymbolPen = new GeoPen(GeoColor.StandardColors.Black, 1), }; StyleCandidates.Add(pointStyle); styleOption = new StyleSetting(this); }
public SimplePointStylePlugin() : base() { IsDefault = true; IsRequired = true; Name = GisEditor.LanguageManager.GetStringResource("SimplePointStyleName"); Description = GisEditor.LanguageManager.GetStringResource("SimplePointStylePluginDescription"); SmallIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simplepoint.png", UriKind.RelativeOrAbsolute)); LargeIcon = new BitmapImage(new Uri("/GisEditorPluginCore;component/Images/styles_simplepoint.png", UriKind.RelativeOrAbsolute)); StyleCategories = StyleCategories.Point; Index = StylePluginOrder.SimpleStyle; PointStyle pointStyle = new PointStyle { Name = GisEditor.LanguageManager.GetStringResource("MapElementsListPluginPointHeader"), SymbolType = PointSymbolType.Circle, SymbolSize = 6, SymbolSolidBrush = new GeoSolidBrush(GeoColor.FromHtml("#FF4500")), SymbolPen = new GeoPen(GeoColor.StandardColors.Black, 1), }; StyleCandidates.Add(pointStyle); pointStyleOption = new StyleSetting(this); }