Chart FX for Java 6.5

SoftwareFX.ChartFX
Class Chart

java.lang.Object
  extended by SoftwareFX.ChartFX.ChartCore
      extended by SoftwareFX.ChartFX.Chart
Direct Known Subclasses:
ChartServer, Map

public final class Chart
extends ChartCore

Provides access to the Chart object.

General chart properties are provided to set general attributes in the chart. For example, you may use properties to show or hide tools in the chart window or to apply a specific line style to all lines in a line chart.

There may be a case in which a general property is also found in a specific object. For example, you may use a general property called Gallery property to change the chart type displayed (for all series in the chart), but if you use the Gallery property supported by the Series object you will change the chart type for a particular series (thus creating a MultiType chart) instead of all series in the chart. You may even go a step further by assigning properties directly to specific points rather than series using the Point object.

Some properties of the Chart object act as a mechanism for assigning attributes directly to other objects that exist in the chart. Some of these properties include ChartCore.getLegendBoxObj(), ChartCore.getSerLegBoxObj(), ChartCore.getUserLegendBoxObj(), ChartCore.getToolBarObj(int) and ChartCore.getMenuBarObj(int).

If you want to assign individual properties to elements in the chart, you may refer to the different objects available.


Field Summary
static double HIDDEN
           
 
Constructor Summary
Chart()
           
 
Method Summary
 double dateToNumber(java.util.Calendar date)
          Converts a Java Date to Chart FX internal Format.
 double dateToNumber(java.util.Date date)
          Converts a Java Date to Chart FX internal Format.
 java.awt.Font getFont()
          Gets the Font.
 int getHeight()
          Gets the Height.
 void getHtmlData(java.lang.Object width, java.lang.Object height, java.lang.String tag)
          Prevents the chart file from being saved to disk by bit-streaming the chart directly to the browser.
 void getHtmlDataEx(java.lang.Object width, java.lang.Object height, java.lang.String tag, java.io.OutputStream data, java.io.OutputStream imgmap, java.io.OutputStream tagText)
          Allows you to retrieve the image data and map in one call.
 java.lang.String getHtmlTag()
          Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.
 java.lang.String getHtmlTag(java.lang.Object objWidth, java.lang.Object objHeight)
          Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.
 java.lang.String getHtmlTag(java.lang.Object objWidth, java.lang.Object objHeight, java.lang.String tag)
          Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.
 java.lang.String getHtmlTag(java.lang.Object width, java.lang.Object height, java.lang.String tag, java.lang.String name)
          Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.
 java.lang.String getID()
          Gets the ID.
 int getImgHeight()
          Gets the ImgHeight.
 int getImgMap()
          Gets the ImgMap.
 int getImgQuality()
          Gets the ImgQuality.
 java.lang.String getImgTags()
          Gets the ImgTags.
 int getImgWidth()
          Gets the ImgWidth.
 IOutputWriter getOutputWriter()
          Gets the OutputWriter.
 java.lang.String getProxyUri()
          Gets the ProxyUri.
 java.lang.String getURL()
          Deprecated. You should use chart.getLink().getUrl instead.
 int getURLOptions()
          Deprecated. You should use chart.getLink().getReload instead.
 java.lang.String getURLParamMask()
          Deprecated. You should use chart.getLink().getUrl instead.
 java.lang.String getURLTarget()
          Deprecated. You should use chart.getLink().getTarget instead.
 int getWidth()
          Gets the Width.
 boolean isEmbeddedData()
          Gets the EmbeddedData.
 boolean isImgSizeable()
          Gets the ImgSizeable.
 boolean isMainClient()
          Gets the MainClient.
 void loadDefault(int n)
          Reload the inifiles making effective the changes you have made on those files without the need of stopping or rebooting the server.
 void setConfigPath(java.lang.String path)
          Sets the path for the location of the configuration files.
 void setEmbeddedData(boolean value)
          Gets or sets a value specifying if chart data will be embedded in the resulting html.
 void setFont(java.awt.Font value)
          Allows you to change the font attributes for the entire chart.
 void setHeight(int value)
          Specifies the suggested height of the chart when generating images.
 void setHtmlTag(java.lang.String value)
          Allows you to select the type of tag generated by ChartFX.
 void setID(java.lang.String ID)
          Sets the Map name for the Image Map.
 void setImgHeight(int value)
          Specifies the suggested height of the chart when generating images.
 void setImgMap(int value)
          Allows you to control how ToolTip will appear in the chart area.
 void setImgQuality(int value)
          Allows you to set the image quality for generated Jpeg chart images.
 void setImgSizeable(boolean value)
          Allows you to specify if Chart images will be based on pixels or percentages.
 void setImgTags(java.lang.String value)
          A string property that will be appended to the IMG tag created by Chart FX.
 void setImgWidth(int value)
          Specifies the suggested width of the chart when generating images.
 void setMainClient(boolean value)
          Gets or sets a value indicating whether to generate an object with a small "wrapper" control for faster downloads when generating .NET Client Controls.
 void setOutputWriter(IOutputWriter value)
          Allows you to select a specific external output writer for generating chart images.
 void setProxyUri(java.lang.String value)
          Used to add the Proxy URI of a proxy server.
 void setURL(java.lang.String value)
          Deprecated. You should use chart.getLink().setUrl instead.
 void setURLOptions(int value)
          Deprecated. You should use chart.getLink().setReload instead.
 void setURLParamMask(java.lang.String value)
          Deprecated. You should use chart.getLink().setUrl instead.
 void setURLTarget(java.lang.String value)
          Deprecated. You should use chart.getLink().setTarget instead.
 void setWidth(int value)
          Specifies the suggested width of the chart when generating images.
 
Methods inherited from class SoftwareFX.ChartFX.ChartCore
clearData, closeData, exportChart, exportChart, getAngleX, getAngleY, getAxesStyle, getAxis, getAxis, getAxisX, getAxisY, getAxisY2, getBackColor, getBackgroundImage, getBackObject, getBorderColor, getBorderEffect, getBorderObject, getBottomGap, getChartStyle, getCommand, getCommands, getConditionalAttribute, getConditionalAttributes, getConstantLine, getConstantLines, getCulture, getCylSides, getDataEditorObj, getDataSource, getDataSourceSettings, getDataStyle, getDataType, getDataType, getDesignTimeData, getExtension, getExtensions, getFileMask, getGallery, getGalleryObj, getGaps, getGrid, getHighlight, getImageMode, getInfoString, getIniValue, getIniValue, getInsideBackObject, getInsideColor, getKeyLeg, getKeyLeg, getLeftGap, getLegend, getLegend, getLegendBoxObj, getLineStyle, getLineWidth, getLink, getMarkerShape, getMarkerSize, getMarkerStep, getMenuBarObj, getMenuBarObj, getMessageText, getNSeries, getNValues, getPageColor, getPalette, getPane, getPanes, getPersonalizedFlags, getPersonalizedName, getPerspective, getPoint, getPoint, getPoint, getPointFont, getPointLabelAlign, getPointLabelAngle, getPointLabelColor, getPointLabelFont, getPointLabelMask, getPointLabelOffset, getPrinter, getRightGap, getScheme, getSeries, getSeries, getSerKey, getSerKey, getSerLeg, getSerLeg, getSerLegBoxObj, getSmoothFlags, getStacked, getStripe, getStripes, getStyleEx, getTemplateMask, getTipMask, getTitle, getTitles, getToolBarObj, getToolBarObj, getTopGap, getTypeEx, getTypeMask, getUserLegendBoxObj, getValue, getValue, getView3DDepth, getView3DLight, getVolume, getWallWidth, getXValue, getXValue, getYLeg, getYLeg, importChart, importChart, isAllowDrag, isAllowEdit, isBorder, isChart3D, isCluster, isContextMenus, isCrossHairs, isDataEditor, isDirty, isLegendBox, isMenuBar, isMultipleColors, isPointLabels, isScrollable, isSerLegBox, isShowTips, isToolBar, isUserLegendBox, isView3D, isZoom, markerToPixel, openData, paint, recalcScale, setAllowDrag, setAllowEdit, setAngleX, setAngleY, setAxesStyle, setBackColor, setBackgroundImage, setBackObject, setBorder, setBorderColor, setBorderEffect, setBorderObject, setBottomGap, setChart3D, setChartStyle, setCluster, setContextMenus, setCrossHairs, setCulture, setCylSides, setDataEditor, setDataSource, setDataStyle, setDataType, setDesignTimeData, setDirty, setFileMask, setGallery, setGalleryObj, setGaps, setGrid, setImageMode, setIniValue, setInsideBackObject, setInsideColor, setKeyLeg, setLeftGap, setLegend, setLegendBox, setLineStyle, setLineWidth, setMarkerShape, setMarkerSize, setMarkerStep, setMenuBar, setMenuBarObj, setMessageText, setMultipleColors, setNSeries, setNValues, setPageColor, setPalette, setPersonalizedFlags, setPersonalizedName, setPerspective, setPoint, setPoint, setPointFont, setPointLabelAlign, setPointLabelAngle, setPointLabelColor, setPointLabelFont, setPointLabelMask, setPointLabelOffset, setPointLabels, setRightGap, setScheme, setScrollable, setSerKey, setSerLeg, setSerLegBox, setShowTips, setSmoothFlags, setStacked, setStyleEx, setTemplateMask, setTipMask, setToolBar, setToolBarObj, setTopGap, setTypeEx, setTypeMask, setUserLegendBox, setValue, setView3D, setView3DDepth, setView3DLight, setVolume, setWallWidth, setXValue, setYLeg, setZoom
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HIDDEN

public static final double HIDDEN
See Also:
Constant Field Values
Constructor Detail

Chart

public Chart()
Method Detail

dateToNumber

public double dateToNumber(java.util.Date date)

Converts a Java Date to Chart FX internal Format.

Remarks:
  • When loading XValues which are dates to a Chart, they must be converted to an internal format for Chart FX to properly handle labeling and scaling.

  • Parameters:
    date - Date to convert
    See Also:
    Chart

    dateToNumber

    public double dateToNumber(java.util.Calendar date)

    Converts a Java Date to Chart FX internal Format.

    Remarks:
  • When loading XValues which are dates to a Chart, they must be converted to an internal format for Chart FX to properly handle labeling and scaling.

  • Parameters:
    date - Date to convert
    See Also:
    Chart

    getFont

    public java.awt.Font getFont()

    Gets the Font. For more detail see setFont(java.awt.Font).


    getHeight

    public int getHeight()

    Gets the Height. For more detail see setHeight(int).


    getHtmlData

    public void getHtmlData(java.lang.Object width,
                            java.lang.Object height,
                            java.lang.String tag)

    Prevents the chart file from being saved to disk by bit-streaming the chart directly to the browser.

    Remarks:
  • This method should only be used when you are manually creating your ASP.NET scripts in a single page approach or if you are creating the control programmatically (not dropping the chart in the web form at design time) in you Development tool. If you are creating web applications with Java IDE , the form will automatically generate the code to display the chart in the form.

  • Using this method requires use of a client page that calls getHtmlTag() referencing the page calling GetHtmlData method as the sTag parameter. Below is an example of such a page:

    <html>
    <IMG SRC="gethtmldata.jsp" WIDTH=450 HEIGHT=280>
    </html>

  • In terms of performance, the GetHtmlData method is processor intensive yet it allows developers to boost performance and scalability and it permits the use of Chart FX on intricate server architectures such as web farms.

  • Parameters:
    width - Required. Specifies the suggested width of the chart. If the parameter is an integer the width will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    height - Required. Specifies the suggested height of the chart. If the parameter is an integer the height will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    tag - Optional. Allows you to select the type of tag generated by ChartFX. The possible options are: ".NET", "Image", "Jpeg", "Png", "SVG" or "Auto". In Automatic mode ChartFX will use the HTTP_USER_AGENT variable to determine the appropriate tag compatible with the browser being used by the user. If no value is specified, The default setting is Auto.
    See Also:
    getHtmlTag(), getHtmlDataEx(java.lang.Object, java.lang.Object, java.lang.String, java.io.OutputStream, java.io.OutputStream, java.io.OutputStream)

    getHtmlDataEx

    public void getHtmlDataEx(java.lang.Object width,
                              java.lang.Object height,
                              java.lang.String tag,
                              java.io.OutputStream data,
                              java.io.OutputStream imgmap,
                              java.io.OutputStream tagText)

    Allows you to retrieve the image data and map in one call.

    Remarks:
  • The GetHtmlDataEx allows you to generate an image and its corresponding image map without generating any temporary files, this method also allows you to generate image maps in ColdFusion or server side apps other than IIS (note that GetHtmlTag returns the image map to the browser using the built-in IIS response object).

  • Parameters:
    width - Required. Specifies the suggested width of the chart. If the parameter is an integer the width will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    height - Required. Specifies the suggested height of the chart. If the parameter is an integer the height will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    tag - Optional. Allows you to select the type of tag generated by ChartFX. The possible options are: ".NET", "Image", "Jpeg", "Png", "SVG" or "Auto". In Automatic mode ChartFX will use the HTTP_USER_AGENT variable to determine the appropriate tag compatible with the browser being used by the user. If no value is specified, The default setting is Auto.
    data - Stream that contains the image data.
    imgmap - TextWriter that contains the image map information.
    tagText - TextWriter that contains the Image tag information.
    See Also:
    getHtmlData(java.lang.Object, java.lang.Object, java.lang.String), getHtmlTag()

    getHtmlTag

    public java.lang.String getHtmlTag()

    Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.

    Remarks:
  • This method should only be used when you are manually creating scripts in a single page approach or if you are creating the control programmatically (not dropping the chart in the web application project at design time). If you are creating web applications with Java IDE , the form will automatically generate the code to display the chart in the form.

  • One of GetHtmlTag's greatest advantages is that charts can be easily integrated into your existing scripts and it allows support for automatic browser detection. However, saving a file to disk can have its toll on server performance.

  • By default Chart FX will generate an image of the configured chart when developing with web applications. However, Chart FX can be configured to generate an active .NET Client Control or use browser detection to determine the correct format to display. To do this, you may configure the HtmlTag property in the design time property dialog to ".NET" or "Auto". The "Auto" setting will instruct Chart FX to use browser detection and the ".NET" setting will force the active component to be created. You may also configure the HtmlTag property to "PNG" or "JPEG" to force that specific format as the chart image. To force Chart FX to always generate an active .NET Client Control a single page approach, the GetHtmlTag method call should look like:

    out.println(chart1.getHtmlTag("450","280",".NET"));

  • The GetHtmlTag is responsible for processing the HTTP_USER_AGENT. This means, the GetHtmltag must be invoked using the <%=%> which will return the appropriate tag to the browser posting the request. For example:

    <%=chart1.getHtmlTag("450","280")%>

  • See Also:
    setImgSizeable(boolean), setImgWidth(int), setImgHeight(int), getHtmlData(java.lang.Object, java.lang.Object, java.lang.String)

    getHtmlTag

    public java.lang.String getHtmlTag(java.lang.Object width,
                                       java.lang.Object height,
                                       java.lang.String tag,
                                       java.lang.String name)

    Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.

    Remarks:
  • This method should only be used when you are manually creating scripts in a single page approach or if you are creating the control programmatically (not dropping the chart in the web application project at design time). If you are creating web applications with Java IDE , the form will automatically generate the code to display the chart in the form.

  • One of GetHtmlTag's greatest advantages is that charts can be easily integrated into your existing scripts and it allows support for automatic browser detection. However, saving a file to disk can have its toll on server performance.

  • By default Chart FX will generate an image of the configured chart when developing with web applications. However, Chart FX can be configured to generate an active .NET Client Control or use browser detection to determine the correct format to display. To do this, you may configure the HtmlTag property in the design time property dialog to ".NET" or "Auto". The "Auto" setting will instruct Chart FX to use browser detection and the ".NET" setting will force the active component to be created. You may also configure the HtmlTag property to "PNG" or "JPEG" to force that specific format as the chart image. To force Chart FX to always generate an active .NET Client Control a single page approach, the GetHtmlTag method call should look like:

    out.println(chart1.getHtmlTag("450","280",".NET"));

  • The GetHtmlTag is responsible for processing the HTTP_USER_AGENT. This means, the GetHtmltag must be invoked using the <%=%> which will return the appropriate tag to the browser posting the request. For example:

    <%=chart1.getHtmlTag("450","280")%>

  • Parameters:
    width - Required. Specifies the suggested width of the chart. If the parameter is an integer the width will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    height - Required. Specifies the suggested height of the chart. If the parameter is an integer the height will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    tag - Optional. Allows you to select the type of tag generated by ChartFX. The possible options are: ".NET", "ActiveX", "Image", "Jpeg", "Png", "SVG" or "Auto". In Automatic mode ChartFX will use the HTTP_USER_AGENT variable to determine the appropriate tag compatible with the browser being used by the user. If no value is specified, the default setting is Auto.
    name - Optional. Specifies the chart name. It is useful when you plan to write client-side scripts to manipulate the chart. The default value is Chart1.
    See Also:
    setImgSizeable(boolean), setImgWidth(int), setImgHeight(int), getHtmlData(java.lang.Object, java.lang.Object, java.lang.String)

    getHtmlTag

    public java.lang.String getHtmlTag(java.lang.Object objWidth,
                                       java.lang.Object objHeight,
                                       java.lang.String tag)

    Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.

    Remarks:
  • This method should only be used when you are manually creating scripts in a single page approach or if you are creating the control programmatically (not dropping the chart in the web application project at design time). If you are creating web applications with Java IDE , the form will automatically generate the code to display the chart in the form.

  • One of GetHtmlTag's greatest advantages is that charts can be easily integrated into your existing scripts and it allows support for automatic browser detection. However, saving a file to disk can have its toll on server performance.

  • By default Chart FX will generate an image of the configured chart when developing with web applications. However, Chart FX can be configured to generate an active .NET Client Control or use browser detection to determine the correct format to display. To do this, you may configure the HtmlTag property in the design time property dialog to ".NET" or "Auto". The "Auto" setting will instruct Chart FX to use browser detection and the ".NET" setting will force the active component to be created. You may also configure the HtmlTag property to "PNG" or "JPEG" to force that specific format as the chart image. To force Chart FX to always generate an active .NET Client Control a single page approach, the GetHtmlTag method call should look like:

    out.println(chart1.getHtmlTag("450","280",".NET"));

  • The GetHtmlTag is responsible for processing the HTTP_USER_AGENT. This means, the GetHtmltag must be invoked using the <%=%> which will return the appropriate tag to the browser posting the request. For example:

    <%=chart1.getHtmlTag("450","280")%>

  • Parameters:
    objWidth - Required. Specifies the suggested width of the chart. If the parameter is an integer the width will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    objHeight - Required. Specifies the suggested height of the chart. If the parameter is an integer the height will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    tag - Optional. Allows you to select the type of tag generated by ChartFX. The possible options are: ".NET", "ActiveX", "Image", "Jpeg", "Png", "SVG" or "Auto". In Automatic mode ChartFX will use the HTTP_USER_AGENT variable to determine the appropriate tag compatible with the browser being used by the user. If no value is specified, the default setting is Auto.
    See Also:
    setImgSizeable(boolean), setImgWidth(int), setImgHeight(int), getHtmlData(java.lang.Object, java.lang.Object, java.lang.String)

    getHtmlTag

    public java.lang.String getHtmlTag(java.lang.Object objWidth,
                                       java.lang.Object objHeight)

    Allows Chart FX for Java Server to determine the browser posting the request and return the appropriate tag to the browser for displaying the chart.

    Remarks:
  • This method should only be used when you are manually creating scripts in a single page approach or if you are creating the control programmatically (not dropping the chart in the web application project at design time). If you are creating web applications with Java IDE , the form will automatically generate the code to display the chart in the form.

  • One of GetHtmlTag's greatest advantages is that charts can be easily integrated into your existing scripts and it allows support for automatic browser detection. However, saving a file to disk can have its toll on server performance.

  • By default Chart FX will generate an image of the configured chart when developing with web applications. However, Chart FX can be configured to generate an active .NET Client Control or use browser detection to determine the correct format to display. To do this, you may configure the HtmlTag property in the design time property dialog to ".NET" or "Auto". The "Auto" setting will instruct Chart FX to use browser detection and the ".NET" setting will force the active component to be created. You may also configure the HtmlTag property to "PNG" or "JPEG" to force that specific format as the chart image. To force Chart FX to always generate an active .NET Client Control a single page approach, the GetHtmlTag method call should look like:

    out.println(chart1.getHtmlTag("450","280",".NET"));

  • The GetHtmlTag is responsible for processing the HTTP_USER_AGENT. This means, the GetHtmltag must be invoked using the <%=%> which will return the appropriate tag to the browser posting the request. For example:

    <%=chart1.getHtmlTag("450","280")%>

  • Parameters:
    objWidth - Required. Specifies the suggested width of the chart. If the parameter is an integer the width will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    objHeight - Required. Specifies the suggested height of the chart. If the parameter is an integer the height will be measured in pixels. You can also specify a string containing a percentage sign (e.g. "45%") to use a percentage of the available space in the clients page (or frame).
    See Also:
    setImgSizeable(boolean), setImgWidth(int), setImgHeight(int), getHtmlData(java.lang.Object, java.lang.Object, java.lang.String)

    getID

    public java.lang.String getID()

    Gets the ID. For more detail see setID(java.lang.String).


    getImgHeight

    public int getImgHeight()

    Gets the ImgHeight. For more detail see setImgHeight(int).


    getImgMap

    public int getImgMap()

    Gets the ImgMap. For more detail see setImgMap(int).


    getImgQuality

    public int getImgQuality()

    Gets the ImgQuality. For more detail see setImgQuality(int).


    getImgTags

    public java.lang.String getImgTags()

    Gets the ImgTags. For more detail see setImgTags(java.lang.String).


    getImgWidth

    public int getImgWidth()

    Gets the ImgWidth. For more detail see setImgWidth(int).


    getOutputWriter

    public IOutputWriter getOutputWriter()

    Gets the OutputWriter. For more detail see setOutputWriter(SoftwareFX.ChartFX.IOutputWriter).


    getProxyUri

    public java.lang.String getProxyUri()

    Gets the ProxyUri. For more detail see setProxyUri(java.lang.String).


    getURL

    public java.lang.String getURL()
    Deprecated. You should use chart.getLink().getUrl instead.

    See Also:
    ChartCore.getLink()

    getURLOptions

    public int getURLOptions()
    Deprecated. You should use chart.getLink().getReload instead.

    See Also:
    ChartCore.getLink()

    getURLParamMask

    public java.lang.String getURLParamMask()
    Deprecated. You should use chart.getLink().getUrl instead.

    See Also:
    ChartCore.getLink()

    getURLTarget

    public java.lang.String getURLTarget()
    Deprecated. You should use chart.getLink().getTarget instead.

    See Also:
    ChartCore.getLink()

    getWidth

    public int getWidth()

    Gets the Width. For more detail see setWidth(int).


    isEmbeddedData

    public boolean isEmbeddedData()

    Gets the EmbeddedData. For more detail see setEmbeddedData(boolean).


    isImgSizeable

    public boolean isImgSizeable()

    Gets the ImgSizeable. For more detail see setImgSizeable(boolean).


    isMainClient

    public boolean isMainClient()

    Gets the MainClient. For more detail see setMainClient(boolean).


    loadDefault

    public void loadDefault(int n)

    Reload the inifiles making effective the changes you have made on those files without the need of stopping or rebooting the server.

    Remarks:
  • The Chart FX Server component provides a method call LoadDefault, when invoked, it will force the Chart FX Server component to reload the inifiles making effective the changes you have made on those files without the need of stopping or rebooting the server.

  • The LoadDefault method must be invoked only once. This will cause the Server Component to reload the configuration (ini) files which is a major advantage over stopping the web server or rebooting the Operating system. Therefore, we suggest you create a utilitarian asp that reloads the ini file instead of including this method call in any asp that contains a chart. If you leave this method call in the asp page that creates the chart, the Chart FX ini files will be loaded every time you execute this asp causing a performance problem.

  • Parameters:
    n - Integer specifying whether to update
    See Also:
    Chart

    setConfigPath

    public void setConfigPath(java.lang.String path)

    Sets the path for the location of the configuration files.

    Remarks:
  • Chart FX requires 2 files to properly function: ChartFX.Internet.config (configuration) and cfxjava.lic (license).

  • These files are usually located in the WEB-INF\lib folder of the web application, or starting in the 6.2 version, in the chartfx62/config folder. There is a build in mechanism that looks for these files in the context of the web application.

  • If these files must be located outside of the web application context, for example in a web-farm scenario, the setConfigPath method should be used. For example:

    Chart1.setConfigPath("c:\\configfiles\chartfx");

  • Parameters:
    path - The physical path where the configuration files are located.

    setEmbeddedData

    public void setEmbeddedData(boolean value)

    Gets or sets a value specifying if chart data will be embedded in the resulting html.

    Remarks:
  • You MUST set the setMainClient(boolean) property to False to use EmbeddedData.

  • This boolean property instructs Chart FX to embed the data used for the chart into the one resulting HTML page. There are several advantages to this scenario:

    1) No Temporary files left on server. By default, chart files (Chart data) are generated on the server in the form of a file and downloaded separately.

    2) This makes the data as secure as the page (i.e. SSL).

    3) No round trip to download the chart data file.

    One disadvange is when generating charts will a large number of data points is that the encoded data string can be very long. When a page is loaded, unexpected resizing may be visible, however, the resulting page should look correct.

  • The setMainClient(boolean) property allows you to control the MainClient assembly usage. The MainClient assembly was implemented to increase the performance of the .NET Client Component in WebForm applications. Setting the MainClient to False will force the download of the core client assembly by the client ever session. When MainClient is True, a smaller assembly is downloaded per session. However, some functionality such as EmbeddedData and using Client Side events requires that MainClient is set to false.

  • See Also:
    setMainClient(boolean)

    setFont

    public void setFont(java.awt.Font value)

    Allows you to change the font attributes for the entire chart.

    Remarks:
  • The Font property is used to change the font settings for the axis labels, titles, point labels or any other text contained in the chart.

  • When setting a font in Chart FX, you must create a new font object with the desired attributes and assign that object to the desired chart element every time you want to change the font.

  • For more information regarding the Font type, please refer to the Java API Documentation.

  • See Also:
    Axis.setFont(java.awt.Font), ConstantLine.setFont(java.awt.Font), DataEditor.setFont(java.awt.Font), LegendBoxBase.setFont(java.awt.Font), Title.setFont(java.awt.Font), Axis, ConstantLine, DataEditor, LegendBox, Title

    setHeight

    public void setHeight(int value)

    Specifies the suggested height of the chart when generating images.

    Remarks:
  • You may also set the dimensions for the image generated using the setImgHeight(int) and setImgWidth(int) properties.

  • This property allows you to configure the height of the image using units other than pixels.

  • For more information regarding the dimension classes, please refer to the Java API Documentation.

  • See Also:
    setImgHeight(int), setImgWidth(int)

    setHtmlTag

    public void setHtmlTag(java.lang.String value)

    Allows you to select the type of tag generated by ChartFX.

    Remarks:
  • The possible options are: ".NET", "Image", "Jpeg", "Png", "SVG" or "Auto". In Automatic mode ChartFX will use the HTTP_USER_AGENT variable and to determine the appropriate tag compatible with the browser being used by the user. If no value is specified, The default setting is Image.

  • By default, Chart FX generates charts as images when working with web applications. You can force Chart FX to generate active charts on the client, as an ActiveX or a .NET component, by setting the HtmlTag property to ".NET", "ActiveX' or "Auto".

  • See Also:
    setImgQuality(int), setImgSizeable(boolean), getHtmlTag()

    setID

    public void setID(java.lang.String ID)

    Sets the Map name for the Image Map.

    Remarks:
  • When using Image Maps, there is a direct link betwen the Image Tag and the Image Map, as shown in the following example:
    <MAP name="Chart1">
    ...
    </MAP>
    <IMG SRC="chart_image.png" WIDTH="450" HEIGHT="280" usemap="#Chart1" border="0">

  • But when the getHtmlDataEx(java.lang.Object, java.lang.Object, java.lang.String, java.io.OutputStream, java.io.OutputStream, java.io.OutputStream) method is used to create the image and its image map, it is necesary to assing a Map name by using the setID method as shown in the sample below:

    Chart chart1 = new Chart();
    chart1.setImgMap(ImgMap.TITLE_TIP);
    chart1.setTipMask("Value is %v");
    chart1.setID("MyChart");

    ByteArrayOutputStream image = new ByteArrayOutputStream();
    java.io.ByteArrayOutputStream mapStream = new java.io.ByteArrayOutputStream();
    java.io.ByteArrayOutputStream tagStream = new java.io.ByteArrayOutputStream();

    chart1.getHtmlDataEx("600","400","PNG", imgStream,mapStream,tagStream);

    This will generate a image map with the name "MyChart":

    <MAP name="MyChart">

    and a IMG tag with the equivalent usempap

    <IMG ... usemap="#MyChart" border="0">


  • setImgHeight

    public void setImgHeight(int value)

    Specifies the suggested height of the chart when generating images.

    Remarks:
  • This property will only be used if an image is generated by Chart FX. If you plan to use a client component on the browser, you may set the setHeight(int) and setWidth(int) to set the height and width of the chart.

  • You can specify for Chart FX to generate an image or use an active component using the setHtmlTag(java.lang.String) property.

  • If generating an image, you can use the setImgTags(java.lang.String) property to include additional attributes in the image tags.

  • The configured value will set the height of the image in pixels.

  • See Also:
    setHeight(int), setWidth(int), setHtmlTag(java.lang.String), setImgTags(java.lang.String), getHtmlTag()

    setImgMap

    public void setImgMap(int value)

    Allows you to control how ToolTip will appear in the chart area.

    Values:
    ImgMap : ImgMap
    ValueDescription
    ImgMap.TITLE_TIPUsed to display tooltips specifically for MicroSoft Internet Explorer.
    ImgMap.MOUSE_TIPAllows you to invoke a javascript to show the Tooltip on any browser.
    ImgMap.URL_TIPMust be turned on to view tooltip over a chart URL. By default this flag is turned on.
    ImgMap.EMBEDDEDForces ChartFX to return the ImgMap as part of the GetHtmlTag.
    ImgMap.HAS_URLSFor internal use.
    ImgMap.EVENTHandle per Click event.
    ImgMap.NO_CONNECTEDOnly the Image Map tag and name will be generated.
    ImgMap.ENCODE_TIPWhen using the MouseTip event, allows you to add html tags in the tooltips.
    ImgMap.FORCE_EVENTFor internal use.

    Remarks:
  • When the MouseTip enumeration is selected for the ImgMap, a javascript will be added in your code to show a tooltip for any browser. It will add the following function calls to the AREA tag:

    onmouseover="popupon('<ToolTip>',event)"
    : this function will be called when the mouse passes over the Image Map area.

    onmouseout="popupoff()"
    : this function will be called when the mouse abandons the Image Map area.

    You will be responsible for the implementation of these functions.

  • See Also:
    ChartCore.setShowTips(boolean)

    setImgQuality

    public void setImgQuality(int value)

    Allows you to set the image quality for generated Jpeg chart images.

    Remarks:
  • This property only applies when generated charts are Jpeg format. Other formats do not support this feature.

  • This property receives an integer between 0 and 100. Zero being the default setting, 1 being low quality and 100 being best quality.

  • You may set the format of generated charts using the setHtmlTag(java.lang.String) property.

  • See Also:
    setHtmlTag(java.lang.String), getHtmlTag(), getHtmlData(java.lang.Object, java.lang.Object, java.lang.String)

    setImgSizeable

    public void setImgSizeable(boolean value)

    Allows you to specify if Chart images will be based on pixels or percentages.

    Remarks:
  • ImgSizeable True means Chart FX will generate the image tag with the Width/Height generated as percentages.

  • ImgSizeable False means Chart FX will generate the image tag with pixel sizes, but object tags could still be generated as percentages.

  • See Also:
    setImgHeight(int), setImgWidth(int), setImgQuality(int), setImgTags(java.lang.String)

    setImgTags

    public void setImgTags(java.lang.String value)

    A string property that will be appended to the IMG tag created by Chart FX.

    Remarks:
  • This property is very useful when you would like to modify the <IMG> tag created by Chart FX. For example, if you wanted to add "Border = 0" attribute to the image tag where the chart is displayed you can do so with this property.

  • This property also is used in conjunction with the ChartCore.exportChart(int, java.lang.String) and ChartCore.importChart(int, java.lang.String) methods. When the exportChart or importChart file fomats are set to External, Chart FX will read the ImgTags string looking for a file extension (e.g. svg). Chart FX will generate the chart in the desired format using an image writer. This will allow Chart FX to add additional image formats to the charting component by including another writer.

  • See Also:
    getHtmlTag(), ChartCore.importChart(int, java.lang.String), ChartCore.exportChart(int, java.lang.String)

    setImgWidth

    public void setImgWidth(int value)

    Specifies the suggested width of the chart when generating images.

    Remarks:
  • This property will only be used if an image is generated by Chart FX. If you plan to use an an active component on the browser, you may set the setHeight(int) and setWidth(int) to set the height and width of the chart.

  • You can specify for Chart FX to generate an image or use an active component using the setHtmlTag(java.lang.String) property.

  • If generating an image, you can use the setImgTags(java.lang.String) property to include additional attributes in the image tags.

  • The configured value will set the width of the image in pixels.

  • See Also:
    setHeight(int), setWidth(int), setHtmlTag(java.lang.String), setImgTags(java.lang.String), getHtmlTag()

    setMainClient

    public void setMainClient(boolean value)

    Gets or sets a value indicating whether to generate an object with a small "wrapper" control for faster downloads when generating .NET Client Controls.

    Remarks:
  • Web applications generating charts as .NET Client Controls as opposed to images take additional time to generate and download all the required components. This wait time can be associated with the connection speed of the end user as well as the process which the Microsoft .NET Framework utilizes in order to display .NET controls on the client computer.

    The first time a browser encounters a .NET control in a page it has to load the .NET framework at the client machine; in addition the "main" control (in this case the Chart FX .NET Internet Client Control) is downloaded to compare against the version in the download cache (this is done on a per-session basis).

    In order to prevent the entire Chart FX .NET Internet Client Control from being downloaded each time, a smaller wrapper control is downloaded with the version information and is compared to the version of the Chart FX .NET Internet Client Control in the downloaded cache. If the version is compatible, the control in cache is used instead of requiring another download.

    To change the Chart FX behavior so your charts generate an object with a small "wrapper" control, you can set the MainClient property of the chart (in your script) to true.

    chart1.setMainClient(true);

  • On some slower connections, we have measured an improvement from 30 seconds to about 7 seconds (on the first hit of a browser session).

  • See Also:
    setHtmlTag(java.lang.String)

    setOutputWriter

    public void setOutputWriter(IOutputWriter value)

    Allows you to select a specific external output writer for generating chart images.

    Remarks:
  • In order to property configure this property, you will need to add the chart writer component to your chart. Once you have done so, you may assign this property the name of the instance of the output writer. Chart FX will then use that output writer to generate the chart. The idea is to be able to add additional output writers to the product as the demand for a particular output format increases.

  • If you would like to generate a SVG without using this property, you may do so by adding the SVG writer assembly (ChartFX.Writer.SVG.dll) as a reference to the project and setting the setHtmlTag(java.lang.String) property to 'SVG'.

  • See Also:
    setHtmlTag(java.lang.String)

    setProxyUri

    public void setProxyUri(java.lang.String value)

    Used to add the Proxy URI of a proxy server.

    Remarks:
  • This property should only be used when generating an Active Chart (.NET or ActiveX).

  • You may configure this property to an empty string instructing Chart FX to try and obtain the correct proxy for the Java API installed. However, for this feature to work, Chart FX requires Full Trust in the .NET security settings for the client computer accessing the control.

    chart1.setProxiUri("your_proxy_uri");

  • Unfortunately, PAC files are not supported for Chart FX.

  • See Also:
    setHtmlTag(java.lang.String), Chart

    setURL

    public void setURL(java.lang.String value)
    Deprecated. You should use chart.getLink().setUrl instead.

    See Also:
    ChartCore.getLink()

    setURLOptions

    public void setURLOptions(int value)
    Deprecated. You should use chart.getLink().setReload instead.

    See Also:
    ChartCore.getLink()

    setURLParamMask

    public void setURLParamMask(java.lang.String value)
    Deprecated. You should use chart.getLink().setUrl instead.

    See Also:
    ChartCore.getLink()

    setURLTarget

    public void setURLTarget(java.lang.String value)
    Deprecated. You should use chart.getLink().setTarget instead.

    See Also:
    ChartCore.getLink()

    setWidth

    public void setWidth(int value)

    Specifies the suggested width of the chart when generating images.

    Remarks:
  • You may also set the dimensions for the image generated using the setImgHeight(int) and setImgWidth(int) properties.

  • This property allows you to configure the width of the image using units other than pixels.

  • For more information regarding the dimension classes, please refer to the Java API Documentation.

  • See Also:
    setImgHeight(int), setImgWidth(int)

    http://www.softwarefx.com

    2007 Software FX, Inc. All Rights Reserved. Chart FX is a registered trademark of Software FX, Inc
    All other names are trademarks or registered trademarks of their respective owners.