Version: 0.6.0
ohlccandlestickrenderer.h
1 // Name: ohlccandlestickrenderer.h
3 // Purpose: OHLC candlestick renderer declarations
4 // Author: Moskvichev Andrey V.
5 // Created: 2008/11/07
6 // Copyright: (c) 2008-2010 Moskvichev Andrey V.
7 // Licence: wxWidgets licence
9 
10 #ifndef OHLCCANDDLESTICKRENDERER_H_
11 #define OHLCCANDDLESTICKRENDERER_H_
12 
13 #include <wx/ohlc/ohlcrenderer.h>
14 
18 class WXDLLIMPEXP_FREECHART OHLCCandlestickRenderer : public OHLCRenderer
19 {
20 public:
22  virtual ~OHLCCandlestickRenderer();
23 
24  virtual void DrawItem(wxDC &dc, wxCoord x, wxCoord open, wxCoord high, wxCoord low, wxCoord close);
25 
30  void SetOutlinePen(wxPen outlinePen)
31  {
32  m_outlinePen = outlinePen;
33  FireNeedRedraw();
34  }
35 
40  const wxPen &GetOutlinePen()
41  {
42  return m_outlinePen;
43  }
44 
49  void SetLowerBrush(wxBrush lowerBrush)
50  {
51  m_lowerBrush = lowerBrush;
52  FireNeedRedraw();
53  }
54 
59  const wxBrush &GetLowerBrush()
60  {
61  return m_lowerBrush;
62  }
63 
68  void SetHigherBrush(wxBrush higherBrush)
69  {
70  m_higherBrush = higherBrush;
71  FireNeedRedraw();
72  }
73 
78  const wxBrush &GetHigherBrush()
79  {
80  return m_higherBrush;
81  }
82 
83 private:
84  wxCoord m_candleRadius;
85 
86  wxPen m_outlinePen;
87  wxBrush m_lowerBrush;
88  wxBrush m_higherBrush;
89 };
90 
91 #endif /*OHLCCANDDLESTICKRENDERER_H_*/
const wxBrush & GetHigherBrush()
Definition: ohlccandlestickrenderer.h:78
Definition: ohlccandlestickrenderer.h:18
void SetOutlinePen(wxPen outlinePen)
Definition: ohlccandlestickrenderer.h:30
Definition: ohlcrenderer.h:28
void SetHigherBrush(wxBrush higherBrush)
Definition: ohlccandlestickrenderer.h:68
void SetLowerBrush(wxBrush lowerBrush)
Definition: ohlccandlestickrenderer.h:49
const wxPen & GetOutlinePen()
Definition: ohlccandlestickrenderer.h:40
const wxBrush & GetLowerBrush()
Definition: ohlccandlestickrenderer.h:59
virtual void DrawItem(wxDC &dc, wxCoord x, wxCoord open, wxCoord high, wxCoord low, wxCoord close)=0