Click here to Skip to main content
15,881,173 members
Articles / Desktop Programming / MFC

High-speed Charting Control

Rate me:
Please Sign up or sign in to vote.
4.95/5 (327 votes)
13 Jul 2010CPOL35 min read 4.2M   100.4K   787  
A flexible charting control to display 2D data
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>ChartDemo: CChartSeriesMouseListener&lt; PointType &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.8 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>CChartSeriesMouseListener&lt; PointType &gt; Class Template Reference</h1><!-- doxytag: class="CChartSeriesMouseListener" -->Listener for mouse events occuring on a series.  
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="_chart_series_mouse_listener_8h-source.html">ChartSeriesMouseListener.h</a>&gt;</code>
<p>

<p>
<a href="class_c_chart_series_mouse_listener-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ddcd23886b58fd60915a0785f49536a5"></a><!-- doxytag: member="CChartSeriesMouseListener::CChartSeriesMouseListener" ref="ddcd23886b58fd60915a0785f49536a5" args="()" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_chart_series_mouse_listener.html#ddcd23886b58fd60915a0785f49536a5">CChartSeriesMouseListener</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="3a2cba53ed76f30183a9880f1905a1fa"></a><!-- doxytag: member="CChartSeriesMouseListener::~CChartSeriesMouseListener" ref="3a2cba53ed76f30183a9880f1905a1fa" args="()" -->
virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_chart_series_mouse_listener.html#3a2cba53ed76f30183a9880f1905a1fa">~CChartSeriesMouseListener</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Destructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_chart_series_mouse_listener.html#066879592ec79ccd4341f319b27ac467">OnMouseEventSeries</a> (<a class="el" href="class_c_chart_mouse_listener.html#cffa1073dca632eca72f7339ecb350d7">CChartMouseListener::MouseEvent</a> mouseEvent, CPoint point, <a class="el" href="class_c_chart_serie_base.html">CChartSerieBase</a>&lt; PointType &gt; *pSerie, unsigned uPointIndex)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Virtual function to implement in order to be notified when a mouse event occurs on a series.  <a href="#066879592ec79ccd4341f319b27ac467"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<h3>template&lt;class PointType&gt;<br>
 class CChartSeriesMouseListener&lt; PointType &gt;</h3>

Listener for mouse events occuring on a series. 
<p>
This is an interface which must be implemented in order to receive mouse notifications. You can then register your class with the chart control by calling RegisterMouseListener. <hr><h2>Member Function Documentation</h2>
<a class="anchor" name="066879592ec79ccd4341f319b27ac467"></a><!-- doxytag: member="CChartSeriesMouseListener::OnMouseEventSeries" ref="066879592ec79ccd4341f319b27ac467" args="(CChartMouseListener::MouseEvent mouseEvent, CPoint point, CChartSerieBase&lt; PointType &gt; *pSerie, unsigned uPointIndex)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class PointType&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">virtual void <a class="el" href="class_c_chart_series_mouse_listener.html">CChartSeriesMouseListener</a>&lt; PointType &gt;::OnMouseEventSeries           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_c_chart_mouse_listener.html#cffa1073dca632eca72f7339ecb350d7">CChartMouseListener::MouseEvent</a>&nbsp;</td>
          <td class="paramname"> <em>mouseEvent</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">CPoint&nbsp;</td>
          <td class="paramname"> <em>point</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_c_chart_serie_base.html">CChartSerieBase</a>&lt; PointType &gt; *&nbsp;</td>
          <td class="paramname"> <em>pSerie</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&nbsp;</td>
          <td class="paramname"> <em>uPointIndex</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [inline, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Virtual function to implement in order to be notified when a mouse event occurs on a series. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>mouseEvent</em>&nbsp;</td><td>The mouse event which occured </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>point</em>&nbsp;</td><td>The screen point on which the event occured </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pSerie</em>&nbsp;</td><td>The series on which the event occured </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>uPointIndex</em>&nbsp;</td><td>The index of the point on which the event occured. In case the event did not occur on a specific point but on the series itself (e.g. clicking between two points on a line series), INVALID_POINT is passed for this parameter. </td></tr>
  </table>
</dl>

</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li>E:/Sources Misc/ChartDemo/ChartCtrl/<a class="el" href="_chart_series_mouse_listener_8h-source.html">ChartSeriesMouseListener.h</a></ul>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Sun Jan 17 13:33:11 2010 for ChartDemo by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.8 </small></address>
</body>
</html>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Engineer
Belgium Belgium
I am a 29 years old guy and I live with my girlfriend in Hoegaarden, little city from Belgium well known for its white beer Smile | :) .
I studied as an industrial engineer in electronics but I oriented myself more towards software development when I started to work.
Currently I am working in a research centre in mechatronica. I mainly develop in C++ but I also do a bit of Java.
When I have so spare time, I like to read (mainly fantasy) and play electric guitar.

Comments and Discussions