Xojo Developer Conference
25/27th April 2018 in Denver.
MBS Xojo Conference
6/7th September 2018 in Munich, Germany.

Platforms to show: All Mac Windows Linux Cross-Platform

Previous items

CDBaseChartMBS.setBgImage(img as string, align as Integer = 5)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Uses the image from the specified file as the background image of the chart.
Notes:
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.
ArgumentDefaultDescription
img(Mandatory)The image file that is used as the background image of the chart.
alignCenterThe alignment of the background image relative to the chart. See Alignment Specification for supported alignment types.

Feedback, Comments & Corrections

CDBaseChartMBS.setBorder(colorvalue as color)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setBorder method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setBorder(colorvalue as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Deprecated. Use SetBackground instead.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setColor(paletteEntry as Integer, colorvalue as color)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setColor method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setColor(paletteEntry as Integer, colorvalue as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Change the color at the specified position in the palette.
Notes:
See Color Specification on how colors are represented in ChartDirector.
ArgumentDefaultDescription
paletteEntry(Mandatory)An index to the palette.
color(Mandatory)The color to change to.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setColors(numbers() as color)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setColors method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setColors(numbers() as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Change the colors in the palette.
Notes:
See Color Specification on how colors are represented in ChartDirector.
ArgumentDefaultDescription
colors(Mandatory)An array of colors to change to.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setColors(paletteEntry as Integer, numbers() as color)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setColors method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setColors(paletteEntry as Integer, numbers() as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Change the colors in the palette, starting from the specified position in the palette.
Notes:
See Color Specification on how colors are represented in ChartDirector.
ArgumentDefaultDescription
paletteEntry(Mandatory)An index to the palette to start changing the colors.
colors(Mandatory)An array of colors to change to.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setDefaultColors(paletteEntry as Integer = 0)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the default colors.

Feedback, Comments & Corrections

CDBaseChartMBS.setDefaultFonts(normal as string, bold as string, italic as string, boldItalic as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the defaults for normal, bold, italic and bold-italic fonts.
Notes:
See Font Specification for details on various font attributes.
ArgumentDefaultDescription
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

Feedback, Comments & Corrections

CDBaseChartMBS.setDropShadow(ColorValue as color, OffsetX as Integer = 5, OffsetY as Integer = &h7fffffff, blurRadius as Integer = 5)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setDropShadow method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

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 Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 9.2 Yes Yes Yes Yes No
Function: Adds a drop shadow to the chart.
Notes:
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:
ArgumentDefaultDescription
colorAAAAAAThe color of the drop shadow.
offsetX5The x offset of the drop shadow.
offsetY7fffffffThe y offset of the drop shadow. 7fffffff means it is the same as the x offset.
blurRadius5The blur radius of the drop shadow.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setFontTable(index as Integer, font as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets an entry in the font table to the specified font name.
Notes:
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.
ArgumentDefaultDescription
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

Feedback, Comments & Corrections

CDBaseChartMBS.setMonthNames(names() as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the names of the months for date/time formatting purposes.
Notes:
The default is to use the first 3 characters of the English month names (Jan, Feb, Mar ...).
ArgumentDefaultDescription
names(Mandatory)An array of 12 text strings to be used as the month names.

Feedback, Comments & Corrections

CDBaseChartMBS.setNumberFormat(thousandSeparator as string = "~", decimalPointChar as string = ".", signChar as string = "-")
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the characters used for thousand separator, decimal point, and negative sign.
Notes:
ArgumentDefaultDescription
thousandSeparator'~'The thousand separator. Use '~' to mean no thousand separator.
decimalPointChar'.'The decimal point character.
signChar'-'The negative sign character.

Feedback, Comments & Corrections

CDBaseChartMBS.setOutputOptions(options as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 15.1 Yes Yes Yes Yes No
Function: Sets output format options for the next chart output. Currently, only SVG, SVGZ and PDF output formats support output options.
Notes:
An output option can be a flag (such as "compress") or an attribute-value pair (such as "width=800"). Multiple output options can be joined using semicolons as delimiters.

SVG Options
SVG OptionTypeDescription
compressFlagCompressed the SVG, that is, output SVGZ.
bitmapFlagRender the chart as a bitmap and output the bitmap as SVG.
noxmldeclFlagDo not include the xml declaration line "<?xml version="1.0" .... >" in the SVG.
nodoctypeFlagDo not include the document type declaration line "<!DOCTYPE svg PUBLIC .... >" in the SVG.
widthFlag / AttributeSpecifies the width attribute of the SVG. By default, ChartDirector will not include the width or height attribute in the SVG output. In this case, the SVG is variable in size and would assume the size of its container. For example, if the SVG is inside a <DIV> block in a web page, it will assume the size of the DIV block. If the "width" option is used as a flag, ChartDirector will include the width attribute in the SVG and set it to the chart width. If the "width" option is used as an attribute (such as "width=800"), ChartDirector will include the width attribute in the SVG and set it to the specified value. The specified value should be some text that is valid as SVG width. Examples are "100" and "75%".
heightFlag / AttributeSpecifies the height attribute of the SVG. See the description on "width" above on how to use it.

PDF Options
PDF OptionTypeDescription
bitmapFlagRender the chart as a bitmap and output the bitmap as PDF.
widthAttributeThe width of the chart in the PDF in pixel unit. By default, ChartDirector will use the pixel width of the chart as the width of the chart in PDF. The "width" attribute can be used to specify an alternative value. The value must be a number.
heightAttributeThe width of the chart in the PDF in pixel unit. See the description on "width" above for how to use it.
pagewidthAttributeThe page width in pixel unit. By default, ChartDirector will set the page width to the same width as the chart. The "pagewidth" attribute can be used to specify an alternative value. The value must be a number.
pageheightAttributeThe page height in pixel unit. By default, ChartDirector will set the page height to the same height as the chart. The "pageheight" attribute can be used to specify an alternative value. The value must be a number.
leftxAttributeThe x coordinate of the left side of the chart within the page in pixel unit. By default, ChartDirector will center the chart in the page. The "leftx" attribute can be used to specify an alternative horizontal position. The coordinate must be a number.
topyAttributeThe y coordinate of the top side of the chart within the page in pixel unit. By default, ChartDirector will center the chart in the page. The "topy" attribute can be used to specify an alternative vertical position. The coordinate must be a number.
dpiAttributeSpecify the factor for conversion from pixel to physical unit. The PDF viewer will convert the pixel unit into physical unit (eg. inches) so that it can be layout on paper or other physical media. The default conversion factor for the chart is 96 pixels per inch. The "dpi" attribute can be used to specify an alternative value. The value must be a number.

ArgumentDefaultDescription
options(Mandatory)A list of options delimited by semicolons.

Feedback, Comments & Corrections

CDBaseChartMBS.setRoundedFrame(extColor as color, r1 as Integer = 10, r2 as Integer = -1, r3 as Integer = -1, r4 as Integer = -1)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setRoundedFrame method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setRoundedFrame(extColor as Integer = &hFFFFFF, r1 as Integer = 10, r2 as Integer = -1, r3 as Integer = -1, r4 as Integer = -1)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the border style of the chart to rounded corners.
Notes:
The underlying drawing surface for a chart is always rectangular. When rounded corners are used, part of the drawing surface (the regions external to the rounded corners) will be outside the chart border. The extColor argument specifies the color to be used for the external regions. Typically, it is set to the same color as the background the container that will be hosting the chart.

For example, in a web page, the extColor may be set to the same color as the web page background.
ArgumentDefaultDescription
extColorFFFFFFThe exterior background color.
r110The radius of the top-left rounded corner in pixels.
r2-1The radius of the top-right rounded corner in pixels. The default value of -1 means it is the same as the radius of the top-left corner.
r3-1The radius of the bottom-right rounded corner in pixels. The default value of -1 means it is the same as the radius of the top-left corner.
r4-1The radius of the bottom-left rounded corner in pixels. The default value of -1 means it is the same as the radius of the top-left corner.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setSearchPath(path as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the file system search path for loading image files.
Notes:
The plugin uses folderitems for most file operations, so this method is not needed for most operations.

Several ChartDirector operations involve loading image files. Examples are wallpapers (BaseChart.setWallpaper), background images (BaseChart.setBgImage and PlotArea.setBackground2), user-defined symbols (DataSet.setDataSymbol2) or for embedding images in text using ChartDirector Mark Up Language.
ArgumentDefaultDescription
path(Mandatory)A list of directories, separated with the path separator of your operating system (";" for Windows, ":" for Linux/UNIX).

Feedback, Comments & Corrections

CDBaseChartMBS.setSize(width as Integer, height as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the size of the chart.
Notes:
ArgumentDefaultDescription
width(Mandatory)The width of the chart in pixels.
height(Mandatory)The height of the chart in pixels.

Feedback, Comments & Corrections

CDBaseChartMBS.setThickFrame(thickness as Integer, frameColor as Integer = -1, outerEdgeColor as Integer = -1, innerEdgeColor as Integer = -1)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 15.1 Yes Yes Yes Yes No
Function: Sets a thick frame around the chart.
Notes:
The thick frame can have 3 colors for the frame itself, the outer edge and the inner edge.

In some applications, the frame color may be similar to the external background color. An common example is a "silver" frame (which is actually a light grey gradient) against a white background. In this case, the frame effect may look less than optimal. An outer edge of different color (such as darker grey) can often help to highlight the frame. Similarly, if the frame color is similar to the chart background, an inner edge of different color may help to improve the frame effect.

ArgumentDefaultDescription
thickness(Mandatory)The frame thickness.
frameColor-1The frame color. The default value of -1 means the frame color is the same as the outer edge color.
outerEdgeColor-1The outer edge color. The default value of -1 means the outer edge color is the same as the current edge color, which can be set in the chart constructor or in BaseChart.setBackground.
innerEdgeColor-1The inner edge color. The default value of -1 means the inner edge color is the same as the frame color.

Feedback, Comments & Corrections

CDBaseChartMBS.setTransparentColor(c as color)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 11.1 Yes Yes Yes Yes No
Function: Same as the other setTransparentColor method, but uses color instead of integer data type for passing color values.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setTransparentColor(c as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Specifies a certain color to mean transparent when creating the image output, or to include alpha transparency channel in the output.
Notes:
Alpha transparency: In addition to red, green and blue levels, there is a transparency level associated with each pixel, which can range from completely transparent to completely opaque. The data associated with the transparency information is called the alpha channel.

Single color transparency: The image itself has no alpha channel, but a certain color is used to mean completely transparent. For internal drawing, ChartDirector always use alpha transparency. However, when outputting the image as an image file, ChartDirector by default will remove the alpha channel to reduce image size. It is because many image displaying software do not support alpha transparency. For example, the IE browser only supports single color transparency but not alpha transparency.

If you want to use single color transparency in the output, you may specify the transparent color as the argument to the setTransparentColor method. Note that only GIF and PNG can support single color transparency. JPEG, BMP and WBMP cannot support transparency at all.

If you do want to keep the alpha channel in final output, you may pass -1 as the argument to setTransparentColor. Note that the only image format that can support alpha transparency is PNG.

One important thing to note is that the IE browser (and possibly many image displaying software) only supports single color transparency for palette based images with up to 256 colors, but not for true color images. For this reason, if single color transparency is used, ChartDirector will automatically reduce the image to 256 colors if it has more than 256 colors. This may result in lost of image quality, especially if the image contains gradient colors.

Therefore, due to the limitations of the current generations of image displaying software, for highest image quality, sometimes it may be beneficial to not using transparency in image output, but to set the image background color to the same color as the container background.
ArgumentDefaultDescription
c(Mandatory)The color that is designated as the transparent color. If -1 is used, the full alpha transparency channel will be included in the final output.

See also:

Feedback, Comments & Corrections

CDBaseChartMBS.setTransparentColors(paletteEntry as Integer = 0)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the color palette to transparent colors.

Feedback, Comments & Corrections

CDBaseChartMBS.setWallpaper(img as folderitem)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Uses the image from the specified file as the wallpaper to repetitively fill the background of the chart.
Notes:
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.
ArgumentDefaultDescription
img(Mandatory)The image file that is used as the background wallpaper of the chart.

Feedback, Comments & Corrections

CDBaseChartMBS.setWeekDayNames(names() as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the names of the week days for date/time formatting purposes.
Notes:
The default is to use the first 3 characters of the English week day names (Sun, Mon, Tue, ...).
ArgumentDefaultDescription
names(Mandatory)An array of 7 text strings to be used as the week day names.

Feedback, Comments & Corrections

CDBaseChartMBS.setWhiteOnBlackColors(paletteEntry as Integer = 0)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method ChartDirector MBS ChartDirector Plugin 8.2 Yes Yes Yes Yes No
Function: Sets the color palette to white on black colors.

Feedback, Comments & Corrections

Previous items

The items on this page are in the following plugins: MBS ChartDirector Plugin.




Links
MBS Xojo Plugins