public class ChartStyle
extends java.lang.Object
Examples:
Shows how to set and get chart style.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
// Insert a chart in the Black style.
builder.insertChart(ChartType.COLUMN, 400.0, 250.0, ChartStyle.BLACK);
doc.save(getArtifactsDir() + "Charts.SetChartStyle.docx");
doc = new Document(getArtifactsDir() + "Charts.SetChartStyle.docx");
// Get a chart to update.
Shape shape = (Shape)doc.getChild(NodeType.SHAPE, 0, true);
Chart chart = shape.getChart();
// Get the chart style.
Assert.assertEquals(ChartStyle.BLACK, chart.getStyle());
| Modifier and Type | Field and Description |
|---|---|
static int |
BLACK
A style with black chart background.
|
static int |
BLUE
A style with blue chart background.
|
static int |
FLAT
A style with flat data points without gradient.
|
static int |
GRADIENT
A style with gradient fill of data points.
|
static int |
GREY
A style with gray gradient chart background.
|
static int |
length |
static int |
MUTED
A style with muted colors.
|
static int |
NORMAL
Represents the default chart style.
|
static int |
ORIGINAL
A style with an original appearance of a chart.
|
static int |
OUTLINE
A style with data points having no fill, but only an outline.
|
static int |
OUTLINE_BLACK
A style with black chart background, in which data points have no fill, but only an outline.
|
static int |
SATURATED
A style with more saturated colors.
|
static int |
SHADED
A style with shaded data points.
|
static int |
SHADED_PLOT
A style, in which the plot area is shaded.
|
static int |
SHADOWED
A style with data points having a shadow.
|
static int |
TRANSPARENT_1
A style with transparent data points.
|
static int |
TRANSPARENT_2
A style with transparent data points.
|
| Modifier and Type | Method and Description |
|---|---|
static int |
fromName(java.lang.String chartStyleName) |
static java.lang.String |
getName(int chartStyle) |
static int[] |
getValues() |
static java.lang.String |
toString(int chartStyle) |
public static int NORMAL
public static int MUTED
public static int SATURATED
public static int SHADED
public static int FLAT
public static int SHADOWED
public static int GRADIENT
public static int ORIGINAL
public static int TRANSPARENT_1
public static int TRANSPARENT_2
public static int OUTLINE
public static int OUTLINE_BLACK
public static int BLACK
public static int GREY
public static int BLUE
public static int SHADED_PLOT
public static int length