OFC-2 - Miscellaneous Patches
This page contains the information about other patches that have been applied to the OFC-2
SWF file but do not have a full explanation/example page. Many of these patches were provided by or
requested users on the forum. These patches are not currently in the released version of OFC-2.
Thank you to everyone who has contributed to make Open Flash Chart the
excellent project that it is!!
Miscellaneous Patches
Area and Line Charts with null values optionally produce gaps in line
Set "null-gap":true to treat null points as gaps otherwise
the line will extend from the previous point to the next
defined point value.
Number formatting fixes
Corrects the formatting of large numbers when the thousands
separator is set to a period instead of a comma.
Thanks to AwayFromTheSun82 for providing a similar patch.
Inner Background Colour
Use "inner_bg_colour":"#nnnnnn" to specify a different colour
for the grid background area from the outer background area.
Inline JSON Data provided to Chart
Use a flash variable called "inline_data" to specify the
JSON data for the chart (similar to the "get_data" variable)
Thanks to qlegrand for this patch.
Disable tooltips for individual points/bars
Set the "tip" for the point/bar to an empty string ("") and it
will not display the tooltip window
Specify "alpha" value for Horizontal Bars
Set the "alpha" property for horizontal bars at the element type level
or for each individual bar object. (0 is transparent and 1 is opaque)
Chart Parameters "allowDomain" and "allowInsecureDomain"
Set these parameters and they will be passed to the flash.system.Security
object before an attempt is made to read the JSON data for the chart.
In theory this should allow you to set it up to allow cross domain access.
I believe that a value of "*" will allow access to anywhere.
See this link for more info:
Flash Security Class
+++ Update 27-Feb-2009: Apparently this applies only to SWF's loaded by other
SWF's. When attempting to load data from a different domain, a Flash
Security Policy file must be set up on the data hosting server to
allow access to it.
Enable Advanced Anti-Aliasing for unrotated Labels (21-Feb-2009)
* For the "title" and the "legend" objects, set the "font-family" to
"spArial" in the "style" property string.
* For the "legend" object there is a new "font" property that you must set to
"spArial".
* For X and Y Axis Labels and Tags set the "rotate" property to 360 so that
it will use the embedded font but will not actually rotate the text.
("spArial" is the internal name of the embedded font)
+++ Update 27-Feb-2009: Fixed Y-AxisLabels and hopefully the "top" legend
Passing the Char Parameter "ID" when saving images (23-Feb-2009)
* If an "ID" is defined as a chart paramter it will be passed to the
"save_image" callback and also to the callback function passed
into the "post_image"
New "on-click-window" property (8-Mar-2009)
* Use the "on-click-window" property to specify where an on-click URL should
be displayed. The valid values are:
"_blank" = open URL in a new window (default)
"_parent" = open URL in the parent of the current frame
"_self" = open URL in the current frame in the current window
"_top" = open URL in the top-level frame in the current window