KiCad PCB EDA Suite
Loading...
Searching...
No Matches
angle_item.h
Go to the documentation of this file.
1/*
2 * This program source code file is part of KICAD, a free EDA CAD application.
3 *
4 * Copyright (C) 2024 The KiCad Developers, see AUTHORS.txt for contributors.
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version 2
9 * of the License, or (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, you may find one here:
18 * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
19 * or you may search the http://www.gnu.org website for the version 2 license,
20 * or you may write to the Free Software Foundation, Inc.,
21 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
22 */
23
24#ifndef PREVIEW_ANGLE_ITEM_H
25#define PREVIEW_ANGLE_ITEM_H
26
28
29class EDIT_POINTS;
30
31namespace KIGFX
32{
33namespace PREVIEW
34{
35
37{
38public:
39 ANGLE_ITEM( EDIT_POINTS* aPoints );
40
41 const BOX2I ViewBBox() const override;
42
43 void SetEditPoints( EDIT_POINTS* aPoints )
44 {
45 m_points = aPoints;
46 }
47
48private:
49 void drawPreviewShape( KIGFX::VIEW* aView ) const override;
50
52};
53
54} // PREVIEW
55} // KIGFX
56
57#endif
BOX2< VECTOR2I > BOX2I
Definition box2.h:922
EDIT_POINTS is a VIEW_ITEM that manages EDIT_POINTs and EDIT_LINEs and draws them.
ANGLE_ITEM(EDIT_POINTS *aPoints)
void SetEditPoints(EDIT_POINTS *aPoints)
Definition angle_item.h:43
const BOX2I ViewBBox() const override
Return the bounding box of the item covering all its layers.
void drawPreviewShape(KIGFX::VIEW *aView) const override
Draw the preview onto the given GAL.
Hold a (potentially large) number of VIEW_ITEMs and renders them on a graphics device provided by the...
Definition view.h:66
The Cairo implementation of the graphics abstraction layer.
Definition eda_group.h:33