com.steema.teechart
Class TChart

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by com.steema.teechart.TChart
All Implemented Interfaces:
IChart, java.awt.datatransfer.ClipboardOwner, java.awt.datatransfer.Transferable, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener
Direct Known Subclasses:
GalleryChart, InnerChart

public class TChart
extends javax.swing.JComponent
implements java.io.Serializable, IChart, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener, java.awt.datatransfer.Transferable, java.awt.datatransfer.ClipboardOwner

Title: TChart class

Description: Principle Chart class for Windows based forms

Copyright (c) 2005-2013 by Steema Software SL. All Rights Reserved.

Company: Steema Software SL

See Also:
Serialized Form

Nested Class Summary
static interface TChart.Scrollable
           
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
protected  AxisLabelResolver axisLabelResolver
           
protected  LegendResolver legendResolver
           
 Point mousePosition
           
protected  TChart.Scrollable scrollable
           
 
Fields inherited from class javax.swing.JComponent
accessibleContext, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
TChart()
           
 
Method Summary
 void addChartListener(ChartListener l)
           
 void addChartMotionListener(ChartMotionListener l)
           
 void addChartMouseListener(ChartMouseListener l)
           
 void addChartPaintListener(ChartPaintListener l)
           
 void addChartPrintListener(ChartPrintListener l)
           
 Series addSeries(Series s)
          Adds a new Series.
 void addSeriesMouseListener(SeriesMouseListener l)
           
 void checkBackground(java.lang.Object sender, FrameworkMouseEvent e)
           
 boolean checkClickSeries()
           
 Graphics3D checkGraphics()
           
 void checkTitle(Title aTitle, FrameworkMouseEvent e, ClickedParts c)
           
 void copyToClipboard(java.lang.Object object)
           
 javax.swing.JToolTip createToolTip()
           
 void dispose()
          Cleans up any resources being used.
 void doAfterDraw()
           
 void doAfterDrawSeries()
           
 void doAllowScroll(Axis a, double delta, ScrollResult result)
           
 void doBaseInvalidate()
           
 void doBeforeDraw()
           
 void doBeforeDrawAxes()
           
 void doBeforeDrawSeries()
           
 void doChartPrint()
           
 void doClickAxis(Axis a, FrameworkMouseEvent e)
           
 void doClickLegend(Legend legend, FrameworkMouseEvent e)
           
 void doClickSeries(java.lang.Object sender, Series s, int valueIndex, FrameworkMouseEvent e)
           
 void doDrawImage(IGraphics3D g)
           
 void doInvalidate()
           
 void doScroll(java.lang.Object sender)
           
 void doSetBuffered(boolean value)
           
 void doUnZoomed(java.lang.Object sender)
           
 void doZoomed(java.lang.Object sender)
           
 void exchangeSeries(int series1, int series2)
          Deprecated.  
protected  void fireChartAdded(ChartEvent e)
           
protected  boolean fireChartClicked(ChartMouseEvent e)
           
protected  void fireChartMotion(ChartEvent e)
           
protected  void fireChartPaint(ChartDrawEvent e)
           
protected  void fireChartPrint(ChartDrawEvent ce)
           
protected  void fireSeriesClick(SeriesMouseEvent seriesClickEvent)
           
 boolean getApplyZOrder()
          Deprecated.  
 Aspect getAspect()
          Accesses view characteristics of the Chart.
 boolean getAutoRepaint()
          Enables/Disables repainting of Chart when points are added.
 Axes getAxes()
          Collection of predefined and custom axis objects.
 AxisLabelResolver getAxisLabelResolver()
           
 Color getBackColor()
          The color the Chart rectangle is filled with.
 java.awt.Color getBackground()
          Gets the colour of the Chart background.
 Image getBackgroundImage()
          Returns background image of TChart
 IGraphics3D getCanvas()
          Deprecated.  
 Chart getChart()
          Defines the Chart to display.
 boolean getClipPoints()
          Deprecated.  
 java.lang.Object getControl()
           
 int getControlHeight()
           
 int getControlWidth()
           
 Exports getExport()
          Accesses Chart export attributess.
 java.awt.Font getFont()
          Determines the Font characteristics.
 Footer getFooter()
          Defines Text shown at the bottom of the Chart.
 java.awt.Color getForeground()
          Determines the Foreground color.
 ChartPen getFrame()
          Use TChart.
 Point getGetCursorPos()
          Deprecated.  
 IGraphics3D getGraphics3D()
          Used to access TeeChart Draw attributes.
 Header getHeader()
          Defines the Text and formatting properties to be drawn at the top of the Chart.
 Image getImage()
          Return an image of the rendered Chart as Image.
 Imports getImport()
          Accesses Chart import attributes.
 Legend getLegend()
          Legend characteristics.
 LegendResolver getLegendResolver()
           
 boolean getMetafiling()
          True when the Chart is internally drawing into a Metafile image.
 Page getPage()
          Accesses multiple page characteristics of the Chart.
 Panel getPanel()
          Background visible attributes.
 Scroll getPanning()
          Accesses Panning characteristics.
 Dimension getPreferredSize()
           
 Printer getPrinter()
          Printing related attributes.
 boolean getPrinting()
          Determines which Chart is being printed.
 int getScreenHeight()
           
 int getScreenWidth()
           
 SeriesCollection getSeries()
          Collection of Series contained in this Chart.
 Series getSeries(int index)
          Default indexer.
 int getSeriesCount()
          Returns the number of Series in Chart.
 Footer getSubFooter()
          Defines Text shown directly above Footer.
 Header getSubHeader()
          Defines Text shown directly below Header.
 Cursor getTeeCursor()
          Returns the current active Cursor.
 java.lang.String getText()
          The text for the Footer, Header, SubFooter and SubHeader.
 ToolsCollection getTools()
          Collection of Tool components contained in this Chart.
 java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor flavor)
           
 java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
           
 Walls getWalls()
          Accesses left, bottom and back wall characteristics of the Chart.
 Zoom getZoom()
          Accesses the Zoom characteristics of the Chart.
 Image image(int width, int height)
          Return an image of the rendered Chart as Image.
 Image internalImage(int width, int height)
           
 boolean invertedRotation()
           
 boolean isDataFlavorSupported(java.awt.datatransfer.DataFlavor flavor)
           
 boolean isDesignTime()
           
 boolean isDisposing()
           
 boolean isDoubleBuffered()
           
 boolean isOpaque()
           
 void lostOwnership(java.awt.datatransfer.Clipboard arg0, java.awt.datatransfer.Transferable arg1)
           
 void mouseDragged(java.awt.event.MouseEvent e)
           
 void mouseMoved(java.awt.event.MouseEvent e)
          Captures current mouse position every time the mouse is moved.
 void mouseWheelMoved(java.awt.event.MouseWheelEvent e)
           
 void paint(java.awt.Graphics g, int width, int height)
           
 void paint(java.awt.Graphics g, Rectangle rectangle)
           
protected  void paintComponent(java.awt.Graphics g)
           
 Point pointToScreen(Point p)
           
protected  void processMouseEvent(java.awt.event.MouseEvent e)
           
protected  void processMouseMotionEvent(java.awt.event.MouseEvent e)
           
protected  void processMouseWheelEvent(java.awt.event.MouseWheelEvent e)
           
 void refreshControl()
           
 void removeAllSeries()
          Removes all Series.
 void removeAxisLabelResolver()
           
 void removeChartListener(ChartListener l)
           
 void removeChartMotionListener(ChartMotionListener l)
           
 void removeChartMouseListener(ChartMouseListener l)
           
 void removeChartPaintListener(ChartPaintListener l)
           
 void removeChartPrintListener(ChartPrintListener l)
           
 void removeLegendResolver()
           
 void removeScrollable()
           
 void removeSeriesMouseListener(SeriesMouseListener l)
           
 void setApplyZOrder(boolean value)
          Deprecated.  
 void setAutoRepaint(boolean value)
          Enables/Disables repainting of Chart when points are added.
 void setAxes(Axes axes)
          Collection of predefined and custom axis objects.
 void setAxisLabelResolver(AxisLabelResolver resolver)
           
 void setBackColor(java.awt.Color value)
          The color the Chart rectangle is filled with.
 void setBackColor(Color value)
          Sets the color the Chart rectangle is filled with.
 void setBackground(Color value)
           
 void setBackground(java.awt.Color value)
          Sets the colour of the Chart background.
 void setCanvas(IGraphics3D value)
          Deprecated.  
 void setChart(Chart value)
          Defines the Chart to display.
 void setChart(IChart value)
           
 void setClipPoints(boolean value)
          Obsolete.
 void setCursor(Cursor c)
           
 void setDisposing(boolean value)
           
 void setFont(java.awt.Font font)
          Determines the Font characteristics.
 void setFooter(Footer footer)
          Defines Text shown at the bottom of the Chart.
 void setGraphics3D(IGraphics3D value)
          Used to access TeeChart Draw attributes.
 void setHeader(Header header)
          Sets the text for the Footer, Header, SubFooter and SubHeader.
 void setHeight(int value)
          Sets the Height of the Image.
 void setLegend(Legend legend)
          Legend characteristics.
 void setLegendResolver(LegendResolver resolver)
           
 void setOpaque(boolean value)
           
 void setPage(Page page)
          Accesses multiple page characteristics of the Chart.
 void setPanel(Panel panel)
          The color the Chart rectangle is filled with.
 void setPanning(Scroll panning)
          Accesses Panning characteristics.
 void setPreferredSize(Dimension dim)
           
 void setPrinter(Printer printer)
          Printing related attributes.
 void setPrinting(boolean value)
          Determines which Chart is being printed.
 void setScrollable(TChart.Scrollable scrollable)
           
 void setSeries(int index, Series value)
          Collection of Series contained in this Chart.
 void setSeries(SeriesCollection series)
           
 void setSubFooter(Footer subFooter)
          Defines Text shown directly above Footer.
 void setSubHeader(Header subHeader)
          Defines Text shown directly below Header.
 void setText(java.lang.String value)
          Sets the text for the Footer, Header, SubFooter and SubHeader.
 void setTools(ToolsCollection value)
          Collection of Tool components contained in this Chart.
 void setToolTip(ToolTip tool, java.lang.String text)
           
 void setWalls(Walls walls)
          Accesses left, bottom and back wall characteristics of the Chart.
 void setWidth(int value)
          Sets the Width of the Image.
 void setZoom(Zoom zoom)
          Accesses the Zoom characteristics of the Chart.
 void showEditor()
          Shows the TeeChart editor dialog.
 void timerExec(int time, java.lang.Runnable runnable)
           
 Chart xmlDecode(java.io.InputStream stream)
           
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isLightweightComponent, isManagingFocus, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.steema.teechart.IChart
getGraphics
 

Field Detail

mousePosition

public Point mousePosition

scrollable

protected TChart.Scrollable scrollable

axisLabelResolver

protected transient AxisLabelResolver axisLabelResolver

legendResolver

protected transient LegendResolver legendResolver
Constructor Detail

TChart

public TChart()
Method Detail

addChartListener

public void addChartListener(ChartListener l)

removeChartListener

public void removeChartListener(ChartListener l)

addChartMouseListener

public void addChartMouseListener(ChartMouseListener l)

removeChartMouseListener

public void removeChartMouseListener(ChartMouseListener l)

addChartMotionListener

public void addChartMotionListener(ChartMotionListener l)

removeChartMotionListener

public void removeChartMotionListener(ChartMotionListener l)

addChartPaintListener

public void addChartPaintListener(ChartPaintListener l)

removeChartPaintListener

public void removeChartPaintListener(ChartPaintListener l)

addChartPrintListener

public void addChartPrintListener(ChartPrintListener l)

removeChartPrintListener

public void removeChartPrintListener(ChartPrintListener l)

addSeriesMouseListener

public void addSeriesMouseListener(SeriesMouseListener l)

removeSeriesMouseListener

public void removeSeriesMouseListener(SeriesMouseListener l)

fireSeriesClick

protected void fireSeriesClick(SeriesMouseEvent seriesClickEvent)

fireChartAdded

protected void fireChartAdded(ChartEvent e)

fireChartClicked

protected boolean fireChartClicked(ChartMouseEvent e)

fireChartMotion

protected void fireChartMotion(ChartEvent e)

fireChartPaint

protected void fireChartPaint(ChartDrawEvent e)

fireChartPrint

protected void fireChartPrint(ChartDrawEvent ce)

getPreferredSize

public Dimension getPreferredSize()
Overrides:
getPreferredSize in class javax.swing.JComponent

setPreferredSize

public void setPreferredSize(Dimension dim)

isDisposing

public boolean isDisposing()
Specified by:
isDisposing in interface IChart

setDisposing

public void setDisposing(boolean value)
Specified by:
setDisposing in interface IChart

dispose

public void dispose()
Cleans up any resources being used.

Parameters:
disposing - boolean

getPrinting

public boolean getPrinting()
Determines which Chart is being printed.

Returns:
boolean

setPrinting

public void setPrinting(boolean value)
Determines which Chart is being printed.

Parameters:
value - boolean

getMetafiling

public boolean getMetafiling()
True when the Chart is internally drawing into a Metafile image.

Returns:
boolean

getClipPoints

public boolean getClipPoints()
Deprecated. 

Obsolete. Please use Aspect.ClipPoints instead.

Returns:
boolean

setClipPoints

public void setClipPoints(boolean value)
Obsolete. Please use Aspect.ClipPoints instead.

Parameters:
value - boolean

getApplyZOrder

public boolean getApplyZOrder()
Deprecated. 

Obsolete. Please use getSeries.getApplyZOrder() instead.

Returns:
boolean

setApplyZOrder

public void setApplyZOrder(boolean value)
Deprecated. 

Obsolete. Please use getSeries().setApplyZOrder() instead.

Parameters:
value - boolean

getBackColor

public Color getBackColor()
The color the Chart rectangle is filled with.
The chart rectangle is the screen area between axes.
Setting BackColor to Color.EMPTY does not fill the rectangle.
Assigning Color.EMPTY to tChart.getBackColor() makes TeeChart NOT fill the Chart back area, so Gradient fills and Background Bitmaps can be shown.

Returns:
Color

setBackColor

public void setBackColor(java.awt.Color value)
The color the Chart rectangle is filled with.
The chart rectangle is the screen area between axes.
Setting BackColor to Color.EMPTY does not fill the rectangle.
Assigning Color.EMPTY to tChart.getBackColor() makes TeeChart NOT fill the Chart back area, so Gradient fills and Background Bitmaps can be shown.

Parameters:
value -

setBackColor

public void setBackColor(Color value)
Sets the color the Chart rectangle is filled with.

Parameters:
value - Color

setBackground

public void setBackground(Color value)

getBackground

public java.awt.Color getBackground()
Gets the colour of the Chart background.

Overrides:
getBackground in class java.awt.Component
Returns:

setBackground

public void setBackground(java.awt.Color value)
Sets the colour of the Chart background.

Overrides:
setBackground in class javax.swing.JComponent
Parameters:
value -

mouseDragged

public void mouseDragged(java.awt.event.MouseEvent e)
Specified by:
mouseDragged in interface java.awt.event.MouseMotionListener

mouseMoved

public void mouseMoved(java.awt.event.MouseEvent e)
Captures current mouse position every time the mouse is moved.

Specified by:
mouseMoved in interface java.awt.event.MouseMotionListener
Parameters:
e - MouseEvent

getGetCursorPos

public Point getGetCursorPos()
Deprecated. 

Obsolete. Please use mousePosition field instead.

Returns:
Point

addSeries

public Series addSeries(Series s)
Adds a new Series.

Parameters:
s - Series
Returns:
Series

getAutoRepaint

public boolean getAutoRepaint()
Enables/Disables repainting of Chart when points are added.
Use AutoRepaint false to disable Chart repainting whilst, for example, adding a large number of points to a Chart Series. This avoids repainting of the Chart whilst the points are added.
AutoRepaint may be re-enabled, followed by a manual Repaint command when all points are added.
Default value: true

Returns:
boolean

setAutoRepaint

public void setAutoRepaint(boolean value)
Enables/Disables repainting of Chart when points are added.
Default value: true

Parameters:
value - boolean
See Also:
getAutoRepaint()

image

public Image image(int width,
                   int height)
Return an image of the rendered Chart as Image.

Specified by:
image in interface IChart
Returns:

setHeight

public void setHeight(int value)
Sets the Height of the Image.

Parameters:
value -

setWidth

public void setWidth(int value)
Sets the Width of the Image.

Parameters:
value -

removeAllSeries

public void removeAllSeries()
Removes all Series.


exchangeSeries

public void exchangeSeries(int series1,
                           int series2)
Deprecated. 

Obsolete. Use TChart.Series.Exchange() instead.

Parameters:
series1 - int
series2 - int

getFrame

public ChartPen getFrame()
Use TChart.getWalls()getPen() instead.

Returns:
ChartPen

getSeriesCount

public int getSeriesCount()
Returns the number of Series in Chart.

Returns:
int

setScrollable

public void setScrollable(TChart.Scrollable scrollable)

removeScrollable

public void removeScrollable()

getBackgroundImage

public Image getBackgroundImage()
Returns background image of TChart

Returns:
Image

doDrawImage

public void doDrawImage(IGraphics3D g)
Specified by:
doDrawImage in interface IChart

paint

public void paint(java.awt.Graphics g,
                  Rectangle rectangle)

paint

public void paint(java.awt.Graphics g,
                  int width,
                  int height)

paintComponent

protected void paintComponent(java.awt.Graphics g)
Overrides:
paintComponent in class javax.swing.JComponent

doBeforeDrawAxes

public void doBeforeDrawAxes()
Specified by:
doBeforeDrawAxes in interface IChart

doAfterDrawSeries

public void doAfterDrawSeries()
Specified by:
doAfterDrawSeries in interface IChart

doBeforeDrawSeries

public void doBeforeDrawSeries()
Specified by:
doBeforeDrawSeries in interface IChart

doAfterDraw

public void doAfterDraw()
Specified by:
doAfterDraw in interface IChart

doBeforeDraw

public void doBeforeDraw()
Specified by:
doBeforeDraw in interface IChart

doClickSeries

public void doClickSeries(java.lang.Object sender,
                          Series s,
                          int valueIndex,
                          FrameworkMouseEvent e)
Specified by:
doClickSeries in interface IChart

doAllowScroll

public void doAllowScroll(Axis a,
                          double delta,
                          ScrollResult result)
Specified by:
doAllowScroll in interface IChart

setAxisLabelResolver

public void setAxisLabelResolver(AxisLabelResolver resolver)
Specified by:
setAxisLabelResolver in interface IChart

removeAxisLabelResolver

public void removeAxisLabelResolver()
Specified by:
removeAxisLabelResolver in interface IChart

getAxisLabelResolver

public AxisLabelResolver getAxisLabelResolver()
Specified by:
getAxisLabelResolver in interface IChart

setLegendResolver

public void setLegendResolver(LegendResolver resolver)

removeLegendResolver

public void removeLegendResolver()

getLegendResolver

public LegendResolver getLegendResolver()
Specified by:
getLegendResolver in interface IChart

doChartPrint

public void doChartPrint()
Specified by:
doChartPrint in interface IChart

doClickAxis

public void doClickAxis(Axis a,
                        FrameworkMouseEvent e)
Specified by:
doClickAxis in interface IChart

checkBackground

public void checkBackground(java.lang.Object sender,
                            FrameworkMouseEvent e)
Specified by:
checkBackground in interface IChart

checkGraphics

public Graphics3D checkGraphics()
Specified by:
checkGraphics in interface IChart

checkTitle

public void checkTitle(Title aTitle,
                       FrameworkMouseEvent e,
                       ClickedParts c)
Specified by:
checkTitle in interface IChart

doClickLegend

public void doClickLegend(Legend legend,
                          FrameworkMouseEvent e)
Specified by:
doClickLegend in interface IChart

doScroll

public void doScroll(java.lang.Object sender)
Specified by:
doScroll in interface IChart

doZoomed

public void doZoomed(java.lang.Object sender)
Specified by:
doZoomed in interface IChart

doSetBuffered

public void doSetBuffered(boolean value)
Specified by:
doSetBuffered in interface IChart

doUnZoomed

public void doUnZoomed(java.lang.Object sender)
Specified by:
doUnZoomed in interface IChart

getTeeCursor

public Cursor getTeeCursor()
Returns the current active Cursor.

Specified by:
getTeeCursor in interface IChart
Returns:

setChart

public void setChart(Chart value)
Defines the Chart to display.

Parameters:
value - Chart

setAxes

public void setAxes(Axes axes)
Collection of predefined and custom axis objects.

Parameters:
axes -

setFooter

public void setFooter(Footer footer)
Defines Text shown at the bottom of the Chart.
Use Text to enter the desired Footer lines, set Visible to True and change the Font, Frame and Brush methods.
Use Alignment to control text output position.

Parameters:
footer -

setFont

public void setFont(java.awt.Font font)
Determines the Font characteristics.

Overrides:
setFont in class javax.swing.JComponent
Parameters:
font -

setHeader

public void setHeader(Header header)
Sets the text for the Footer, Header, SubFooter and SubHeader.

Parameters:
header -

setLegend

public void setLegend(Legend legend)
Legend characteristics.
The Legend property determines the text and drawing attributes of Chart's textual representation of Series and Series values.
The Legend class draws a rectangle and for each Series in a Chart (or for each point in a Series) outputs a text representation of that Series (or that point).
You can use the Legend.LegendStyle and Legend.TextStyle properties to control the text used to draw the legend.
The Legend can be positioned at Left, Right, Top and Bottom chart sides using the Legend.Alignment property.
Use the Legend.Visible property to show / hide the Legend.
The Inverted property makes Legend to draw text starting from bottom.
The Frame, Font and Color properties allow you to change Legend appearance.
The Legend.ColorWidth property determines the percent width of each item's "colored" mark.
The Legend.FirstValue property controls which Series (or Series point) will be used to draw first Legend item.

Parameters:
legend -

setSubFooter

public void setSubFooter(Footer subFooter)
Defines Text shown directly above Footer.
Use Text to enter the desired SubFooter lines, set Visible to True and change the Font, Frame and Brush methods.
Use Alignment to control text output position.

Parameters:
subFooter -

setSubHeader

public void setSubHeader(Header subHeader)
Defines Text shown directly below Header.
Use the Text method to enter the desired SubHeader lines, set Visible to True and change the Font, Frame and Brush methods.
Use the Alignment method to control text output position.

Parameters:
subHeader -

setWalls

public void setWalls(Walls walls)
Accesses left, bottom and back wall characteristics of the Chart.

Parameters:
walls -

setZoom

public void setZoom(Zoom zoom)
Accesses the Zoom characteristics of the Chart.

Parameters:
zoom -

setSeries

public void setSeries(SeriesCollection series)

setPrinter

public void setPrinter(Printer printer)
Printing related attributes.

Parameters:
printer -

setPanning

public void setPanning(Scroll panning)
Accesses Panning characteristics.

Scrolling speed depends on:
The number of Series and Series Points.
The Chart Width and Height.
The computer processor and Video card processor speed.
The Video resolution and number of colors.
The Windows version and the Video driver.
The speed when dragging the mouse !

Parameters:
panning -

setPanel

public void setPanel(Panel panel)
The color the Chart rectangle is filled with.
The chart rectangle is the screen area between axes.
Setting BackColor to Color.EMPTY does not fill the rectangle.
Assigning Color.EMPTY to tChart.getBackColor() makes TeeChart NOT fill the Chart back area, so Gradient fills and Background Bitmaps can be shown.

Parameters:
panel -

setPage

public void setPage(Page page)
Accesses multiple page characteristics of the Chart.

Parameters:
page -

setChart

public void setChart(IChart value)

getControl

public java.lang.Object getControl()
Specified by:
getControl in interface IChart

getControlHeight

public int getControlHeight()
Specified by:
getControlHeight in interface IChart

getControlWidth

public int getControlWidth()
Specified by:
getControlWidth in interface IChart

doInvalidate

public void doInvalidate()
Specified by:
doInvalidate in interface IChart

doBaseInvalidate

public void doBaseInvalidate()

pointToScreen

public Point pointToScreen(Point p)
Specified by:
pointToScreen in interface IChart

setCursor

public void setCursor(Cursor c)
Specified by:
setCursor in interface IChart

refreshControl

public void refreshControl()
Specified by:
refreshControl in interface IChart

createToolTip

public javax.swing.JToolTip createToolTip()
Overrides:
createToolTip in class javax.swing.JComponent

internalImage

public Image internalImage(int width,
                           int height)

showEditor

public void showEditor()
Shows the TeeChart editor dialog. Displays the Chart Editor at runtime opening the Editor at the Series page of the SeriesIndex Series.


getChart

public Chart getChart()
Defines the Chart to display.

Returns:
Chart

isOpaque

public boolean isOpaque()
Overrides:
isOpaque in class javax.swing.JComponent

getText

public java.lang.String getText()
The text for the Footer, Header, SubFooter and SubHeader.

Returns:
String

setText

public void setText(java.lang.String value)
Sets the text for the Footer, Header, SubFooter and SubHeader.

Parameters:
value - String

getPanel

public Panel getPanel()
Background visible attributes.
Provides access, via the Panel Interface, to all Chart Panel properties.

Returns:
Panel

getPrinter

public Printer getPrinter()
Printing related attributes.

Returns:
Printer

setOpaque

public void setOpaque(boolean value)
Specified by:
setOpaque in interface IChart
Overrides:
setOpaque in class javax.swing.JComponent
Parameters:
value -

getPage

public Page getPage()
Accesses multiple page characteristics of the Chart.

Returns:
Page

getLegend

public Legend getLegend()
Legend characteristics.
The Legend property determines the text and drawing attributes of Chart's textual representation of Series and Series values.
The Legend class draws a rectangle and for each Series in a Chart (or for each point in a Series) outputs a text representation of that Series (or that point).
You can use the Legend.LegendStyle and Legend.TextStyle properties to control the text used to draw the legend.
The Legend can be positioned at Left, Right, Top and Bottom chart sides using the Legend.Alignment property.
Use the Legend.Visible property to show / hide the Legend.
The Inverted property makes Legend to draw text starting from bottom.
The Frame, Font and Color properties allow you to change Legend appearance.
The Legend.ColorWidth property determines the percent width of each item's "colored" mark.
The Legend.FirstValue property controls which Series (or Series point) will be used to draw first Legend item.

Returns:
Legend

getHeader

public Header getHeader()
Defines the Text and formatting properties to be drawn at the top of the Chart.
Use Text to enter the desired Header lines, set Visible to True and change the Font, Frame and Brush methods.
Use Alignment to control text output position.

Returns:
Header

getSubHeader

public Header getSubHeader()
Defines Text shown directly below Header.
Use the Text method to enter the desired SubHeader lines, set Visible to True and change the Font, Frame and Brush methods.
Use the Alignment method to control text output position.

Returns:
Header

getFont

public java.awt.Font getFont()
Determines the Font characteristics.

Specified by:
getFont in interface java.awt.MenuContainer
Overrides:
getFont in class java.awt.Component
Returns:
Font

getForeground

public java.awt.Color getForeground()
Determines the Foreground color.

Overrides:
getForeground in class java.awt.Component
Returns:
Color

getFooter

public Footer getFooter()
Defines Text shown at the bottom of the Chart.
Use Text to enter the desired Footer lines, set Visible to True and change the Font, Frame and Brush methods.
Use Alignment to control text output position.

Returns:
Footer

getZoom

public Zoom getZoom()
Accesses the Zoom characteristics of the Chart.

Returns:
Zoom

getPanning

public Scroll getPanning()
Accesses Panning characteristics.

Scrolling speed depends on:
The number of Series and Series Points.
The Chart Width and Height.
The computer processor and Video card processor speed.
The Video resolution and number of colors.
The Windows version and the Video driver.
The speed when dragging the mouse !

Returns:
Scroll

getSubFooter

public Footer getSubFooter()
Defines Text shown directly above Footer.
Use Text to enter the desired SubFooter lines, set Visible to True and change the Font, Frame and Brush methods.
Use Alignment to control text output position.

Returns:
Footer

getAspect

public Aspect getAspect()
Accesses view characteristics of the Chart.
3D view parameters.

Returns:
Aspect

getCanvas

public IGraphics3D getCanvas()
Deprecated. 

Obsolete. Please use getGraphics3D function.

Returns:
IGraphics3D

setCanvas

public void setCanvas(IGraphics3D value)
Deprecated. 

Obsolete. Please use setGraphics3D method.

Parameters:
value - IGraphics3D

getGraphics3D

public IGraphics3D getGraphics3D()
Used to access TeeChart Draw attributes.

Returns:
IGraphics3D

setGraphics3D

public void setGraphics3D(IGraphics3D value)
Used to access TeeChart Draw attributes.

Parameters:
value - IGraphics3D

getSeries

public SeriesCollection getSeries()
Collection of Series contained in this Chart.

TeeChart Series are the data display method type, e.g. Line Series, Bar Series, Pie Series etc. You can mix different Series types in a Chart according to your requirements, thus your design is not limited to just one 'Chart type' defined by TeeChart. The concept of Chart type being virtually obsolete in terms of the number of permutations of Charts (Series type mix) you may create.

For more information please see "Tutorial 6 - Working with Series".

Returns:
SeriesCollection

getSeries

public Series getSeries(int index)
Default indexer.
Example: tChart1[0].Color=Color.Blue; is equivalent to tChart1.Series[0].Color=Color.Blue;

Parameters:
index - int
Returns:
Series

getTools

public ToolsCollection getTools()
Collection of Tool components contained in this Chart.

Returns:
ToolsCollection

getWalls

public Walls getWalls()
Accesses left, bottom and back wall characteristics of the Chart.

Returns:
Walls

getAxes

public Axes getAxes()
Collection of predefined and custom axis objects.

Returns:
Axes

getExport

public Exports getExport()
Accesses Chart export attributess.

Returns:
Exports

getImport

public Imports getImport()
Accesses Chart import attributes.

Returns:
Imports

setSeries

public void setSeries(int index,
                      Series value)
Collection of Series contained in this Chart.

TeeChart Series are the data display method type, e.g. Line Series, Bar Series, Pie Series etc. You can mix different Series types in a Chart according to your requirements, thus your design is not limited to just one 'Chart type' defined by TeeChart. The concept of Chart type being virtually obsolete in terms of the number of permutations of Charts (Series type mix) you may create.

For more information please see "Tutorial 6 - Working with Series".

Parameters:
index -
value -

checkClickSeries

public boolean checkClickSeries()
Specified by:
checkClickSeries in interface IChart

processMouseEvent

protected void processMouseEvent(java.awt.event.MouseEvent e)
Overrides:
processMouseEvent in class javax.swing.JComponent

processMouseWheelEvent

protected void processMouseWheelEvent(java.awt.event.MouseWheelEvent e)
Overrides:
processMouseWheelEvent in class java.awt.Component

processMouseMotionEvent

protected void processMouseMotionEvent(java.awt.event.MouseEvent e)
Overrides:
processMouseMotionEvent in class javax.swing.JComponent

setToolTip

public void setToolTip(ToolTip tool,
                       java.lang.String text)
Specified by:
setToolTip in interface IChart

setTools

public void setTools(ToolsCollection value)
Collection of Tool components contained in this Chart.

Parameters:
value -

getTransferDataFlavors

public java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
Specified by:
getTransferDataFlavors in interface java.awt.datatransfer.Transferable

isDataFlavorSupported

public boolean isDataFlavorSupported(java.awt.datatransfer.DataFlavor flavor)
Specified by:
isDataFlavorSupported in interface java.awt.datatransfer.Transferable

isDoubleBuffered

public boolean isDoubleBuffered()
Overrides:
isDoubleBuffered in class javax.swing.JComponent

getTransferData

public java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor flavor)
                                 throws java.awt.datatransfer.UnsupportedFlavorException,
                                        java.io.IOException
Specified by:
getTransferData in interface java.awt.datatransfer.Transferable
Throws:
java.awt.datatransfer.UnsupportedFlavorException
java.io.IOException

getImage

public Image getImage()
Return an image of the rendered Chart as Image.

Returns:

isDesignTime

public boolean isDesignTime()
Specified by:
isDesignTime in interface IChart

timerExec

public void timerExec(int time,
                      java.lang.Runnable runnable)
Specified by:
timerExec in interface IChart

copyToClipboard

public void copyToClipboard(java.lang.Object object)
Specified by:
copyToClipboard in interface IChart

xmlDecode

public Chart xmlDecode(java.io.InputStream stream)
Specified by:
xmlDecode in interface IChart

getScreenHeight

public int getScreenHeight()
Specified by:
getScreenHeight in interface IChart

getScreenWidth

public int getScreenWidth()
Specified by:
getScreenWidth in interface IChart

lostOwnership

public void lostOwnership(java.awt.datatransfer.Clipboard arg0,
                          java.awt.datatransfer.Transferable arg1)
Specified by:
lostOwnership in interface java.awt.datatransfer.ClipboardOwner

mouseWheelMoved

public void mouseWheelMoved(java.awt.event.MouseWheelEvent e)
Specified by:
mouseWheelMoved in interface java.awt.event.MouseWheelListener

invertedRotation

public boolean invertedRotation()
Specified by:
invertedRotation in interface IChart