Exemple #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="dataPoint"></param>
        /// <param name="property"></param>
        /// <param name="newValue"></param>
        /// <param name="isAxisChanged"></param>
        private static void UpdateDataPoint(DataPoint dataPoint, VcProperties property, object newValue, Boolean isAxisChanged)
        {
            Chart       chart            = dataPoint.Chart as Chart;
            PlotDetails plotDetails      = chart.PlotDetails;
            Marker      marker           = dataPoint.Marker;
            DataSeries  dataSeries       = dataPoint.Parent;
            Canvas      bubleChartCanvas = dataSeries.Faces.Visual as Canvas;

            Double plotHeight = chart.ChartArea.ChartVisualCanvas.Height;
            Double plotWidth = chart.ChartArea.ChartVisualCanvas.Width;
            Double minimumZVal, maximumZVal;

            ColumnChart.UpdateParentVisualCanvasSize(chart, bubleChartCanvas);

            if (property == VcProperties.Enabled)
            {
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                CalculateMaxAndMinZValue(dataPoint.Parent, out minimumZVal, out maximumZVal);
                CreateOrUpdateAPointDataPoint(bubleChartCanvas, dataPoint, minimumZVal, maximumZVal, plotWidth, plotHeight);
                return;
            }

            if (dataPoint.Faces == null)
            {
                return;
            }

            Grid bubbleVisual = dataPoint.Faces.Visual as Grid;

            switch (property)
            {
            case VcProperties.Bevel:
                break;

            case VcProperties.Cursor:
                break;

            case VcProperties.Href:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.HrefTarget:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.LabelBackground:
                if (marker != null)
                {
                    marker.TextBackground = dataPoint.LabelBackground;
                }
                break;

            case VcProperties.LabelEnabled:
                CalculateMaxAndMinZValue(dataPoint.Parent, out minimumZVal, out maximumZVal);
                CreateOrUpdateAPointDataPoint(bubleChartCanvas, dataPoint, minimumZVal, maximumZVal, plotWidth, plotHeight);

                //if (marker != null)
                //    marker.LabelEnabled = (Boolean)dataPoint.LabelEnabled;

                break;

            case VcProperties.LabelFontColor:
                if (marker != null)
                {
                    marker.FontColor = dataPoint.LabelFontColor;
                }

                break;

            case VcProperties.LabelFontFamily:
                if (marker != null)
                {
                    marker.FontFamily = dataPoint.LabelFontFamily;
                }
                break;

            case VcProperties.LabelFontStyle:
                if (marker != null)
                {
                    marker.FontStyle = (FontStyle)dataPoint.LabelFontStyle;
                }
                break;

            //case VcProperties.LabelFontSize:
            //    if (marker != null)
            //        marker.FontSize = (Double)dataPoint.LabelFontSize;
            //    break;

            case VcProperties.LabelFontWeight:
                if (marker != null)
                {
                    marker.FontWeight = (FontWeight)dataPoint.LabelFontWeight;
                }
                break;

            case VcProperties.LabelAngle:
                if (marker != null)
                {
                    marker.FontWeight = (FontWeight)dataPoint.LabelFontWeight;
                }
                break;

            case VcProperties.LegendText:
                chart.InvokeRender();
                break;

            case VcProperties.Color:
            case VcProperties.LightingEnabled:
                if (marker != null)
                {
                    marker.MarkerShape.Fill = (chart.View3D ? Graphics.Get3DBrushLighting(dataPoint.Color, (Boolean)dataPoint.LightingEnabled) : ((Boolean)dataPoint.LightingEnabled ? Graphics.GetLightingEnabledBrush(dataPoint.Color, "Linear", null) : dataPoint.Color));
                }
                break;

            case VcProperties.MarkerBorderColor:
                if (marker != null)
                {
                    marker.BorderColor = dataPoint.MarkerBorderColor;
                }
                break;

            case VcProperties.MarkerBorderThickness:
                if (marker != null)
                {
                    marker.BorderThickness = dataPoint.MarkerBorderThickness.Value.Left;
                }
                break;

            case VcProperties.XValueFormatString:
            case VcProperties.YValueFormatString:
            case VcProperties.LabelFontSize:
            case VcProperties.LabelStyle:
            case VcProperties.LabelText:
            case VcProperties.MarkerScale:
            case VcProperties.MarkerSize:
            case VcProperties.MarkerType:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                CalculateMaxAndMinZValue(dataPoint.Parent, out minimumZVal, out maximumZVal);
                CreateOrUpdateAPointDataPoint(bubleChartCanvas, dataPoint, minimumZVal, maximumZVal, plotWidth, plotHeight);
                break;

            case VcProperties.ShadowEnabled:
                if (marker != null)
                {
                    marker.ShadowEnabled = (Boolean)dataPoint.ShadowEnabled;
                    marker.ApplyRemoveShadow();
                }
                break;

            case VcProperties.Opacity:
                if (marker != null)
                {
                    marker.Visual.Opacity = dataPoint.Opacity * dataSeries.Opacity;
                }
                break;

            case VcProperties.ShowInLegend:
                chart.InvokeRender();
                break;

            case VcProperties.ToolTipText:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                break;

            case VcProperties.XValueType:
                chart.InvokeRender();
                break;

            case VcProperties.XValue:
            case VcProperties.YValue:

                if (isAxisChanged)
                {
                    UpdateDataSeries(dataSeries, property, newValue, false);
                }
                else
                if (marker != null)
                {
                    dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);

                    if ((Boolean)dataPoint.LabelEnabled)
                    {
                        marker.Text = dataPoint.TextParser(dataPoint.LabelText);
                    }

                    UpdateBubblePositionAccording2XandYValue(dataPoint, plotWidth, plotHeight, chart.AnimatedUpdate, marker.MarkerShape.Width, marker.MarkerShape.Width);
                }

                break;

            case VcProperties.ZValue:

                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);

                //if ((Boolean)dataPoint.LabelEnabled)
                //    marker.Text = dataPoint.TextParser(dataPoint.LabelText);

                CalculateMaxAndMinZValue(dataPoint.Parent, out minimumZVal, out maximumZVal);

                foreach (DataPoint dp in dataSeries.InternalDataPoints)
                {
                    if (Double.IsNaN(dp.InternalYValue) || (dp.Enabled == false))
                    {
                        continue;
                    }

                    ApplyZValue(dp, minimumZVal, maximumZVal, plotWidth, plotHeight);
                }

                break;
            }


            if (bubleChartCanvas.Parent != null)
            {
                RectangleGeometry clipRectangle = new RectangleGeometry();
                clipRectangle.Rect = new Rect(0, -(dataPoint.Chart as Chart).ChartArea.PLANK_DEPTH, plotWidth + (dataPoint.Chart as Chart).ChartArea.PLANK_OFFSET, plotHeight + (dataPoint.Chart as Chart).ChartArea.PLANK_DEPTH);
                (bubleChartCanvas.Parent as Canvas).Clip = clipRectangle;
            }
        }
Exemple #2
0
        private static void UpdateDataPoint(DataPoint dataPoint, VcProperties property, object newValue, Boolean isAxisChanged)
        {
            Chart      chart      = dataPoint.Chart as Chart;
            DataSeries dataSeries = dataPoint.Parent;
            PlotGroup  plotGroup  = dataSeries.PlotGroup;
            Faces      dsFaces    = dataSeries.Faces;
            Faces      dpFaces    = dataPoint.Faces;

            Double dataPointWidth;

            if (dsFaces != null)
            {
                ColumnChart.UpdateParentVisualCanvasSize(chart, dsFaces.Visual as Canvas);
            }

            if (dpFaces != null && dpFaces.Visual != null)
            {
                dataPointWidth = dpFaces.Visual.Width;
            }
            else if (dsFaces == null)
            {
                return;
            }
            else
            {
                dataPointWidth = CandleStick.CalculateDataPointWidth(dsFaces.Visual.Width, dsFaces.Visual.Height, chart);
            }

            if (property == VcProperties.Enabled)
            {
                CreateOrUpdateAStockDataPoint(dataPoint, dsFaces.Visual as Canvas, dsFaces.LabelCanvas, dsFaces.Visual.Width, dsFaces.Visual.Height, dataPointWidth);
                return;
            }

            if (dpFaces == null)
            {
                return;
            }

            Canvas dataPointVisual = dpFaces.Visual as Canvas;            // DataPoint visual canvas
            Line   highLowLine     = dpFaces.VisualComponents[0] as Line; // HighLowline
            Line   closeLine       = dpFaces.VisualComponents[1] as Line; // Closeline
            Line   openLine        = dpFaces.VisualComponents[2] as Line; // Openline

            switch (property)
            {
            case VcProperties.BorderThickness:
            case VcProperties.BorderStyle:
                ApplyBorderProperties(dataPoint, highLowLine, openLine, closeLine, dataPointWidth);
                break;

            case VcProperties.Color:
                ApplyOrUpdateColorForAStockDp(dataPoint, highLowLine, openLine, closeLine);
                break;

            case VcProperties.Cursor:
                dataPoint.SetCursor2DataPointVisualFaces();
                break;

            case VcProperties.Href:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.HrefTarget:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.LabelBackground:
            case VcProperties.LabelEnabled:
            case VcProperties.LabelFontColor:
            case VcProperties.LabelFontFamily:
            case VcProperties.LabelFontStyle:
            case VcProperties.LabelFontSize:
            case VcProperties.LabelFontWeight:
            case VcProperties.LabelStyle:
            case VcProperties.LabelText:
                CandleStick.CreateAndPositionLabel(dsFaces.LabelCanvas, dataPoint);
                break;

            case VcProperties.LegendText:
                chart.InvokeRender();
                break;

            case VcProperties.LightingEnabled:
                ApplyOrUpdateColorForAStockDp(dataPoint, highLowLine, openLine, closeLine);
                break;

            //case VcProperties.MarkerBorderColor:
            //case VcProperties.MarkerBorderThickness:
            //case VcProperties.MarkerColor:
            //case VcProperties.MarkerEnabled:
            //case VcProperties.MarkerScale:
            //case VcProperties.MarkerSize:
            //case VcProperties.MarkerType:
            case VcProperties.ShadowEnabled:
                ApplyOrUpdateShadow(dataPoint, dataPointVisual, highLowLine, openLine, closeLine, dataPointWidth);
                break;

            case VcProperties.Opacity:
                dpFaces.Visual.Opacity = dataSeries.Opacity * dataPoint.Opacity;
                break;

            case VcProperties.ShowInLegend:
                chart.InvokeRender();
                break;

            case VcProperties.ToolTipText:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                break;

            case VcProperties.XValueFormatString:
            case VcProperties.YValueFormatString:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                CandleStick.CreateAndPositionLabel(dsFaces.LabelCanvas, dataPoint);
                break;

            case VcProperties.XValueType:
                chart.InvokeRender();
                break;

            case VcProperties.Enabled:
                CreateOrUpdateAStockDataPoint(dataPoint, dsFaces.Visual as Canvas, dsFaces.LabelCanvas, dsFaces.Visual.Width, dsFaces.Visual.Height, dataPointWidth);
                break;

            case VcProperties.XValue:
            case VcProperties.YValues:
                if (isAxisChanged)
                {
                    UpdateDataSeries(dataSeries, property, newValue, isAxisChanged);
                }
                else
                {
                    dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                    UpdateYValueAndXValuePosition(dataPoint, dsFaces.Visual.Width, dsFaces.Visual.Height, dpFaces.Visual.Width);

                    if ((Boolean)dataPoint.LabelEnabled)
                    {
                        CandleStick.CreateAndPositionLabel(dsFaces.LabelCanvas, dataPoint);
                    }
                }

                if (dataPoint.Parent.SelectionEnabled && dataPoint.Selected)
                {
                    dataPoint.Select(true);
                }

                break;
            }
        }
Exemple #3
0
        //internal static void Update(Chart chart, RenderAs currentRenderAs, List<DataSeries> selectedDataSeries4Rendering, VcProperties property, object newValue)
        //{
        //    Boolean is3D = chart.View3D;
        //    ChartArea chartArea = chart.ChartArea;
        //    Canvas ChartVisualCanvas = chart.ChartArea.ChartVisualCanvas;

        //    // Double width = chart.ChartArea.ChartVisualCanvas.Width;
        //    // Double height = chart.ChartArea.ChartVisualCanvas.Height;

        //    Panel preExistingPanel = null;
        //    Dictionary<RenderAs, Panel> RenderedCanvasList = chart.ChartArea.RenderedCanvasList;

        //    if (chartArea.RenderedCanvasList.ContainsKey(currentRenderAs))
        //    {
        //        preExistingPanel = RenderedCanvasList[currentRenderAs];
        //    }

        //    Panel renderedChart = chartArea.RenderSeriesFromList(preExistingPanel, selectedDataSeries4Rendering);

        //    if (preExistingPanel == null)
        //    {
        //        chartArea.RenderedCanvasList.Add(currentRenderAs, renderedChart);
        //        ChartVisualCanvas.Children.Add(renderedChart);
        //    }
        //}

        /// <summary>
        ///
        /// </summary>
        /// <param name="dataPoint"></param>
        /// <param name="property"></param>
        /// <param name="newValue"></param>
        /// <param name="isAxisChanged"></param>
        private static void UpdateDataPoint(DataPoint dataPoint, VcProperties property, object newValue, Boolean isAxisChanged)
        {
            Chart       chart       = dataPoint.Chart as Chart;
            PlotDetails plotDetails = chart.PlotDetails;
            Marker      marker      = dataPoint.Marker;
            DataSeries  dataSeries  = dataPoint.Parent;

            Canvas pointChartCanvas = dataSeries.Faces.Visual as Canvas;

            Double plotHeight = chart.ChartArea.ChartVisualCanvas.Height;
            Double plotWidth  = chart.ChartArea.ChartVisualCanvas.Width;

            ColumnChart.UpdateParentVisualCanvasSize(chart, pointChartCanvas);

            if (property == VcProperties.Enabled)
            {
                CreateOrUpdateAPointDataPoint(pointChartCanvas, dataPoint, plotWidth, plotHeight);
                return;
            }

            if (dataPoint.Faces == null)
            {
                return;
            }

            Grid bubbleVisual = dataPoint.Faces.Visual as Grid;

            switch (property)
            {
            case VcProperties.Bevel:
                break;

            case VcProperties.Cursor:
                break;

            case VcProperties.Href:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.HrefTarget:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.LabelBackground:
                if (marker != null)
                {
                    marker.TextBackground = dataPoint.LabelBackground;
                }
                break;

            case VcProperties.LabelEnabled:
                CreateOrUpdateAPointDataPoint(pointChartCanvas, dataPoint, plotWidth, plotHeight);
                //if (marker != null)
                //    marker.LabelEnabled = (Boolean)dataPoint.LabelEnabled;
                break;

            case VcProperties.LabelFontColor:
                if (marker != null)
                {
                    marker.FontColor = dataPoint.LabelFontColor;
                }

                break;

            case VcProperties.LabelFontFamily:
                if (marker != null)
                {
                    marker.FontFamily = dataPoint.LabelFontFamily;
                }
                break;

            case VcProperties.LabelFontStyle:
                if (marker != null)
                {
                    marker.FontStyle = (FontStyle)dataPoint.LabelFontStyle;
                }
                break;

            //case VcProperties.LabelFontSize:
            //    if (marker != null)
            //        marker.FontSize = (Double)dataPoint.LabelFontSize;
            //    break;

            case VcProperties.LabelFontWeight:
                if (marker != null)
                {
                    marker.FontWeight = (FontWeight)dataPoint.LabelFontWeight;
                }
                break;

            case VcProperties.LabelAngle:
                if (marker != null)
                {
                    marker.FontWeight = (FontWeight)dataPoint.LabelFontWeight;
                }
                break;

            case VcProperties.LegendText:
                chart.InvokeRender();
                break;

            case VcProperties.Color:
            case VcProperties.LightingEnabled:
                if (marker != null)
                {
                    marker.MarkerShape.Fill = (chart.View3D ? Graphics.Get3DBrushLighting(dataPoint.Color, (Boolean)dataPoint.LightingEnabled) : ((Boolean)dataPoint.LightingEnabled ? Graphics.GetLightingEnabledBrush(dataPoint.Color, "Linear", null) : dataPoint.Color));
                }
                break;

            case VcProperties.MarkerBorderColor:
                if (marker != null)
                {
                    marker.BorderColor = dataPoint.MarkerBorderColor;
                }
                break;

            case VcProperties.MarkerBorderThickness:
                if (marker != null)
                {
                    marker.BorderThickness = dataPoint.MarkerBorderThickness.Value.Left;
                }
                break;

            case VcProperties.MarkerColor:
                if (marker != null)
                {
                    marker.MarkerFillColor = dataPoint.MarkerColor;
                }
                break;

            case VcProperties.LabelFontSize:
            case VcProperties.LabelStyle:
            case VcProperties.LabelText:
            case VcProperties.MarkerScale:
            case VcProperties.MarkerSize:
            case VcProperties.MarkerType:
                CreateOrUpdateAPointDataPoint(pointChartCanvas, dataPoint, plotWidth, plotHeight);
                break;

            case VcProperties.ShadowEnabled:
                if (marker != null)
                {
                    marker.ShadowEnabled = (Boolean)dataPoint.ShadowEnabled;
                    marker.ApplyRemoveShadow();
                }

                break;

            case VcProperties.Opacity:
                if (marker != null)
                {
                    marker.Visual.Opacity = dataPoint.Opacity * dataSeries.Opacity;
                }
                break;

            case VcProperties.ShowInLegend:
                chart.InvokeRender();
                break;

            case VcProperties.ToolTipText:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                break;

            case VcProperties.XValueFormatString:
            case VcProperties.YValueFormatString:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                CreateOrUpdateAPointDataPoint(pointChartCanvas, dataPoint, plotWidth, plotHeight);
                break;

            case VcProperties.XValueType:
                chart.InvokeRender();
                break;

            case VcProperties.XValue:
            case VcProperties.YValue:
                if (isAxisChanged)
                {
                    UpdateDataSeries(dataSeries, property, newValue, false);
                }
                else
                if (marker != null)
                {
                    dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);

                    if ((Boolean)dataPoint.LabelEnabled)
                    {
                        marker.Text = dataPoint.TextParser(dataPoint.LabelText);
                    }

                    BubbleChart.UpdateBubblePositionAccording2XandYValue(dataPoint, plotWidth, plotHeight, chart.AnimatedUpdate, marker.MarkerShape.Width, marker.MarkerShape.Width);
                }

                break;
            }

            if (pointChartCanvas.Parent != null)
            {
                Double tickLengthOfAxisX = (from tick in chart.AxesX[0].Ticks
                                            where (Boolean)chart.AxesX[0].Enabled && (Boolean)tick.Enabled
                                            select tick.TickLength).Sum();

                if (tickLengthOfAxisX == 0)
                {
                    tickLengthOfAxisX = 5;
                }

                Double tickLengthOfPrimaryAxisY = (from axis in chart.AxesY
                                                   where axis.AxisType == AxisTypes.Primary
                                                   from tick in axis.Ticks
                                                   where (Boolean)axis.Enabled && (Boolean)tick.Enabled
                                                   select tick.TickLength).Sum();

                if (tickLengthOfPrimaryAxisY == 0)
                {
                    tickLengthOfPrimaryAxisY = 8;
                }

                Double tickLengthOfSecondaryAxisY = (from axis in chart.AxesY
                                                     where axis.AxisType == AxisTypes.Secondary
                                                     from tick in axis.Ticks
                                                     where (Boolean)axis.Enabled && (Boolean)tick.Enabled
                                                     select tick.TickLength).Sum();

                if (tickLengthOfSecondaryAxisY == 0)
                {
                    tickLengthOfSecondaryAxisY = 8;
                }

                Double plotGroupCount = (from c in chart.PlotDetails.PlotGroups
                                         where c.AxisY.AxisType == AxisTypes.Secondary
                                         select c).Count();

                RectangleGeometry clipRectangle = new RectangleGeometry();
                clipRectangle.Rect = new Rect(-tickLengthOfPrimaryAxisY, -chart.ChartArea.PLANK_DEPTH - 4, plotWidth + tickLengthOfSecondaryAxisY + (plotGroupCount > 0 ? tickLengthOfPrimaryAxisY : 8) + chart.ChartArea.PLANK_OFFSET, plotHeight + chart.ChartArea.PLANK_DEPTH + chart.ChartArea.PLANK_THICKNESS + tickLengthOfAxisX + 4);
                (pointChartCanvas.Parent as Canvas).Clip = clipRectangle;
            }
        }
        private static void UpdateDataPoint(DataPoint dataPoint, VcProperties property, object newValue, Boolean isAxisChanged)
        {
            Chart chart = dataPoint.Chart as Chart;

            if (chart == null)
            {
                return;
            }

            DataSeries dataSeries = dataPoint.Parent;
            PlotGroup  plotGroup  = dataSeries.PlotGroup;
            Faces      dsFaces    = dataSeries.Faces;
            Faces      dpFaces    = dataPoint.Faces;
            Double     dataPointWidth;

            if (dsFaces != null)
            {
                ColumnChart.UpdateParentVisualCanvasSize(chart, dsFaces.Visual as Canvas);
            }

            if (dpFaces != null && dpFaces.Visual != null)
            {
                dataPointWidth = dpFaces.Visual.Width;
            }
            else if (dsFaces == null)
            {
                return;
            }
            else
            {
                dataPointWidth = CalculateDataPointWidth(dsFaces.Visual.Width, dsFaces.Visual.Height, chart);
            }

            if (property == VcProperties.Enabled || (dpFaces == null && (property == VcProperties.XValue || property == VcProperties.YValues)))
            {
                CreateOrUpdateACandleStick(dataPoint, dsFaces.Visual as Canvas, dsFaces.LabelCanvas, dsFaces.Visual.Width, dsFaces.Visual.Height, dataPointWidth);
                return;
            }

            if (dpFaces == null)
            {
                return;
            }

            switch (property)
            {
            case VcProperties.BorderThickness:
                ApplyOrUpdateBorder(dataPoint, dataPointWidth);
                ApplyOrRemoveBevel(dataPoint, dataPointWidth);
                break;

            case VcProperties.BorderStyle:
                ApplyOrUpdateBorder(dataPoint, dataPointWidth);
                break;

            case VcProperties.BorderColor:
                ApplyOrUpdateBorder(dataPoint, dataPointWidth);
                break;

            case VcProperties.Bevel:
                ApplyOrRemoveBevel(dataPoint, dataPointWidth);
                break;

            case VcProperties.Color:
            case VcProperties.PriceUpColor:
            case VcProperties.PriceDownColor:
            case VcProperties.StickColor:
                ApplyOrUpdateColorForACandleStick(dataPoint);
                break;

            case VcProperties.Cursor:
                dataPoint.SetCursor2DataPointVisualFaces();
                break;

            case VcProperties.Href:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.HrefTarget:
                dataPoint.SetHref2DataPointVisualFaces();
                break;

            case VcProperties.LabelBackground:
            case VcProperties.LabelEnabled:
            case VcProperties.LabelFontColor:
            case VcProperties.LabelFontFamily:
            case VcProperties.LabelFontStyle:
            case VcProperties.LabelFontSize:
            case VcProperties.LabelFontWeight:
            case VcProperties.LabelStyle:
            case VcProperties.LabelText:
                CreateAndPositionLabel(dsFaces.LabelCanvas, dataPoint);
                break;


            case VcProperties.LegendText:
                chart.InvokeRender();
                break;

            case VcProperties.LightingEnabled:
                ApplyOrUpdateColorForACandleStick(dataPoint);
                break;

            //case VcProperties.MarkerBorderColor:
            //case VcProperties.MarkerBorderThickness:
            //case VcProperties.MarkerColor:
            //case VcProperties.MarkerEnabled:
            //case VcProperties.MarkerScale:
            //case VcProperties.MarkerSize:
            //case VcProperties.MarkerType:
            case VcProperties.ShadowEnabled:
                ApplyOrRemoveShadow(dataPoint, dataPointWidth);
                break;

            case VcProperties.Opacity:
                dpFaces.Visual.Opacity = (Double)dataSeries.Opacity * (Double)dataPoint.Opacity;
                break;

            case VcProperties.ShowInLegend:
                chart.InvokeRender();
                break;

            case VcProperties.ToolTipText:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                break;

            case VcProperties.XValueFormatString:
            case VcProperties.YValueFormatString:
                dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                CreateAndPositionLabel(dsFaces.LabelCanvas, dataPoint);
                break;

            case VcProperties.XValueType:
                chart.InvokeRender();
                break;

            case VcProperties.Enabled:
                CreateOrUpdateACandleStick(dataPoint, dsFaces.Visual as Canvas, dsFaces.LabelCanvas, dsFaces.Visual.Width, dsFaces.Visual.Height, dataPointWidth);
                break;

            case VcProperties.XValue:
            case VcProperties.YValue:
            case VcProperties.YValues:
                if (isAxisChanged || dataPoint.InternalYValues == null)
                {
                    UpdateDataSeries(dataSeries, property, newValue, isAxisChanged);
                }
                else
                {
                    dataPoint._parsedToolTipText = dataPoint.TextParser(dataPoint.ToolTipText);
                    UpdateYValueAndXValuePosition(dataPoint, dsFaces.Visual.Width, dsFaces.Visual.Height, dpFaces.Visual.Width);

                    if ((Boolean)dataPoint.LabelEnabled)
                    {
                        CreateAndPositionLabel(dsFaces.LabelCanvas, dataPoint);
                    }
                }

                if (dataPoint.Parent.SelectionEnabled && dataPoint.Selected)
                {
                    dataPoint.Select(true);
                }

                break;
            }
        }