KiCad PCB EDA Suite
module_editor_tools.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) 2014 CERN
5  * @author Maciej Suminski <maciej.suminski@cern.ch>
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 2
10  * of the License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, you may find one here:
19  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
20  * or you may search the http://www.gnu.org website for the version 2 license,
21  * or you may write to the Free Software Foundation, Inc.,
22  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
23  */
24 
25 #ifndef MODULE_EDITOR_TOOLS_H
26 #define MODULE_EDITOR_TOOLS_H
27 
28 #include <tool/tool_interactive.h>
29 
30 namespace KIGFX
31 {
32  class VIEW;
33  class VIEW_CONTROLS;
34 }
35 class BOARD;
36 class PCB_EDIT_FRAME;
37 
44 {
45 public:
48 
50  void Reset( RESET_REASON aReason ) override;
51 
56  int PlacePad( const TOOL_EVENT& aEvent );
57 
62  int EnumeratePads( const TOOL_EVENT& aEvent );
63 
69  int CopyItems( const TOOL_EVENT& aEvent );
70 
76  int PasteItems( const TOOL_EVENT& aEvent );
77 
83  int CreateArray( TOOL_EVENT& aEvent );
84 
90  int ModuleTextOutlines( const TOOL_EVENT& aEvent );
91 
97  int ModuleEdgeOutlines( const TOOL_EVENT& aEvent );
98 
100  void SetTransitions() override;
101 
102 private:
107 
108 };
109 
110 #endif
void Reset(RESET_REASON aReason) override
Function Reset() Brings the tool to a known, initial state.
int CreateArray(TOOL_EVENT &aEvent)
Function CreateArray.
Class CAIRO_GAL is the cairo implementation of the graphics abstraction layer.
Definition: class_module.h:56
void SetTransitions() override
Sets up handlers for various events.
PCB_EDIT_FRAME * m_frame
int PasteItems(const TOOL_EVENT &aEvent)
Function PastePad()
int ModuleTextOutlines(const TOOL_EVENT &aEvent)
Function ModuleTextOutlines()
int PlacePad(const TOOL_EVENT &aEvent)
Function PlacePad() Places a pad in module editor.
KIGFX::VIEW_CONTROLS * m_controls
Class TOOL_EVENT.
Definition: tool_event.h:162
int CopyItems(const TOOL_EVENT &aEvent)
Function CopyItems()
Class VIEW_CONTROLS is an interface for classes handling user events controlling the view behaviour (...
Definition: view_controls.h:94
int ModuleEdgeOutlines(const TOOL_EVENT &aEvent)
Function ModuleEdgeOutlines()
int EnumeratePads(const TOOL_EVENT &aEvent)
Function EnumeratePads() Tool for quick pad enumeration.
Class BOARD holds information pertinent to a Pcbnew printed circuit board.
Definition: class_board.h:166
Class MODULE_EDITOR_TOOLS.
RESET_REASON
Determines the reason of reset for a tool
Definition: tool_base.h:80
Class VIEW.
Definition: view.h:58