Exemple #1
0
        void AddBarSeries(NChart chart, MultiBarMode mode)
        {
            NBarSeries bar = (NBarSeries)chart.Series.Add(SeriesType.Bar);

            bar.MultiBarMode           = mode;
            bar.UseXValues             = true;
            bar.UseZValues             = true;
            bar.DataLabelStyle.Visible = false;
            bar.InflateMargins         = true;
        }
        void AddBarSeries(NChart chart, MultiBarMode mode, string name)
        {
            NBarSeries bar = (NBarSeries)chart.Series.Add(SeriesType.Bar);

            bar.Name                              = name;
            bar.MultiBarMode                      = mode;
            bar.UseXValues                        = true;
            bar.UseZValues                        = true;
            bar.DataLabelStyle.Visible            = false;
            bar.InflateMargins                    = true;
            bar.Legend.TextStyle.FontStyle.EmSize = new NLength(8, NGraphicsUnit.Point);
        }
        private NBarSeries AddSeries(MultiBarMode mode, Color color, int alpha)
        {
            seriesId++;

            NBarSeries bar = (NBarSeries)m_Chart.Series.Add(SeriesType.Bar);

            bar.Name = "Bar " + seriesId.ToString();
            bar.DataLabelStyle.Visible = false;
            bar.Legend.Mode            = SeriesLegendMode.Series;
            bar.FillStyle         = new NColorFillStyle(Color.FromArgb(alpha, color));
            bar.BorderStyle.Width = new NLength(0);
            bar.Values.FillRandom(Random, 7);
            bar.MultiBarMode = mode;

            return(bar);
        }