// GET: Customization public ActionResult GaugeCustomization() { List <CircularGaugeAnnotation> annotations = new List <CircularGaugeAnnotation>(); CircularGaugeAnnotation annotation1 = new CircularGaugeAnnotation(); annotation1.Content = "<div style=color:#666666;font-size:35px;>1800</div"; annotation1.Radius = "110%"; annotation1.Angle = 0; annotation1.ZIndex = "1"; annotations.Add(annotation1); ViewBag.Annotations = annotations; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 1000; range1.End = 2000; range1.StartWidth = "30"; range1.EndWidth = "30"; range1.Radius = "90%"; range1.Color = "#E0E0E0"; ranges.Add(range1); ViewBag.Ranges = ranges; // Pointers // List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.Type = PointerType.RangeBar; pointer1.Value = 1800; pointer1.Radius = "90%"; pointer1.Color = "#FFDD00"; pointer1.Animation = new CircularGaugeAnimation { Duration = 0 }; pointer1.PointerWidth = 30; pointers.Add(pointer1); CircularGaugePointer pointer2 = new CircularGaugePointer(); pointer2.Value = 1800; pointer2.Radius = "90%"; pointer2.Color = "#424242"; pointer2.Animation = new CircularGaugeAnimation { Duration = 0 }; pointer2.PointerWidth = 9; pointer2.Cap = new CircularGaugeCap { Radius = 10, Color = "#424242", Border = new CircularGaugeBorder { Width = 0 } }; pointers.Add(pointer2); ViewBag.Pointers = pointers; return(View()); }
// GET: Default public ActionResult Export() { // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 32; range1.Radius = "90%"; range1.StartWidth = "10"; range1.EndWidth = "35"; range1.Color = "#F8A197"; ranges.Add(range1); CircularGaugeRange range2 = new CircularGaugeRange(); range2.Start = 32; range2.End = 70; range2.Radius = "90%"; range2.StartWidth = "10"; range2.EndWidth = "35"; range2.Color = "#C45072"; ranges.Add(range2); CircularGaugeRange range3 = new CircularGaugeRange(); range3.Start = 70; range3.End = 100; range3.Radius = "90%"; range3.StartWidth = "10"; range3.EndWidth = "35"; range3.Color = "#1B679F"; ranges.Add(range3); ViewBag.Ranges = ranges; List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); ViewBag.Pointers = pointers; ViewBag.labelFont = new CircularGaugeFont { FontFamily = "Roboto", Size = "12px", Opacity = 1, FontWeight = "Regular" }; ViewBag.format = new string[] { "JPEG", "PNG", "SVG", "PDF" }; return(View()); }
// GET: Campass public ActionResult DirectionCompass() { // Pointers // List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.Value = 7; pointer1.Radius = "50%"; pointer1.Color = "#f03e3e"; pointer1.PointerWidth = 20; pointer1.Cap = new CircularGaugeCap { Radius = 0 }; pointer1.Animation = new CircularGaugeAnimation { Enable = false }; pointers.Add(pointer1); CircularGaugePointer pointer2 = new CircularGaugePointer(); pointer2.Value = 3; pointer2.Radius = "50%"; pointer2.Color = "#9E9E9E"; pointer2.PointerWidth = 20; pointer2.Cap = new CircularGaugeCap { Radius = 0 }; pointer2.Animation = new CircularGaugeAnimation { Enable = false }; pointers.Add(pointer2); ViewBag.Pointers = pointers; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 7; range1.End = 7; range1.Color = "#f03e3e"; ranges.Add(range1); ViewBag.Ranges = ranges; return(View()); }
// GET: Campass public ActionResult GradientColor() { // Pointers // List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.Value = 65; pointer1.Radius = "85%"; pointer1.Color = "#E63B86"; pointer1.PointerWidth = 12; pointer1.NeedleStartWidth = 2; pointer1.Cap = new CircularGaugeCap { Radius = 12, Border = new CircularGaugeBorder { Width = 2.5, Color = "#E63B86" }, Color = "white" }; pointer1.NeedleStartWidth = 2; pointer1.NeedleTail = new CircularGaugeNeedleTail { Length = "0%" }; pointer1.Animation = new CircularGaugeAnimation { Enable = false }; pointers.Add(pointer1); ViewBag.Pointers = pointers; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 120; range1.StartWidth = "18"; range1.EndWidth = "18"; range1.Color = "#E63B86"; range1.RoundedCornerRadius = 10; ranges.Add(range1); ViewBag.Ranges = ranges; return(View()); }
// GET: Ticks public ActionResult TicksAndLabels() { List <CircularGaugeAnnotation> annotations = new List <CircularGaugeAnnotation>(); CircularGaugeAnnotation annotation1 = new CircularGaugeAnnotation(); annotation1.Content = "<div id=content style=color:#518C03;font-size:20px;font-family:Segoe UI;font-weight:semibold;>145</div>"; annotation1.Radius = "0%"; annotation1.Angle = 0; annotation1.ZIndex = "1"; annotations.Add(annotation1); ViewBag.Annotations = annotations; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 145; range1.Radius = "60%"; range1.Color = "#8BC34A"; ranges.Add(range1); ViewBag.Ranges = ranges; // Pointers // List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.PointerWidth = 0; pointer1.NeedleTail = new CircularGaugeNeedleTail { Color = "transparent", Length = "0%" }; ViewBag.Pointers = pointers; return(View()); }
// GET: Range public ActionResult Range() { // Annotations // List <CircularGaugeAnnotation> annotations = new List <CircularGaugeAnnotation>(); CircularGaugeAnnotation annotation1 = new CircularGaugeAnnotation(); annotation1.Content = "<div><span style=font-size:14px; color:#9E9E9E; font-family:Regular>Speedometer</span></div>"; annotation1.Radius = "30%"; annotation1.Angle = 0; annotation1.ZIndex = "1"; annotations.Add(annotation1); CircularGaugeAnnotation annotation2 = new CircularGaugeAnnotation(); annotation2.Content = "<div><span style=font-size:20px; color:#424242; font-family:Regular>65 MPH</span></div>"; annotation2.Radius = "40%"; annotation2.Angle = 180; annotation2.ZIndex = "1"; annotations.Add(annotation2); ViewBag.Annotations = annotations; //Pointers // List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.Value = 65; pointer1.Radius = "60%"; pointer1.PointerWidth = 8; pointer1.Cap = new CircularGaugeCap { Radius = 7 }; pointer1.NeedleTail = new CircularGaugeNeedleTail { Length = "18%" }; pointers.Add(pointer1); ViewBag.Pointers = pointers; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 40; range1.Color = "#30B32D"; ranges.Add(range1); CircularGaugeRange range2 = new CircularGaugeRange(); range2.Start = 40; range2.End = 80; range2.Color = "#FFDD00"; ranges.Add(range2); CircularGaugeRange range3 = new CircularGaugeRange(); range3.Start = 80; range3.End = 120; range3.Color = "#F03E3E"; ranges.Add(range3); ViewBag.Ranges = ranges; return(View()); }
// GET: Annotation public ActionResult Annotation() { // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 3; range1.Color = "rgba(29,29,29,0.6)"; ranges.Add(range1); CircularGaugeRange range2 = new CircularGaugeRange(); range2.Start = 3; range2.End = 12; range2.Color = "rgba(226, 226, 226, 0.6)"; ranges.Add(range2); ViewBag.Ranges = ranges; // Pointers // List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); CircularGaugeBorder border = new CircularGaugeBorder(); border.Color = "#679EEF"; border.Width = 0; pointer1.PointerWidth = 5; pointer1.Radius = "40%"; pointer1.Color = "rgba(29,29,29,0.8)"; pointer1.Border = new CircularGaugeBorder { Color = "#679EEF", Width = 0 }; pointer1.Cap = new CircularGaugeCap { Radius = 0, Border = new CircularGaugeBorder { Width = 0, Color = "red" } }; pointer1.NeedleTail = new CircularGaugeNeedleTail { Length = "0%" }; pointer1.Animation = new CircularGaugeAnimation { Enable = false }; pointers.Add(pointer1); CircularGaugePointer pointer2 = new CircularGaugePointer(); pointer2.Radius = "60%"; pointer2.PointerWidth = 5; pointer2.Color = "rgba(29,29,29,0.8)"; pointer2.Border = new CircularGaugeBorder { Width = 0, Color = "rgba(29,29,29,0.8)" }; pointer2.Cap = new CircularGaugeCap { Color = "rgba(29,29,29,0.8)", Radius = 0, Border = new CircularGaugeBorder { Width = 0, Color = "red" } }; pointer2.NeedleTail = new CircularGaugeNeedleTail { Length = "0%" }; pointer2.Animation = new CircularGaugeAnimation { Enable = false }; pointers.Add(pointer2); CircularGaugePointer pointer3 = new CircularGaugePointer(); pointer3.Radius = "70%"; pointer3.PointerWidth = 1; pointer3.Color = "rgba(29,29,29,0.8)"; pointer3.Border = new CircularGaugeBorder { Width = 2, Color = "rgba(29,29,29,0.8)" }; pointer3.Cap = new CircularGaugeCap { Color = "white", Radius = 4, Border = new CircularGaugeBorder { Width = 2, Color = "rgba(29,29,29,0.8)" } }; pointer3.NeedleTail = new CircularGaugeNeedleTail { Length = "20%", Color = "rgba(29,29,29,0.8)", Border = new CircularGaugeBorder { Width = 2, Color = "rgba(29,29,29,0.8)" } }; pointer3.Animation = new CircularGaugeAnimation { Enable = false, Duration = 500 }; pointers.Add(pointer3); ViewBag.Pointers = pointers; return(View()); }
// GET: Image public ActionResult PointerImage() { // Annotations // List <CircularGaugeAnnotation> annotations = new List <CircularGaugeAnnotation>(); CircularGaugeAnnotation annotation1 = new CircularGaugeAnnotation(); annotation1.Content = "12 M"; annotation1.Radius = "108%"; annotation1.Angle = 98; annotation1.ZIndex = "1"; annotations.Add(annotation1); CircularGaugeAnnotation annotation2 = new CircularGaugeAnnotation(); annotation2.Content = "11 M"; annotation2.Radius = "80%"; annotation2.Angle = 81; annotation2.ZIndex = "1"; annotations.Add(annotation2); CircularGaugeAnnotation annotation3 = new CircularGaugeAnnotation(); annotation3.Content = "10 M"; annotation3.Radius = "50%"; annotation3.Angle = 69; annotation3.ZIndex = "1"; annotations.Add(annotation3); CircularGaugeAnnotation annotation4 = new CircularGaugeAnnotation(); annotation4.Content = "Doe"; annotation4.Radius = "108%"; annotation4.Angle = 190; annotation4.ZIndex = "1"; annotations.Add(annotation4); CircularGaugeAnnotation annotation5 = new CircularGaugeAnnotation(); annotation5.Content = "Almaida"; annotation5.Radius = "80%"; annotation5.Angle = 185; annotation5.ZIndex = "1"; annotations.Add(annotation5); CircularGaugeAnnotation annotation6 = new CircularGaugeAnnotation(); annotation6.Content = "John"; annotation6.Radius = "50%"; annotation6.Angle = 180; annotation6.ZIndex = "1"; annotations.Add(annotation6); ViewBag.Annotations = annotations; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 12; range1.Radius = "115%"; range1.Color = "#01aebe"; range1.StartWidth = "25"; range1.EndWidth = "25"; ranges.Add(range1); CircularGaugeRange range2 = new CircularGaugeRange(); range2.Start = 0; range2.End = 11; range2.Radius = "85%"; range2.Color = "#3bceac"; range2.StartWidth = "25"; range2.EndWidth = "25"; ranges.Add(range2); CircularGaugeRange range3 = new CircularGaugeRange(); range3.Start = 0; range3.End = 10; range3.Radius = "55%"; range3.Color = "#ee4266"; range3.StartWidth = "25"; range3.EndWidth = "25"; ranges.Add(range3); ViewBag.Ranges = ranges; return(View()); }
// GET: AppleWatchRings public ActionResult AppleWatchRings() { ViewBag.Font = new CircularGaugeFont { FontFamily = "Roboto", Size = "0px", Color = "white", FontStyle = "Regular" }; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 100; range1.Radius = "90%"; range1.StartWidth = "40"; range1.EndWidth = "40"; range1.Color = "#E30219"; range1.Opacity = 0.2; ranges.Add(range1); CircularGaugeRange range2 = new CircularGaugeRange(); range2.Start = 0; range2.End = 100; range2.Radius = "68%"; range2.StartWidth = "40"; range2.EndWidth = "40"; range2.Color = "#3EDE00"; range2.Opacity = 0.2; ranges.Add(range2); CircularGaugeRange range3 = new CircularGaugeRange(); range3.Start = 0; range3.End = 100; range3.Radius = "46%"; range3.StartWidth = "40"; range3.EndWidth = "40"; range3.Color = "#18F8F6"; range3.Opacity = 0.2; ranges.Add(range3); ViewBag.Ranges = ranges; List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.RoundedCornerRadius = 25; pointer1.Value = 65; pointer1.Type = PointerType.RangeBar; pointer1.Radius = "90%"; pointer1.Color = "#E2011A"; pointer1.Animation = new CircularGaugeAnimation { Enable = true }; pointer1.PointerWidth = 40; pointers.Add(pointer1); CircularGaugePointer pointer2 = new CircularGaugePointer(); pointer2.RoundedCornerRadius = 25; pointer2.Value = 43; pointer2.Type = PointerType.RangeBar; pointer2.Radius = "68%"; pointer2.Color = "#3FE000"; pointer2.Animation = new CircularGaugeAnimation { Enable = true }; pointer2.PointerWidth = 40; pointers.Add(pointer2); CircularGaugePointer pointer3 = new CircularGaugePointer(); pointer3.RoundedCornerRadius = 25; pointer3.Value = 58; pointer3.Type = PointerType.RangeBar; pointer3.Radius = "46%"; pointer3.Color = "#00C9E6"; pointer3.Animation = new CircularGaugeAnimation { Enable = true }; pointer3.PointerWidth = 40; pointers.Add(pointer3); ViewBag.Pointers = pointers; return(View()); }
// GET: Legend public ActionResult Legend() { List <CircularGaugePointer> pointers = new List <CircularGaugePointer>(); CircularGaugePointer pointer1 = new CircularGaugePointer(); pointer1.Value = 70; pointer1.Radius = "60%"; pointer1.PointerWidth = 8; pointer1.Cap = new CircularGaugeCap { Radius = 7 }; pointer1.NeedleTail = new CircularGaugeNeedleTail { Length = "18%" }; pointers.Add(pointer1); ViewBag.Pointers = pointers; // Ranges // List <CircularGaugeRange> ranges = new List <CircularGaugeRange>(); CircularGaugeRange range1 = new CircularGaugeRange(); range1.Start = 0; range1.End = 5; range1.Color = "#ccffff"; range1.Radius = "110%"; range1.LegendText = "Light air"; ranges.Add(range1); CircularGaugeRange range2 = new CircularGaugeRange(); range2.Start = 5; range2.End = 11; range2.Color = "#99ffff"; range2.Radius = "110%"; range2.LegendText = "Light breeze"; ranges.Add(range2); CircularGaugeRange range3 = new CircularGaugeRange(); range3.Start = 11; range3.End = 19; range3.Color = "#99ff99"; range3.Radius = "110%"; range3.LegendText = "Gentle breeze"; ranges.Add(range3); CircularGaugeRange range4 = new CircularGaugeRange(); range4.Start = 19; range4.End = 28; range4.Color = "#79ff4d"; range4.Radius = "110%"; range4.LegendText = "Moderate breeze"; ranges.Add(range4); CircularGaugeRange range5 = new CircularGaugeRange(); range5.Start = 28; range5.End = 49; range5.Color = "#c6ff1a"; range5.Radius = "110%"; range5.LegendText = "Strong breeze"; ranges.Add(range5); CircularGaugeRange range6 = new CircularGaugeRange(); range6.Start = 49; range6.End = 74; range6.Color = "#e6ac00"; range6.Radius = "110%"; range6.LegendText = "Gale"; ranges.Add(range6); CircularGaugeRange range7 = new CircularGaugeRange(); range7.Start = 74; range7.End = 102; range7.Color = "#ff6600"; range7.Radius = "110%"; range7.LegendText = "Storm"; ranges.Add(range7); CircularGaugeRange range8 = new CircularGaugeRange(); range8.Start = 102; range8.End = 120; range8.Color = "#ff0000"; range8.Radius = "110%"; range8.LegendText = "Hurricane force"; ranges.Add(range8); ViewBag.Ranges = ranges; return(View()); }