Engauge Digitizer  2
GridLines.h
1 /******************************************************************************************************
2  * (C) 2014 markummitchell@github.com. This file is part of Engauge Digitizer, which is released *
3  * under GNU General Public License version 2 (GPLv2) or (at your option) any later version. See file *
4  * LICENSE or go to gnu.org/licenses for details. Distribution requires prior written permission. *
5  ******************************************************************************************************/
6 
7 #ifndef GRID_LINES_H
8 #define GRID_LINES_H
9 
10 #include "GridLine.h"
11 #include <QList>
12 
13 class QPen;
14 
15 typedef QList<GridLine*> GridLinesContainer;
16 
18 class GridLines
19 {
20  public:
22  GridLines();
23 
25  void add (GridLine *gridLine);
26 
28  void clear ();
29 
31  void setPen (const QPen &pen);
32 
34  void setVisible (bool visible);
35 
36  private:
37 
38  GridLinesContainer m_gridLinesContainer;
39 
40 };
41 
42 #endif // GRID_LINES_H
void clear()
Deallocate and remove all grid lines.
Definition: GridLines.cpp:19
void setPen(const QPen &pen)
Set the pen style of each grid line.
Definition: GridLines.cpp:31
Container class for GridLine objects.
Definition: GridLines.h:18
void setVisible(bool visible)
Make all grid lines visible or hidden.
Definition: GridLines.cpp:38
GridLines()
Single constructor.
Definition: GridLines.cpp:10
void add(GridLine *gridLine)
Add specified grid line. Ownership of all allocated QGraphicsItems is passed to new GridLine...
Definition: GridLines.cpp:14
Single grid line drawn a straight or curved line.
Definition: GridLine.h:20