Esempio n. 1
0
        private static void RenderDataPointLabel(ChartGraphics graph, ChartArea area, int index, TreeMapNode dataPointTreeMapNode, RectangleF seriesLabelRelativeRect)
        {
            RectangleF relativeRect = TreeMapChart.GetRelativeRect(graph, dataPointTreeMapNode);
            string     labelText    = TreeMapChart.GetLabelText(dataPointTreeMapNode.DataPoint);

            TreeMapChart.RenderDataPointLabel(graph, area, index, dataPointTreeMapNode, labelText, TreeMapChart.GetDataPointLabelRelativeRect(graph, dataPointTreeMapNode, relativeRect, labelText), relativeRect, seriesLabelRelativeRect);
        }
Esempio n. 2
0
        private static void RenderDataPoint(ChartGraphics graph, CommonElements common, int index, TreeMapNode dataPointTreeMapNode)
        {
            RectangleF relativeRect = TreeMapChart.GetRelativeRect(graph, dataPointTreeMapNode);
            DataPoint  dataPoint    = dataPointTreeMapNode.DataPoint;

            graph.FillRectangleRel(relativeRect, dataPoint.Color, dataPoint.BackHatchStyle, dataPoint.BackImage, dataPoint.BackImageMode, dataPoint.BackImageTransparentColor, dataPoint.BackImageAlign, dataPoint.BackGradientType, dataPoint.BackGradientEndColor, dataPoint.BorderColor, dataPoint.BorderWidth, dataPoint.BorderStyle, dataPoint.series.ShadowColor, dataPoint.series.ShadowOffset, PenAlignment.Inset, ChartGraphics.GetBarDrawingStyle(dataPoint), true);
            TreeMapChart.AddDataPointHotRegion(graph, common, index, dataPoint, relativeRect);
        }
Esempio n. 3
0
 private static void RenderLabels(ChartGraphics graph, ChartArea area, List <TreeMapNode> seriesTreeMapNodes)
 {
     foreach (TreeMapNode seriesTreeMapNode in seriesTreeMapNodes)
     {
         if (seriesTreeMapNode.DataPoint != null)
         {
             RectangleF relativeRect = TreeMapChart.GetRelativeRect(graph, seriesTreeMapNode);
             RectangleF rectangleF   = TreeMapChart.GetSeriesLabelRelativeRect(graph, area, seriesTreeMapNode.Series, relativeRect, seriesTreeMapNode.DataPoint);
             if (!TreeMapChart.CanLabelFit(relativeRect, rectangleF))
             {
                 rectangleF = RectangleF.Empty;
             }
             int num = 0;
             foreach (TreeMapNode child in seriesTreeMapNode.Children)
             {
                 DataPoint  dataPoint = child.DataPoint;
                 RectangleF rectangle = child.Rectangle;
                 TreeMapChart.RenderDataPointLabel(graph, area, num, child, rectangleF);
                 num++;
             }
             TreeMapChart.RenderSeriesLabel(graph, seriesTreeMapNode, rectangleF);
         }
     }
 }