Exemplo n.º 1
0
        /// <summary>
        /// Default constructor
        /// </summary>
        /// <param name="chartSeries">Parent collection</param>
        /// <param name="ns">Namespacemanager</param>
        /// <param name="node">Topnode</param>
       /// <param name="isPivot">Is pivotchart</param>
       internal ExcelChartSerie(ExcelChartSeries chartSeries, XmlNamespaceManager ns, XmlNode node, bool isPivot)
           : base(ns,node)
       {
           _chartSeries = chartSeries;
           _node=node;
           _ns=ns;
           SchemaNodeOrder = new string[] { "idx", "order", "tx", "marker","trendline", "explosion", "dLbls", "cat", "val", "yVal","xVal", "smooth" };

           if (chartSeries.Chart.ChartType == eChartType.XYScatter ||
               chartSeries.Chart.ChartType == eChartType.XYScatterLines ||
               chartSeries.Chart.ChartType == eChartType.XYScatterLinesNoMarkers ||
               chartSeries.Chart.ChartType == eChartType.XYScatterSmooth ||
               chartSeries.Chart.ChartType == eChartType.XYScatterSmoothNoMarkers)
           {
               _seriesTopPath = "c:yVal";
               _xSeriesTopPath = "c:xVal";
           }
           else
           {
               _seriesTopPath = "c:val";
               _xSeriesTopPath = "c:cat";
           }
           _seriesPath = string.Format(_seriesPath, _seriesTopPath);
           _xSeriesPath = string.Format(_xSeriesPath, _xSeriesTopPath, isPivot ? "c:multiLvlStrRef" : "c:numRef");
       }
Exemplo n.º 2
0
        /// <summary>
        /// Default constructor
        /// </summary>
        /// <param name="chartSeries">Parent collection</param>
        /// <param name="ns">Namespacemanager</param>
        /// <param name="node">Topnode</param>
        /// <param name="isPivot">Is pivotchart</param>
        internal ExcelChartSerie(ExcelChartSeries chartSeries, XmlNamespaceManager ns, XmlNode node, bool isPivot)
            : base(ns, node)
        {
            _chartSeries    = chartSeries;
            _node           = node;
            _ns             = ns;
            SchemaNodeOrder = new string[] { "idx", "order", "tx", "marker", "trendline", "explosion", "dLbls", "cat", "val", "yVal", "xVal", "smooth" };

            if (chartSeries.Chart.ChartType == eChartType.XYScatter ||
                chartSeries.Chart.ChartType == eChartType.XYScatterLines ||
                chartSeries.Chart.ChartType == eChartType.XYScatterLinesNoMarkers ||
                chartSeries.Chart.ChartType == eChartType.XYScatterSmooth ||
                chartSeries.Chart.ChartType == eChartType.XYScatterSmoothNoMarkers)
            {
                _seriesTopPath  = "c:yVal";
                _xSeriesTopPath = "c:xVal";
            }
            else
            {
                _seriesTopPath  = "c:val";
                _xSeriesTopPath = "c:cat";
            }
            _seriesPath  = string.Format(_seriesPath, _seriesTopPath);
            _xSeriesPath = string.Format(_xSeriesPath, _xSeriesTopPath, isPivot ? "c:multiLvlStrRef" : "c:numRef");
        }
Exemplo n.º 3
0
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="chartSeries">Parent collection</param>
 /// <param name="ns">Namespacemanager</param>
 /// <param name="node">Topnode</param>
 /// <param name="isPivot">Is pivotchart</param>
 internal ExcelScatterChartSerie(ExcelChartSeries chartSeries, XmlNamespaceManager ns, XmlNode node, bool isPivot) :
     base(chartSeries, ns, node, isPivot)
 {
     if (chartSeries.Chart.ChartType == eChartType.XYScatterLines ||
         chartSeries.Chart.ChartType == eChartType.XYScatterSmooth)
     {
         Marker = eMarkerStyle.Square;
     }
 }
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="chartSeries">Parent collection</param>
 /// <param name="ns">Namespacemanager</param>
 /// <param name="node">Topnode</param>
 /// <param name="isPivot">Is pivotchart</param>
 internal ExcelScatterChartSerie(ExcelChartSeries chartSeries, XmlNamespaceManager ns, XmlNode node, bool isPivot) :
     base(chartSeries, ns, node, isPivot)
 {
     if (chartSeries.Chart.ChartType == eChartType.XYScatterLines ||
         chartSeries.Chart.ChartType == eChartType.XYScatterSmooth)
     {
         Marker = eMarkerStyle.Square;
     }
 }
Exemplo n.º 5
0
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="chartSeries">Parent collection</param>
 /// <param name="ns">Namespacemanager</param>
 /// <param name="node">Topnode</param>
 /// <param name="isPivot">Is pivotchart</param>
 internal ExcelLineChartSerie(ExcelChartSeries chartSeries, XmlNamespaceManager ns, XmlNode node, bool isPivot) :
     base(chartSeries, ns, node, isPivot)
 {
 }
        /// <summary>
        /// Default constructor
        /// </summary>
        /// <param name="chartSeries">Parent collection</param>
        /// <param name="ns">Namespacemanager</param>
        /// <param name="node">Topnode</param>
        /// <param name="isPivot">Is pivotchart</param>
        internal ExcelPieChartSerie(ExcelChartSeries chartSeries, XmlNamespaceManager ns, XmlNode node, bool isPivot) :
            base(chartSeries, ns, node, isPivot)
        {

        }
Exemplo n.º 7
0
 private void InitChartLoad(ExcelDrawings drawings, XmlNode chartNode)
 {
     //SetChartType();
     bool isPivot = false;
     Init(drawings, chartNode);
     _chartSeries = new ExcelChartSeries(this, drawings.NameSpaceManager, _chartNode, isPivot /*ChartXml.SelectSingleNode(_chartPath, drawings.NameSpaceManager)*/);
     LoadAxis();
 }
Exemplo n.º 8
0
       internal ExcelChart(ExcelDrawings drawings, XmlNode node, eChartType type, ExcelChart topChart, ExcelPivotTable PivotTableSource) :
           base(drawings, node, "xdr:graphicFrame/xdr:nvGraphicFramePr/xdr:cNvPr/@name")
       {
           ChartType = type;
           CreateNewChart(drawings, type, topChart);

           Init(drawings, _chartNode);

           _chartSeries = new ExcelChartSeries(this, drawings.NameSpaceManager, _chartNode, PivotTableSource!=null);
           if (PivotTableSource != null) SetPivotSource(PivotTableSource);

           SetTypeProperties(drawings);
           if (topChart == null)
               LoadAxis();
           else
           {
               _axis = topChart.Axis;
               if (_axis.Length > 0)
               {
                   XAxis = _axis[0];
                   YAxis = _axis[1];
               }
           }
       }
Exemplo n.º 9
0
       internal ExcelChart(ExcelDrawings drawings, XmlNode node, eChartType type, bool isPivot) :
           base(drawings, node, "xdr:graphicFrame/xdr:nvGraphicFramePr/xdr:cNvPr/@name")
       {
           ChartType = type;
           CreateNewChart(drawings, type, null);

           Init(drawings, _chartNode);

           _chartSeries = new ExcelChartSeries(this, drawings.NameSpaceManager, _chartNode, isPivot);

           SetTypeProperties(drawings);
           LoadAxis();
       }