Example #1
0
 private static string GetLabelText(CategoryNode categoryNode, DataPoint dataPoint, Series series, DataPointAttributes dataPointAttributes)
 {
     if (dataPoint != null)
     {
         if (TreeMapChart.IsLabelVisible(dataPoint))
         {
             string labelText = PieChart.GetLabelText(dataPoint, false);
             if (!string.IsNullOrEmpty(labelText))
             {
                 return(labelText);
             }
             return(SunburstChart.GetCategoryNodeLabelText(categoryNode, series, dataPoint));
         }
     }
     else if (TreeMapChart.IsLabelVisible(dataPointAttributes))
     {
         return(SunburstChart.GetCategoryNodeLabelText(categoryNode, series, dataPointAttributes));
     }
     return(string.Empty);
 }