KiCad PCB EDA Suite
pl_editor_layout.h
Go to the documentation of this file.
1 
4 /*
5  * This program source code file is part of KiCad, a free EDA CAD application.
6  *
7  * Copyright (C) 2013 CERN
8  * @author Jean-Pierre Charras, jp.charras at wanadoo.fr
9  *
10  * This program is free software; you can redistribute it and/or
11  * modify it under the terms of the GNU General Public License
12  * as published by the Free Software Foundation; either version 2
13  * of the License, or (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, you may find one here:
22  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
23  * or you may search the http://www.gnu.org website for the version 2 license,
24  * or you may write to the Free Software Foundation, Inc.,
25  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
26  */
27 
28 #ifndef CLASS_PL_EDITOR_LAYOUT_H
29 #define CLASS_PL_EDITOR_LAYOUT_H
30 
31 #include <base_struct.h>
32 #include <page_info.h>
33 #include <title_block.h>
34 #include <ws_draw_item.h>
35 
36 
41 {
42 private:
46 
48 
49 public:
52 
54  const PAGE_INFO& GetPageSettings() const { return m_paper; }
55  void SetPageSettings( const PAGE_INFO& aPageSettings ) { m_paper = aPageSettings; }
56 
57  const wxPoint& GetAuxOrigin() const
58  {
59  static wxPoint zero( 0, 0 );
60  return zero;
61  }
62 
64  const TITLE_BLOCK& GetTitleBlock() const { return m_titles; }
65  void SetTitleBlock( const TITLE_BLOCK& aTitleBlock ) { m_titles = aTitleBlock; }
66 
68  {
69  return m_drawItemList;
70  }
71 
78 
84  const EDA_RECT GetBoundingBox() const { return m_BoundingBox; }
85 
86  void SetBoundingBox( const EDA_RECT& aBox ) { m_BoundingBox = aBox; }
87 
88 #if defined(DEBUG)
89  void Show( int nestLevel, std::ostream& os ) const;
90 #endif
91 };
92 
93 #endif // #ifndef CLASS_PL_EDITOR_LAYOUT_H
const wxPoint & GetAuxOrigin() const
EDA_RECT ComputeBoundingBox()
Function ComputeBoundingBox calculates the bounding box containing all Gerber items.
TITLE_BLOCK m_titles
Class TITLE_BLOCK holds the information shown in the lower right corner of a plot,...
Definition: title_block.h:40
PAGE_INFO & GetPageSettings()
TITLE_BLOCK & GetTitleBlock()
Class PAGE_INFO describes the page size and margins of a paper page on which to eventually print or p...
Definition: page_info.h:54
Class PL_EDITOR_LAYOUT.
const PAGE_INFO & GetPageSettings() const
void SetBoundingBox(const EDA_RECT &aBox)
WS_DRAW_ITEM_LIST & GetDrawItems()
WS_DRAW_ITEM_LIST m_drawItemList
void SetPageSettings(const PAGE_INFO &aPageSettings)
const TITLE_BLOCK & GetTitleBlock() const
void SetTitleBlock(const TITLE_BLOCK &aTitleBlock)
Class EDA_RECT handles the component boundary box.
Definition: eda_rect.h:44
const EDA_RECT GetBoundingBox() const
Function GetBoundingBox may be called soon after ComputeBoundingBox() to return the same EDA_RECT,...