ACF $AcfVersion:0$
CQuadrangleComp.h
Go to the documentation of this file.
1// SPDX-License-Identifier: LGPL-2.1-or-later OR GPL-2.0-or-later OR GPL-3.0-or-later OR LicenseRef-ACF-Commercial
2#pragma once
3
4
5// ACF includes
7#include <i2d/CQuadrangle.h>
8
9
10namespace i2d
11{
12
13
18class CQuadrangleComp: public TObject2dCompWrap<CQuadrangle>
19{
20public:
22
23 I_BEGIN_COMPONENT(CQuadrangleComp);
24 I_REGISTER_INTERFACE(CQuadrangle);
25 I_REGISTER_INTERFACE(IObject2d);
26 I_REGISTER_INTERFACE(iser::ISerializable);
27 I_ASSIGN(m_diag1X1AttrPtr, "Diag1X1", "X-Position of start line point of the first diagonal", true, 0);
28 I_ASSIGN(m_diag1Y1AttrPtr, "Diag1Y1", "Y-Position of start line point of the first diagonal", true, 0);
29 I_ASSIGN(m_diag1X2AttrPtr, "Diag1X2", "X-Position of end line point of the first diagonal", true, 0);
30 I_ASSIGN(m_diag1Y2AttrPtr, "Diag1Y2", "Y-Position of end line point of the first diagonal", true, 0);
31 I_ASSIGN(m_diag2X1AttrPtr, "Diag2X1", "X-Position of start line point of the second diagonal", true, 0);
32 I_ASSIGN(m_diag2Y1AttrPtr, "Diag2Y1", "Y-Position of start line point of the second diagonal", true, 0);
33 I_ASSIGN(m_diag2X2AttrPtr, "Diag2X2", "X-Position of end line point of the second diagonal", true, 0);
34 I_ASSIGN(m_diag2Y2AttrPtr, "Diag2Y2", "Y-Position of end line point of the second diagonal", true, 0);
35 I_END_COMPONENT;
36
37protected:
38 // reimplemented (icomp::CComponentBase)
39 virtual void OnComponentCreated() override;
40
41private:
42 I_ATTR(double, m_diag1X1AttrPtr);
43 I_ATTR(double, m_diag1Y1AttrPtr);
44 I_ATTR(double, m_diag1X2AttrPtr);
45 I_ATTR(double, m_diag1Y2AttrPtr);
46 I_ATTR(double, m_diag2X1AttrPtr);
47 I_ATTR(double, m_diag2Y1AttrPtr);
48 I_ATTR(double, m_diag2X2AttrPtr);
49 I_ATTR(double, m_diag2Y2AttrPtr);
50};
51
52
53} // namespace i2d
54
55
56
57
Implementation of a quadrangle as a component.
virtual void OnComponentCreated() override
TObject2dCompWrap< CQuadrangle > BaseClass
Definition of convexes quadrangle object.
Definition CQuadrangle.h:19
Common interface for describing the 2D-objects.
Definition IObject2d.h:26
Base class for all components implementing 2D objects.
Common class for all classes which objects can be archived or restored from archive.
Contains the 2D objects.
Definition CAffine2d.h:11