Platforms to show: All Mac Windows Linux Cross-Platform
Back to CDBaseChartMBS class.
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
BaseChart.layout is automatically called when drawing the chart image (eg. using BaseChart.makeChart, BaseChart.makeChart or BaseChart.makeChart3). There is usually no need to call BaseChart.layout explicitly.
However, if you would like to add custom objects to the chart whose positions depend on the axis scales or position of other objects, you may need to call BaseChart.layout explicit to auto-scaling the axis. An example is to draw a custom label at the maximum value point of a data line.
CDBaseChartMBS.layoutLegend as CDLegendBoxMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
Once the legend box has been laid out, the width and height is known and can be obtained using Box.getWidth and Box.getHeight. However, you may not perform actions that may affect the legend box sizes, such as changing the fonts or adding more data. You may still move the legend box around by using Box.setPos.
The most common use of this method is to position the legend box based on its actual size.
Return Value
The LegendBox object representing the legend box in the chart.
Some examples using this method:
CDBaseChartMBS.linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as color, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as Integer, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as color, endColor as color, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as Integer, endColor as Integer, periodic as boolean=false) as Integer
CDBaseChartMBS.linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as Integer, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
In this method, the color points are defined as an array of positions and colors along a reference line segment, in the following format:
position0, color0, position1, color1, .... positionN, colorN
The positions are specified as a number from 0 - 256 (0 - 100 in hex), in which 0 represents the starting point of the reference line segment, and 256 (100 in hex) represents the ending point of the reference line segment.
For example, the array (in hex):
000000, FF0000, 000080, FFFF00, 000100, 00FF00
means the starting point (000000) is red (FF0000), the mid-point (000080 in hex) is yellow (FFFF00), and the ending point (000100 in hex) is green (00FF00).
One common usage of multi-point gradient colors is to define colors that have metallic look and feel. ChartDirector comes from several predefined gradient color arrays as follows.
NameValue (in Hex)
goldGradient | 000000, FFE743, 000060, FFFFE0, 0000B0, FFF0B0, 000100, FFE743 |
silverGradient | 000000, C8C8C8, 000060, F8F8F8, 0000B0, E0E0E0, 000100, C8C8C8 |
redMetalGradient | 000000, E09898, 000060, FFF0F0, 0000B0, F0D8D8, 000100, E09898 |
greenMetalGradient | 000000, 98E098, 000060, F0FFF0, 0000B0, D8F0D8, 000100, 98E098 |
blueMetalGradient | 000000, 9898E0, 000060, F0F0FF, 0000B0, D8D8F0, 000100, 9898E0 |
Argument | Default | Description |
startX | (Mandatory) | The x coordinate of the starting point of the reference gradient line segment. |
startY | (Mandatory) | The y coordinate of the starting point of the reference gradient line segment. |
endX | (Mandatory) | The x coordinate of the ending point of the reference gradient line segment. |
endY | (Mandatory) | The y coordinate of the ending point of the reference gradient line segment. |
colorArray | (Mandatory) | An array defining the positions and colors of the pixels along the reference gradient line segment. |
periodic | false | Specifies whether the gradient will repeat itself periodically. If the gradient does not repeat itself, the points that lie beyond the end points of the gradient line segment will assume the colors of the end points. |
A 32-bit integer representing the linear gradient color.
See also:
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as color, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as color, endColor as color, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as Integer, endColor as Integer, periodic as boolean=false) as Integer
CDBaseChartMBS.linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as color, endColor as color, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as color, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as Integer, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as Integer, endColor as Integer, periodic as boolean=false) as Integer
CDBaseChartMBS.linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as Integer, endColor as Integer, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
Argument | Default | Description |
startX | (Mandatory) | The x coordinate of the starting point of the reference gradient line segment. |
startY | (Mandatory) | The y coordinate of the starting point of the reference gradient line segment. |
endX | (Mandatory) | The x coordinate of the ending point of the reference gradient line segment. |
endY | (Mandatory) | The y coordinate of the ending point of the reference gradient line segment. |
startColor | (Mandatory) | The color at the starting point of the reference gradient line segment. |
endColor | (Mandatory) | The color at the ending point of the reference gradient line segment. |
periodic | false | Specifies whether the gradient will repeat itself periodically. If the gradient does not repeat itself, the points that lie beyond the end points of the gradient line segment will assume the colors of the end points. |
A 32-bit integer representing the linear gradient color.
See also:
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as color, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, colors() as Integer, periodic as boolean=false) as Integer
- linearGradientColor(startX as Integer, startY as Integer, endX as Integer, endY as Integer, startColor as color, endColor as color, periodic as boolean=false) as Integer
CDBaseChartMBS.makeChart as CDDrawAreaMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
If you want to add custom drawings at the background of the chart, use the BaseChart.getDrawArea method to obtain the DrawArea instead.
After finish adding custom drawings, the resulting chart can then be output using other chart output methods.
Return Value
A DrawArea object that can be used to add custom text and shapes to the chart.
See also:
Some examples using this method:
- /ChartDirector/ChartDirector Control
- /ChartDirector/ChartDirector Control for Web
- /ChartDirector/ChartDirector Control Retina
- /ChartDirector/circularbarmeter
- /ChartDirector/circularbarmeter2
- /ChartDirector/finance with ChartDirector Control
- /ChartDirector/Place PDF Chart with DynaPDF
- /ChartDirector/RealTime ViewPort
- /ChartDirector/simplePie with DynaPDF
- /ChartDirector/surfacetexture
CDBaseChartMBS.makeChart(format as Integer) as string
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
This method is most often used to output the chart directly to an HTTP stream.
ChartDirector supports PNG, JPG, GIF, WBMP and BMP formats, denoted by the following predefined constants:
ConstantValueDescription
kPNG | 0 | The PNG format. |
kGIF | 1 | The GIF format. |
kJPG | 2 | The JPEG format. |
kWMP | 3 | The WAP bitmap format. |
kBMP | 4 | The BMP format. |
kSVG | 5 | Normal SVG. |
kSVGZ | 6 | Compressed SVG |
kPDF | 7 | PDF format |
For vector output (SVG), please call enableVectorOutput early.
Argument | Default | Description |
format | (Mandatory) | A constant representing the format of the image. |
A memory block containing the binary image of the chart in the requested format.
See also:
CDBaseChartMBS.makeChart(path as folderitem) as boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
ChartDirector supports PNG, JPG, GIF, WBMP, SVG, PDF and BMP. The format used are selected based on file extension, which should be png, jpg, jpeg, gif, wbmp, wmp, pdf, svg or bmp.
Argument | Default | Description |
filename | (Mandatory) | The name of the file to save the image. |
A true value indicates no error. A false value indicates the operation is unsuccessful.
See also:
CDBaseChartMBS.makeChartPicture as picture
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
Returns nil on any error.
Some examples using this method:
- /ChartDirector/ChartDirector Control
- /ChartDirector/ChartDirector Control Retina
- /ChartDirector/datatable
- /ChartDirector/finance with ChartDirector Control
- /ChartDirector/multileveltreemap
- /ChartDirector/multivmeter
- /ChartDirector/squareameter
- /ChartDirector/surfacecolor
- /ChartDirector/threedscatteraxis
- /ChartDirector/Track Line with Legend Retina
CDBaseChartMBS.patternColor(colorvalues() as color, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
- patternColor(colorvalues() as Integer, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(file as folderitem, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(path as string, startX as integer = 0, startY as integer = 0) as integer
- patternColor(pic as picture, startX as Integer = 0, startY as Integer = 0) as Integer
CDBaseChartMBS.patternColor(colorvalues() as Integer, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
A pattern color is a dynamic color that changes according to a 2D periodic pattern. When it is used to fill an area, the area will look like being tiled with a wallpaper pattern.
Argument | Default | Description |
colorArray | (Mandatory) | An array of colors representing the colors of the bitmap pixels. The color of the pixel at (x, y) should correspond to index (x + y * width - 1) of the array. |
height | (Mandatory) | The height of the bitmap in pixels. (The width is automatically computed as the size of the color array divided by the height.) |
startX | 0 | The x coordinate of a reference point to align with the top-left corner the pattern. |
startY | 0 | The y coordinate of a reference point to align with the top-left corner the pattern. |
A 32-bit integer representing the pattern color.
See also:
- patternColor(colorvalues() as color, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(file as folderitem, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(path as string, startX as integer = 0, startY as integer = 0) as integer
- patternColor(pic as picture, startX as Integer = 0, startY as Integer = 0) as Integer
CDBaseChartMBS.patternColor(file as folderitem, startX as Integer = 0, startY as Integer = 0) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
A pattern color is a dynamic color that changes according to a 2D periodic pattern. When it is used to fill an area, the area will look like being tiled with a wallpaper pattern.
ChartDirector will automatically detect the image file format using the file extension, which must either png, jpg, jpeg, gif, wbmp or wmp (case insensitive).
Please refer to BaseChart.setSearchPath on the directory that ChartDirector will search for the file.
Argument | Default | Description |
filename | (Mandatory) | An image file providing the pattern. |
startX | 0 | The x coordinate of a reference point to align with the top-left corner the pattern. |
startY | 0 | The y coordinate of a reference point to align with the top-left corner the pattern. |
A 32-bit integer representing the pattern color.
See also:
- patternColor(colorvalues() as color, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(colorvalues() as Integer, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(path as string, startX as integer = 0, startY as integer = 0) as integer
- patternColor(pic as picture, startX as Integer = 0, startY as Integer = 0) as Integer
CDBaseChartMBS.patternColor(path as string, startX as integer = 0, startY as integer = 0) as integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 21.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
- patternColor(colorvalues() as color, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(colorvalues() as Integer, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(file as folderitem, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(pic as picture, startX as Integer = 0, startY as Integer = 0) as Integer
CDBaseChartMBS.patternColor(pic as picture, startX as Integer = 0, startY as Integer = 0) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 12.4 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
A pattern color is a dynamic color that changes according to a 2D periodic pattern. When it is used to fill an area, the area will look like being tiled with a wallpaper pattern.
Argument | Default | Description |
pic | (Mandatory) | A picture. The color of the pixel at (x, y) should correspond to index (x + y * width - 1) of the array. |
startX | 0 | The x coordinate of a reference point to align with the top-left corner the pattern. |
startY | 0 | The y coordinate of a reference point to align with the top-left corner the pattern. |
A 32-bit integer representing the pattern color.
See also:
- patternColor(colorvalues() as color, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(colorvalues() as Integer, height as Integer, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(file as folderitem, startX as Integer = 0, startY as Integer = 0) as Integer
- patternColor(path as string, startX as integer = 0, startY as integer = 0) as integer
CDBaseChartMBS.radialGradientColor(cx as Integer, cy as Integer, rx as Integer, ry as Integer, data() as Integer, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
In this method, the color points are defined as an array of radial distances and colors, in the following format:
distance0, color0, distance1, color1, .... distanceN, colorN
The distances are specified as a number from 0 - 256 (0 - 100 in hex), in which 0 represents the center of the gradient defining ellipse, and 256 (100 in hex) represents the perimeter of the gradient defining ellipse.
For example, the array (in hex):
000000, FF0000, 000080, FFFF00, 000100, 00FF00
means the center (000000) is red (FF0000), the mid-point (000080 in hex) is yellow (FFFF00), and the perimeter (000100 in hex) is green (00FF00).
Argument | Default | Description |
cx | (Mandatory) | The x coordinate of the center of the radial gradient. |
cy | (Mandatory) | The y coordinate of the center of the radial gradient. |
rx | (Mandatory) | The horizontal radius of the radial gradient defining ellipse. |
ry | (Mandatory) | The vertical radius of the radial gradient defining ellipse. |
colorArray | (Mandatory) | An array defining the radial distances and colors. |
periodic | false | Specifies whether the gradient will repeat itself periodically. If the gradient does not repeat itself, the points that lie outside the gradient defining ellipse will assume the color at the perimeter of the gradient defining ellipse. |
A 32-bit integer representing the radial gradient color.
See also:
- radialGradientColor(cx as Integer, cy as Integer, rx as Integer, ry as Integer, startColor as color, endColor as color, periodic as boolean=false) as Integer
- radialGradientColor(cx as Integer, cy as Integer, rx as Integer, ry as Integer, startColor as Integer, endColor as Integer, periodic as boolean=false) as Integer
CDBaseChartMBS.radialGradientColor(cx as Integer, cy as Integer, rx as Integer, ry as Integer, startColor as color, endColor as color, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.radialGradientColor(cx as Integer, cy as Integer, rx as Integer, ry as Integer, startColor as Integer, endColor as Integer, periodic as boolean=false) as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
Argument | Default | Description |
cx | (Mandatory) | The x coordinate of the center of the radial gradient. |
cy | (Mandatory) | The y coordinate of the center of the radial gradient. |
rx | (Mandatory) | The horizontal radius of the radial gradient defining ellipse. |
ry | (Mandatory) | The vertical radius of the radial gradient defining ellipse. |
startColor | (Mandatory) | The color at the center of the gradient defining ellipse. |
endColor | (Mandatory) | The color at the perimeter of the gradient defining ellipse. |
periodic | false | Specifies whether the gradient will repeat itself periodically. If the gradient does not repeat itself, the points that lie outside the gradient defining ellipse will assume the color at the perimeter of the gradient defining ellipse. |
A 32-bit integer representing the radial gradient color.
See also:
CDBaseChartMBS.removeDynamicLayer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 12.3 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
CDBaseChartMBS.setAMPM(am as string, pm as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
The default is to use "am" and "pm".
Argument | Default | Description |
am | (Mandatory) | The name used to denote morning. |
pm | (Mandatory) | The name used to denote afternoon. |
CDBaseChartMBS.setAntiAlias(shapeAntiAlias as Boolean, textAntiAlias as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
For anti-aliasing text, ChartDirector supports the following modes.
ConstantValueDescription
NoAntiAlias | 0 | Disable anti-alias when drawing text |
AntiAlias | 1 | Always use anti-alias when drawing text |
AutoAntiAlias | 2 | Automatically determine if anti-alias should be used for the text. This is the default. |
Currently, ChartDirector will anti-alias only large or bold fonts. For small fonts, assuming it is of high quality, anti-alias is unnecessary. It is because high quality fonts are normally designed to be sharp and clear at low resolution. Anti-aliasing will blur the fonts and make them look worse.
However, for complicated fonts (e.g. some fonts with oriental characters), or for lower quality fonts (e.g. some freeware fonts), anti-alias may be necessary. In this case, it may be needed to force anti-aliasing of all fonts using AntiAlias mode.
Argument | Default | Description |
shapeAntiAlias | true | A true value enables anti-alias when drawing lines and shapes. A false value disables anti-alias when drawing lines and shapes |
textAntiAlias | AutoAntiAlias | The text anti-alias mode, which must be one of AutoAntiAlias, AntiAlias or NoAntiAlias. |
CDBaseChartMBS.setBackground(colorvalue as color, edgeColor as color, raisedEffect as Integer = 0)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.setBackground(colorvalue as Integer, edgeColor as Integer = &hff000000, raisedEffect as Integer = 0)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
Argument | Default | Description |
color | (Mandatory) | The background color of the chart. |
edgeColor | Transparent | The border color of the chart. |
raisedEffect | 0 | The 3D border width. For positive values, the border will appear raised. For negative values, the border will appear depressed. A zero value means the border will appear flat. |
See also:
CDBaseChartMBS.setBgImage(img as string, align as Integer = 5)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
ChartDirector will automatically detect the image file format using the file extension, which must either png, jpg, jpeg, gif, wbmp or wmp (case insensitive).
Please refer to BaseChart.setSearchPath on the directory that ChartDirector will search for the file.
Argument | Default | Description |
img | (Mandatory) | The image file that is used as the background image of the chart. |
align | Center | The alignment of the background image relative to the chart. See Alignment Specification for supported alignment types. |
CDBaseChartMBS.setBorder(colorvalue as color)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.setBorder(colorvalue as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.setColor(paletteEntry as Integer, colorvalue as color)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.setColor(paletteEntry as Integer, colorvalue as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See Color Specification on how colors are represented in ChartDirector.
Argument | Default | Description |
paletteEntry | (Mandatory) | An index to the palette. |
color | (Mandatory) | The color to change to. |
See also:
CDBaseChartMBS.setColors(numbers() as color)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.setColors(numbers() as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See Color Specification on how colors are represented in ChartDirector.
Argument | Default | Description |
colors | (Mandatory) | An array of colors to change to. |
See also:
CDBaseChartMBS.setColors(paletteEntry as Integer, numbers() as color)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
CDBaseChartMBS.setColors(paletteEntry as Integer, numbers() as Integer)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See Color Specification on how colors are represented in ChartDirector.
Argument | Default | Description |
paletteEntry | (Mandatory) | An index to the palette to start changing the colors. |
colors | (Mandatory) | An array of colors to change to. |
See also:
CDBaseChartMBS.setDefaultColors(paletteEntry as Integer = 0)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
CDBaseChartMBS.setDefaultFonts(normal as string, bold as string, italic as string, boldItalic as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See Font Specification for details on various font attributes.
Argument | Default | Description |
normal | (Mandatory) | The default normal font. This is the same as the first font in the font table. |
bold | "" | The default bold font. This is the same as the second font in the font table. An empty string means the default is unchanged. |
italic | "" | The default italic font. This is the same as the third font in the font table. An empty string means the default is unchanged. |
boldItalic | "" | The default bold-italic font. This is the same as the fourth font in the font table. An empty string means the default is unchanged. |
See font specification here:
http://www.monkeybreadsoftware.net/faq-chartdirectorfontspecification.shtml
CDBaseChartMBS.setDropShadow(ColorValue as color, OffsetX as Integer = 5, OffsetY as Integer = &h7fffffff, blurRadius as Integer = 5)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 11.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
See also:
Some examples using this method:
CDBaseChartMBS.setDropShadow(ColorValue as Integer = &hAAAAAA, OffsetX as Integer = 5, OffsetY as Integer = &h7fffffff, blurRadius as Integer = 5)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 9.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
The drop shadow effect is created using a single color representation of the non-transparent part of the chart, offsetted by an amount, and put under the chart. The drop shadow can be blurred to create a soft drop shadow effect.
Note that adding a drop shadow will increase the width and height of the chart image so as to accommodate the drop shadow.
Because the drop shadow is located exterior to the original chart, it uses an exterior background color different from the background color of the original chart. The exterior background color is by default white, and can be configured with CDBaseChartMBS.setRoundedFrame.
Arguments:
Argument | Default | Description |
color | AAAAAA | The color of the drop shadow. |
offsetX | 5 | The x offset of the drop shadow. |
offsetY | 7fffffff | The y offset of the drop shadow. 7fffffff means it is the same as the x offset. |
blurRadius | 5 | The blur radius of the drop shadow. |
See also:
CDBaseChartMBS.setFontTable(index as Integer, font as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
The first 4 fonts in the font table have special significance. They are the defaults for normal, bold, italic and bold-italic fonts.
See Font Specification for details on various font attributes.
Argument | Default | Description |
index | (Mandatory) | An index to the font table, starting from 0. |
font | (Mandatory) | The font name to be put into the font table. |
See font specification here:
http://www.monkeybreadsoftware.net/faq-chartdirectorfontspecification.shtml
CDBaseChartMBS.setMonthNames(names() as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
The default is to use the first 3 characters of the English month names (Jan, Feb, Mar ...).
Argument | Default | Description |
names | (Mandatory) | An array of 12 text strings to be used as the month names. |
CDBaseChartMBS.setNumberFormat(thousandSeparator as string = "~", decimalPointChar as string = ".", signChar as string = "-")
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | ChartDirector | MBS ChartDirector Plugin | 8.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | All |
Argument | Default | Description |
thousandSeparator | '~' | The thousand separator. Use '~' to mean no thousand separator. |
decimalPointChar | '.' | The decimal point character. |
signChar | '-' | The negative sign character. |
The items on this page are in the following plugins: MBS ChartDirector Plugin.