Aspose::Words::Drawing::Charts::ChartStyle enum

ChartStyle enum

Specifies predefined styles of a chart.

enum class ChartStyle : int

Values

NameValueDescription
Black12A style with black chart background.
Blue14A style with blue chart background.
Flat4A style with flat data points without gradient.
Gradient6A style with gradient fill of data points.
Grey13A style with gray gradient chart background.
Muted1A style with muted colors.
Normal0Represents the default chart style.
Original7A style with an original appearance of a chart.
Outline10A style with data points having no fill, but only an outline.
OutlineBlack11A style with black chart background, in which data points have no fill, but only an outline.
Saturated2A style with more saturated colors.
Shaded3A style with shaded data points.
ShadedPlot15A style, in which the plot area is shaded.
Shadowed5A style with data points having a shadow.
Transparent18A style with transparent data points.
Transparent29A style with transparent data points.

Examples

Shows how to set and get chart style.

auto doc = System::MakeObject<Aspose::Words::Document>();
auto builder = System::MakeObject<Aspose::Words::DocumentBuilder>(doc);

// Insert a chart in the Black style.
builder->InsertChart(ChartType::Column, static_cast<double>(400), static_cast<double>(250), ChartStyle::Black);

doc->Save(get_ArtifactsDir() + u"Charts.SetChartStyle.docx");

doc = System::MakeObject<Aspose::Words::Document>(System::String(get_ArtifactsDir() + u"Charts.SetChartStyle.docx"));

// Get a chart to update.
auto shape = System::ExplicitCast<Aspose::Words::Drawing::Shape>(doc->GetChild(NodeType::Shape, 0, true));
System::SharedPtr<Aspose::Words::Drawing::Charts::Chart> chart = shape->get_Chart();

// Get the chart style.
ASSERT_EQ(chart->get_Style(), ChartStyle::Black);

See Also