Exemplo n.º 1
0
 public CalendarStreamChartScript() : base(D3ChartScript.CalendarStream)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("calendar.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Date", ChartColumnType.DateOnly),
         new ChartScriptColumn("Color Scale", ChartColumnType.Magnitude)
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup()
         {
             new ChartScriptParameter("StartDate", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("Sunday|Monday")
             },
             new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Sqrt|Log")
             },
             new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
         }
     };
 }
Exemplo n.º 2
0
 public BarsChartScript() : base(D3ChartScript.Bars)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("bars.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Bars", ChartColumnType.Groupable),
         new ChartScriptColumn("Width", ChartColumnType.Positionable)
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("Scale", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
             new ChartScriptParameter("CompleteValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("Auto|Yes|No")
             },
         },
         new ChartScriptParameterGroup("Margins")
         {
             new ChartScriptParameter("Labels", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Inside|Margin|None")
             },
             new ChartScriptParameter("LabelsMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 100m
                 }
             },
         },
         new ChartScriptParameterGroup("Numbers")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
             new ChartScriptParameter("NumberColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("#fff")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         }
     };
 }
Exemplo n.º 3
0
 public LineChartScript() : base(D3ChartScript.Line)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("lines.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Height", ChartColumnType.Positionable)
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("Scale", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
             new ChartScriptParameter("CompleteValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("Auto|Yes|No")
             },
         },
         new ChartScriptParameterGroup("Margins")
         {
             new ChartScriptParameter("UnitMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 20m
                 }
             },
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             }
         },
         new ChartScriptParameterGroup("Color")
         {
             new ChartScriptParameter("Color", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("steelblue")
             },
         },
         new ChartScriptParameterGroup("Form")
         {
             new ChartScriptParameter("Interpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("linear|step-before|step-after|cardinal|monotone|basis|bundle|catmull-rom")
             },
         }
     };
 }
Exemplo n.º 4
0
    public static void Start(SchemaBuilder sb, bool googleMapsChartScripts, string[]?svgMapUrls = null)
    {
        if (sb.NotDefined(MethodInfo.GetCurrentMethod()))
        {
            QueryLogic.Start(sb);

            PermissionAuthLogic.RegisterTypes(typeof(ChartPermission));

            ChartColorLogic.Start(sb);
            ChartScriptLogic.Start(sb, googleMapsChartScripts, svgMapUrls);
            UserChartLogic.Start(sb);
        }
    }
Exemplo n.º 5
0
 public HeatmapChartScript() : base(GoogleMapsChartScript.Heatmap)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("heatmap.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Latitude", ChartColumnType.Magnitude),
         new ChartScriptColumn("Longitude", ChartColumnType.Magnitude),
         new ChartScriptColumn("Weight", ChartColumnType.Magnitude)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Map")
         {
             new ChartScriptParameter("MapType", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Roadmap|Satellite")
             },
             new ChartScriptParameter("MapStyle", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Standard|Silver|Retro|Dark|Night|Aubergine")
             }
         },
         new ChartScriptParameterGroup("Label")
         {
             new ChartScriptParameter("Opacity", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("1|0.9|0.8|0.7|0.6|0.5|0.4|0.3|0.2|0.1")
             },
             new ChartScriptParameter("Radius(px)", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 10m
                 }
             },
         },
         new ChartScriptParameterGroup("Color Gradient")
         {
             new ChartScriptParameter("ColorGradient", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Default|Blue-Red|Purple-Blue|Orange-Red|Fire|Emerald|Cobalt|Purples|Greys")
             },
         }
     };
 }
Exemplo n.º 6
0
 public PieChartScript() : base(D3ChartScript.Pie)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("doughnut.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Sections", ChartColumnType.Groupable),
         new ChartScriptColumn("Angle", ChartColumnType.Magnitude)
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Form")
         {
             new ChartScriptParameter("InnerRadious", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0m
                 }
             },
         },
         new ChartScriptParameterGroup("Arrange")
         {
             new ChartScriptParameter("Sort", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("No|Ascending|Descending")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         },
         new ChartScriptParameterGroup("ShowPercent")
         {
             new ChartScriptParameter("ValueAsPercent", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("No|Yes")
             },
         },
     };
 }
Exemplo n.º 7
0
 public MultiColumnsChartScript() : base(D3ChartScript.MultiColumns)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("multicolumns.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Split Columns", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height", ChartColumnType.Positionable),
         new ChartScriptColumn("Height 2", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 3", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 4", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 5", ChartColumnType.Positionable)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("Scale", ChartParameterType.Enum)
             {
                 ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
             new ChartScriptParameter("CompleteValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("Auto|Yes|No")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("UnitMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 20m
                 }
             },
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
             new ChartScriptParameter("NumberColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("#fff")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         }
     };
 }
Exemplo n.º 8
0
 public ScatterplotChartScript() : base(D3ChartScript.Scatterplot)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("points.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Point Color", ChartColumnType.Groupable),
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Positionable),
         new ChartScriptColumn("Vertical Axis", ChartColumnType.Positionable)
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("HorizontalScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
             new ChartScriptParameter("VerticalScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("UnitMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 40m
                 }
             },
         },
         new ChartScriptParameterGroup("Points")
         {
             new ChartScriptParameter("PointSize", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 4m
                 }
             },
             new ChartScriptParameter("DrawingMode", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Svg|Canvas")
             },
         },
         new ChartScriptParameterGroup("Color Scale")
         {
             new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Ordinal|ZeroMax|MinMax|Sqrt|Log")
             },
             new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         },
     };
 }
Exemplo n.º 9
0
 public MarkermapChartScript() : base(GoogleMapsCharScript.Markermap)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("markermap.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Latitude", ChartColumnType.Magnitude),
         new ChartScriptColumn("Longitude", ChartColumnType.Magnitude),
         new ChartScriptColumn("Label", ChartColumnType.String)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Icon", ChartColumnType.String)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Title", ChartColumnType.String)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Info", ChartColumnType.String)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Color Scale", ChartColumnType.Real)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Color Category", ChartColumnType.Groupable)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Map")
         {
             new ChartScriptParameter("MapType", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Roadmap|Satellite")
             },
             new ChartScriptParameter("MapStyle", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Standard|Silver|Retro|Dark|Night|Aubergine")
             },
         },
         new ChartScriptParameterGroup("Label")
         {
             new ChartScriptParameter("AnimateDrop", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("No|Yes")
             },
             new ChartScriptParameter("AnimateOnClick", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("No|Yes")
             },
             new ChartScriptParameter("InfoLinkPosition", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Inline|Below")
             },
         },
         new ChartScriptParameterGroup("Performance")
         {
             new ChartScriptParameter("ClusterMap", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Yes|No")
             },
         },
         new ChartScriptParameterGroup()
         {
             new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 6, ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Sqrt|Log")
             },
             new ChartScriptParameter("ColorSet", ChartParameterType.Enum)
             {
                 ColumnIndex = 6, ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ColumnIndex = 7, ValueDefinition = EnumValueList.Parse("category10|category20|category20b|category20c|accent|paired|pastel1|pastel2|set1|set2|set3")
             }
         }
     };
 }
Exemplo n.º 10
0
 public PivotTableScript() : base(HtmlChartScript.PivotTable)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("pivottable.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Horizontal Axis (2)", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Horizontal Axis (3)", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Vertical Axis", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Vertical Axis (2)", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Vertical Axis (3)", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Value", ChartColumnType.Magnitude),
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         CreateBlock("Complete ", ChartParameterType.Enum, EnumValueList.Parse("No|Yes|Consistent|FromFilters"), includeValues: false),
         CreateBlock("Order ", ChartParameterType.Enum, EnumValueList.Parse("None|Ascending|AscendingKey|AscendingToStr|AscendingSumValues|Descending|DescendingKey|DescendingToStr|DescendingSumValues"), includeValues: false),
         CreateBlock("Gradient ", ChartParameterType.Enum, EnumValueList.Parse("None|YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn"), includeValues: true),
         CreateBlock("Scale ", ChartParameterType.Enum, EnumValueList.Parse("ZeroMax|MinMax|Sqrt|Log"), includeValues: true),
         CreateBlock("CSS Style ", ChartParameterType.String, new StringValue(""), includeValues: true),
         CreateBlock("Max Text Length ", ChartParameterType.Number, new NumberInterval {
             DefaultValue = 50
         }, includeValues: false),
         new ChartScriptParameterGroup()
         {
             new ChartScriptParameter("SubTotal Horizontal Axis (2)", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("no|yes")
             },
             new ChartScriptParameter("SubTotal Horizontal Axis (3)", ChartParameterType.Enum)
             {
                 ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("no|yes")
             },
             new ChartScriptParameter("Placeholder Vertical Axis", ChartParameterType.Enum)
             {
                 ColumnIndex = 3, ValueDefinition = EnumValueList.Parse("no|empty|filled")
             },
             new ChartScriptParameter("Placeholder Vertical Axis (2)", ChartParameterType.Enum)
             {
                 ColumnIndex = 4, ValueDefinition = EnumValueList.Parse("no|empty|filled")
             },
         },
     };
 }
Exemplo n.º 11
0
 public MultiLinesChartScript() : base(D3ChartScript.MultiLines)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("multilines.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Split Lines", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height", ChartColumnType.Positionable),
         new ChartScriptColumn("Height 2", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 3", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 4", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 5", ChartColumnType.Positionable)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup()
         {
             new ChartScriptParameter("CompleteValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("Auto|Yes|No|FromFilters")
             },
             new ChartScriptParameter("Scale", ChartParameterType.Enum)
             {
                 ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("UnitMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 20m
                 }
             },
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberMinWidth", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 20
                 }
             },
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
         },
         new ChartScriptParameterGroup("Circle")
         {
             new ChartScriptParameter("CircleAutoReduce", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Yes|No")
             },
             new ChartScriptParameter("CircleRadius", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 5
                 }
             },
             new ChartScriptParameter("CircleStroke", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 2
                 }
             },
             new ChartScriptParameter("CircleRadiusHover", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 15
                 }
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         },
         new ChartScriptParameterGroup("Form")
         {
             new ChartScriptParameter("Interpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("linear|step-before|step-after|cardinal|monotone|basis|bundle")
             },
         }
     };
 }
 public ChartScriptEntity ChartScript(string chartScriptName)
 {
     return(ChartScriptLogic.GetChartScript(chartScriptName));
 }
Exemplo n.º 13
0
    public SvgMapScript(string[] svgMaps) : base(SvgMapsChartScript.SvgMap)
    {
        this.Icon    = ChartScriptLogic.LoadIcon("svgmap.png");
        this.Columns = new List <ChartScriptColumn>
        {
            new ChartScriptColumn("LocationCode", ChartColumnType.String),
            new ChartScriptColumn("Location", ChartColumnType.Groupable)
            {
                IsOptional = true
            },
            new ChartScriptColumn("Color Scale", ChartColumnType.Magnitude)
            {
                IsOptional = true
            },
            new ChartScriptColumn("Color Category", ChartColumnType.Groupable)
            {
                IsOptional = true
            },
            new ChartScriptColumn("Opacity", ChartColumnType.Magnitude)
            {
                IsOptional = true
            },
        };
        this.ParameterGroups = new List <ChartScriptParameterGroup>
        {
            new ChartScriptParameterGroup("Url")
            {
                new ChartScriptParameter("SvgUrl", ChartParameterType.Enum)
                {
                    ValueDefinition = EnumValueList.Parse(svgMaps.ToString("|"))
                },
            },

            new ChartScriptParameterGroup("Location")
            {
                new ChartScriptParameter("LocationSelector", ChartParameterType.String)
                {
                    ColumnIndex = 0, ValueDefinition = new StringValue("path[id]")
                },
                new ChartScriptParameter("LocationAttribute", ChartParameterType.String)
                {
                    ColumnIndex = 0, ValueDefinition = new StringValue("id")
                },
                new ChartScriptParameter("LocationMatch", ChartParameterType.Enum)
                {
                    ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("Exact|Prefix")
                },
            },

            new ChartScriptParameterGroup("Stroke")
            {
                new ChartScriptParameter("StrokeColor", ChartParameterType.String)
                {
                    ValueDefinition = new StringValue("")
                },
                new ChartScriptParameter("StrokeWidth", ChartParameterType.String)
                {
                    ValueDefinition = new StringValue("")
                },
            },

            new ChartScriptParameterGroup("Fill")
            {
                new ChartScriptParameter("NoDataColor", ChartParameterType.String)
                {
                    ValueDefinition = new StringValue("#aaa")
                },
            },

            new ChartScriptParameterGroup("Color Scale")
            {
                new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
                {
                    ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Sqrt|Log")
                },
                new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
                {
                    ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
                },
                new ChartScriptParameter("ColorScaleMaxValue", ChartParameterType.Number)
                {
                    ColumnIndex = 2, ValueDefinition = new NumberInterval {
                        DefaultValue = null
                    }
                },
            },
            new ChartScriptParameterGroup("Color Category")
            {
                new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
                {
                    ColumnIndex = 3, ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
                },
                new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
                {
                    ColumnIndex = 3, ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
                },
            }
        };
    }
Exemplo n.º 14
0
 public StackedBarsChartScript() : base(D3ChartScript.StackedBars)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("stackedbars.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Vertical Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Split Bars", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Width", ChartColumnType.Magnitude),
         new ChartScriptColumn("Width 2", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Width 3", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Width 4", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Width 5", ChartColumnType.Magnitude)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("CompleteValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("Auto|Yes|No|FromFilters")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("Labels", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Margin|Inside|None")
             },
             new ChartScriptParameter("LabelsMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 100m
                 }
             },
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
             new ChartScriptParameter("NumberColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("#fff")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         },
         new ChartScriptParameterGroup("Form")
         {
             new ChartScriptParameter("Stack", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("zero|expand|wiggle|silhouette")
             },
             new ChartScriptParameter("Order", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("none|ascending|descending|insideOut|reverse")
             },
         },
     };
 }
Exemplo n.º 15
0
 public ParallelCoordiantesChartScript() : base(D3ChartScript.ParallelCoordinates)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("parallelcoordinates.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Line", ChartColumnType.Groupable),
         new ChartScriptColumn("Dimension1", ChartColumnType.Positionable),
         new ChartScriptColumn("Dimension2", ChartColumnType.Positionable),
         new ChartScriptColumn("Dimension3", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Dimension4", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Dimension5", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Dimension6", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Dimension7", ChartColumnType.Positionable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Dimension8", ChartColumnType.Positionable)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup()
         {
             new ChartScriptParameter("Scale1", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale2", ChartParameterType.Enum)
             {
                 ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale3", ChartParameterType.Enum)
             {
                 ColumnIndex = 3, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale4", ChartParameterType.Enum)
             {
                 ColumnIndex = 4, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale5", ChartParameterType.Enum)
             {
                 ColumnIndex = 5, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale6", ChartParameterType.Enum)
             {
                 ColumnIndex = 6, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale7", ChartParameterType.Enum)
             {
                 ColumnIndex = 7, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
             new ChartScriptParameter("Scale8", ChartParameterType.Enum)
             {
                 ColumnIndex = 8, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)|Sqrt (M)")
             },
         },
         new ChartScriptParameterGroup("Color")
         {
             new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
         },
         new ChartScriptParameterGroup("Form")
         {
             new ChartScriptParameter("Interpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("linear|step-before|step-after|cardinal|monotone|basis|bundle")
             }
         },
     };
 }
Exemplo n.º 16
0
 public PunchcardChartScript() : base(D3ChartScript.Punchcard)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("punchcard.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Vertical Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Size", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Color", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Opacity", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Inner Size", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Ordering", ChartColumnType.Magnitude)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("CompleteHorizontalValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("Auto|Yes|No")
             },
             new ChartScriptParameter("CompleteVerticalValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("Auto|Yes|No")
             },
         },
         new ChartScriptParameterGroup("Size")
         {
             new ChartScriptParameter("SizeScale", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Log|Sqrt")
             },
             new ChartScriptParameter("Shape", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Circle|Rectangle|ProgressBar")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("XMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 110m
                 }
             },
             new ChartScriptParameter("HorizontalLineColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("LightGray")
             },
             new ChartScriptParameter("VerticalLineColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("LightGray")
             }
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
             new ChartScriptParameter("NumberColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("white")
             },
         },
         new ChartScriptParameterGroup("Arrange")
         {
             new ChartScriptParameter("XSort", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Ascending|AscendingKey|AscendingToStr|AscendingSumOrder|Descending|DescendingKey|DescendingToStr|DescendingSumOrder|None")
             },
             new ChartScriptParameter("YSort", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Ascending|AscendingKey|AscendingToStr|AscendingSumOrder|Descending|DescendingKey|DescendingToStr|DescendingSumOrder|None")
             },
         },
         new ChartScriptParameterGroup("Opacity")
         {
             new ChartScriptParameter("FillOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.4m
                 }
             },
         },
         new ChartScriptParameterGroup("Fill Color")
         {
             new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Sqrt|Log")
             },
             new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
             new ChartScriptParameter("FillColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("gray")
             },
         },
         new ChartScriptParameterGroup("Stroke")
         {
             new ChartScriptParameter("StrokeColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("gray")
             },
             new ChartScriptParameter("StrokeWidth", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 2m
                 }
             },
         },
         new ChartScriptParameterGroup("Opacity")
         {
             new ChartScriptParameter("OpacityScale", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Log|Sqrt")
             },
         },
         new ChartScriptParameterGroup("Inner Size")
         {
             new ChartScriptParameter("InnerSizeType", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Absolute|Relative|Independent")
             },
             new ChartScriptParameter("InnerFillColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("red")
             },
         }
     };
 }
Exemplo n.º 17
0
 public TreeMapChartScript() : base(D3ChartScript.Treemap)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("treemap.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Square", ChartColumnType.Groupable),
         new ChartScriptColumn("Size", ChartColumnType.Magnitude),
         new ChartScriptColumn("Parent", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Color Scale", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Color Category", ChartColumnType.Groupable)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("Scale", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Log")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("Padding", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 4m
                 }
             },
             new ChartScriptParameter("Opacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.5m
                 }
             },
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
             new ChartScriptParameter("NumberColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("#fff")
             },
         },
         new ChartScriptParameterGroup("Color Scale")
         {
             new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Sqrt|Log")
             },
             new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             },
         }
     };
 }
Exemplo n.º 18
0
 public StackedLinesChartScript() : base(D3ChartScript.StackedLines)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("stackedareas.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Groupable),
         new ChartScriptColumn("Areas", ChartColumnType.Groupable)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height", ChartColumnType.Magnitude),
         new ChartScriptColumn("Height 2", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 3", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 4", ChartColumnType.Magnitude)
         {
             IsOptional = true
         },
         new ChartScriptColumn("Height 5", ChartColumnType.Magnitude)
         {
             IsOptional = true
         }
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup("Scale")
         {
             new ChartScriptParameter("CompleteValues", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("Auto|Yes|No")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("Horizontal Margin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 20m
                 }
             },
         },
         new ChartScriptParameterGroup("Number")
         {
             new ChartScriptParameter("NumberOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.8m
                 }
             },
             new ChartScriptParameter("NumberColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("#fff")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             }
         },
         new ChartScriptParameterGroup("Form")
         {
             new ChartScriptParameter("Order", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("none|ascending|descending|insideOut|reverse")
             },
             new ChartScriptParameter("Stack", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("zero|expand|wiggle|silhouette")
             },
             new ChartScriptParameter("Interpolate", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("linear|step-before|step-after|cardinal|monotone|basis")
             },
         },
     };
 }
Exemplo n.º 19
0
 public BubbleplotChartScript() : base(D3ChartScript.Bubbleplot)
 {
     this.Icon    = ChartScriptLogic.LoadIcon("bubbles.png");
     this.Columns = new List <ChartScriptColumn>
     {
         new ChartScriptColumn("Color", ChartColumnType.Groupable),
         new ChartScriptColumn("Horizontal Axis", ChartColumnType.Positionable),
         new ChartScriptColumn("Vertical Axis", ChartColumnType.Positionable),
         new ChartScriptColumn("Size", ChartColumnType.Magnitude)
     };
     this.ParameterGroups = new List <ChartScriptParameterGroup>
     {
         new ChartScriptParameterGroup()
         {
             new ChartScriptParameter("HorizontalScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 1, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
             new ChartScriptParameter("VerticalScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 2, ValueDefinition = EnumValueList.Parse("ZeroMax (M)|MinMax|Log (M)")
             },
             new ChartScriptParameter("SizeScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 3, ValueDefinition = EnumValueList.Parse("ZeroMax|MinMax|Log")
             },
         },
         new ChartScriptParameterGroup("Margin")
         {
             new ChartScriptParameter("UnitMargin", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 40m
                 }
             },
             new ChartScriptParameter("TopMargin", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("0.15*")
             },
             new ChartScriptParameter("RightMargin", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("0.15*")
             },
         },
         new ChartScriptParameterGroup("Label")
         {
             new ChartScriptParameter("ShowLabel", ChartParameterType.Enum)
             {
                 ValueDefinition = EnumValueList.Parse("Yes|No")
             },
             new ChartScriptParameter("LabelColor", ChartParameterType.String)
             {
                 ValueDefinition = new StringValue("#fff")
             },
             new ChartScriptParameter("FillOpacity", ChartParameterType.Number)
             {
                 ValueDefinition = new NumberInterval {
                     DefaultValue = 0.4m
                 }
             },
         },
         new ChartScriptParameterGroup("Color Scale")
         {
             new ChartScriptParameter("ColorScale", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("Ordinal|ZeroMax|MinMax|Sqrt|Log")
             },
             new ChartScriptParameter("ColorInterpolate", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("YlGn|YlGnBu|GnBu|BuGn|PuBuGn|PuBu|BuPu|RdPu|PuRd|OrRd|YlOrRd|YlOrBr|Purples|Blues|Greens|Oranges|Reds|Greys|PuOr|BrBG|PRGn|PiYG|RdBu|RdGy|RdYlBu|Spectral|RdYlGn")
             },
         },
         new ChartScriptParameterGroup("Color Category")
         {
             new ChartScriptParameter("ColorCategory", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("category10|accent|dark2|paired|pastel1|pastel2|set1|set2|set3|BrBG[K]|PRGn[K]|PiYG[K]|PuOr[K]|RdBu[K]|RdGy[K]|RdYlBu[K]|RdYlGn[K]|Spectral[K]|Blues[K]|Greys[K]|Oranges[K]|Purples[K]|Reds[K]|BuGn[K]|BuPu[K]|OrRd[K]|PuBuGn[K]|PuBu[K]|PuRd[K]|RdPu[K]|YlGnBu[K]|YlGn[K]|YlOrBr[K]|YlOrRd[K]")
             },
             new ChartScriptParameter("ColorCategorySteps", ChartParameterType.Enum)
             {
                 ColumnIndex = 0, ValueDefinition = EnumValueList.Parse("3|4|5|6|7|8|9|10|11")
             },
         }
     };
 }