Skip to main content

BarChartViewBase Class

The base class for bar chart views.

Declaration

public abstract class BarChartViewBase extends ColorfulChartView

Remarks

BarChartView and Bar3DChartView classes derive from the BarChartViewBase class.

Refer to the following help topic for additional information: Create Standard Charts — Presentation API for Java.

Inherited Members

com.devexpress.system.JavaObject.clone()
com.devexpress.system.JavaObject.equals(java.lang.Object)
com.devexpress.system.JavaObject.hashCode()
com.devexpress.system.JavaObject.memberwiseClone()
com.devexpress.system.JavaObject.toString()
java.lang.Object.finalize()
java.lang.Object.getClass()
java.lang.Object.notify()
java.lang.Object.notifyAll()
java.lang.Object.wait()
java.lang.Object.wait(long)
java.lang.Object.wait(long,int)

Inheritance

See Also

BarChartViewBase()

Initializes a new instance of the BarChartViewBase class.

Declaration

public BarChartViewBase()

Methods

getBarDirection() Method

Returns the bar orientation (vertical columns or horizontal bars).

Declaration

public BarChartDirection getBarDirection()

Returns

Type Description
BarChartDirection

The bar orientation.

getBarGrouping() Method

Returns the bar grouping type.

Declaration

public BarChartGrouping getBarGrouping()

Returns

Type Description
BarChartGrouping

The bar grouping type.

getGapWidth() Method

Returns the gap width between categories.

Declaration

public int getGapWidth()

Returns

Type Description
int

The gap width as a percentage of the bar width (from 0 to 500).

setBarDirection(BarChartDirection value) Method

Sets the bar orientation (vertical columns or horizontal bars).

Declaration

public void setBarDirection(BarChartDirection value)

Parameters

Name Type Description
value BarChartDirection

The bar orientation.

Exceptions

Type Description
NullPointerException

Thrown if the value parameter is null and the chart view is in a chart on a slide.

Remarks

The setBarDirection(value) method accepts the following values:

Value Description
COLUMN Indicates vertical bars (a column chart).
BAR Indicates horizontal bars (a bar chart).

If you do not call the setBarDirection(value) method, the view displays vertical columns (BarChartDirection.COLUMN).

setBarGrouping(BarChartGrouping value) Method

Sets the bar grouping type.

Declaration

public void setBarGrouping(BarChartGrouping value)

Parameters

Name Type Description
value BarChartGrouping

The bar grouping type.

Exceptions

Type Description
NullPointerException

Thrown if the value parameter is null and the chart view is in a chart on a slide.

Remarks

The setBarGrouping(value) method accepts the following values:

Value Description
STANDARD Indicates bars of each series in a separate row along the depth axis in a 3D column chart.
STACKED Indicates bars of all series stacked on top of each other in each category.
PERCENT_STACKED Indicates bars of all series stacked and scaled to 100% in each category.
CLUSTERED Indicates bars of all series placed side by side in each category.

If you do not call the setBarGrouping(value) method, the API uses BarChartGrouping.STANDARD.

Note

The BarChartGrouping.STANDARD value applies to 3D column charts. Horizontal 3D bar charts (BarChartDirection.BAR) do not support this value.

setGapWidth(int value) Method

Sets the gap width between categories.

Declaration

public void setGapWidth(int value)

Parameters

Name Type Description
value int

The gap width as a percentage of the bar width (from 0 to 500).

Exceptions

Type Description
ArgumentOutOfRangeException

Thrown if the value parameter is less than 0 or greater than 500.

Remarks

The value range is from 0 to 500. If you do not call the setGapWidth(value) method, the API uses 150.