Seamly2D
Code documentation
anchorpoint_visual.h
Go to the documentation of this file.
1 /************************************************************************
2  **
3  ** @file anchorpoint_visual.h
4  ** @author Roman Telezhynskyi <dismine(at)gmail.com>
5  ** @date 31 1, 2017
6  **
7  ** @brief
8  ** @copyright
9  ** This source code is part of the Valentine project, a pattern making
10  ** program, whose allow create and modeling patterns of clothing.
11  ** Copyright (C) 2017 Seamly2D project
12  ** <https://github.com/fashionfreedom/seamly2d> All Rights Reserved.
13  **
14  ** Seamly2D is free software: you can redistribute it and/or modify
15  ** it under the terms of the GNU General Public License as published by
16  ** the Free Software Foundation, either version 3 of the License, or
17  ** (at your option) any later version.
18  **
19  ** Seamly2D is distributed in the hope that it will be useful,
20  ** but WITHOUT ANY WARRANTY; without even the implied warranty of
21  ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22  ** GNU General Public License for more details.
23  **
24  ** You should have received a copy of the GNU General Public License
25  ** along with Seamly2D. If not, see <http://www.gnu.org/licenses/>.
26  **
27  *************************************************************************/
28 
29 #ifndef ANCHOR_POINT_VISUAL_H
30 #define ANCHOR_POINT_VISUAL_H
31 
32 #include "visline.h"
33 
34 class VSimplePoint;
35 
36 class AnchorPointVisual : public VisLine
37 {
38  Q_OBJECT
39 public:
40  explicit AnchorPointVisual(const VContainer *data, QGraphicsItem *parent = nullptr);
41  virtual ~AnchorPointVisual();
42 
43  virtual void RefreshGeometry() Q_DECL_OVERRIDE;
44  virtual int type() const Q_DECL_OVERRIDE {return Type;}
45  enum {Type = UserType + static_cast<int>(Vis::ToolAnchorPoint)};
46 
47 private:
48  Q_DISABLE_COPY(AnchorPointVisual)
49  QPointer<VSimplePoint> m_point;
50 };
51 
52 #endif // ANCHOR_POINT_VISUAL_H
AnchorPointVisual(const VContainer *data, QGraphicsItem *parent=nullptr)
QPointer< VSimplePoint > m_point
virtual void RefreshGeometry() Q_DECL_OVERRIDE
virtual int type() const Q_DECL_OVERRIDE
The VContainer class container of all variables.
Definition: vcontainer.h:141
const VContainer * data
Definition: visualization.h:97
@ ToolAnchorPoint