KiCad PCB EDA Suite
gerbview_draw_panel_gal.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) 2017-2021 KiCad Developers, see AUTHORS.txt for contributors.
5  *
6  * This program is free software: you can redistribute it and/or modify it
7  * under the terms of the GNU General Public License as published by the
8  * Free Software Foundation, either version 3 of the License, or (at your
9  * option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful, but
12  * WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License along
17  * with this program. If not, see <http://www.gnu.org/licenses/>.
18  */
19 
20 #ifndef GERBVIEW_DRAW_PANEL_GAL_H_
21 #define GERBVIEW_DRAW_PANEL_GAL_H_
22 
23 #include <class_draw_panel_gal.h>
24 
25 class DS_PROXY_VIEW_ITEM;
26 
27 
29 {
30 public:
31  GERBVIEW_DRAW_PANEL_GAL( wxWindow* aParentWindow, wxWindowID aWindowId,
32  const wxPoint& aPosition, const wxSize& aSize,
34  GAL_TYPE aGalType = GAL_TYPE_OPENGL );
35 
36  virtual ~GERBVIEW_DRAW_PANEL_GAL();
37 
39  virtual void SetHighContrastLayer( int aLayer ) override;
40 
42  void GetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vector<MSG_PANEL_ITEM>& aList ) override;
43 
45  void OnShow() override;
46 
47  bool SwitchBackend( GAL_TYPE aGalType ) override;
48 
50  virtual void SetTopLayer( int aLayer ) override;
51 
53  BOX2I GetDefaultViewBBox() const override;
54 
61  void SetDrawingSheet( DS_PROXY_VIEW_ITEM* aDrawingSheet );
62 
67 
68 protected:
70  void setDefaultLayerDeps();
71 
73  std::unique_ptr<DS_PROXY_VIEW_ITEM> m_drawingSheet;
74 };
75 
76 
77 #endif /* GERBVIEW_DRAW_PANEL_GAL_H_ */
virtual void SetHighContrastLayer(int aLayer) override
BOX2I GetDefaultViewBBox() const override
Return the bounding box of the view that should be used if model is not valid.
void GetMsgPanelInfo(EDA_DRAW_FRAME *aFrame, std::vector< MSG_PANEL_ITEM > &aList) override
Called when the window is shown for the first time.
GERBVIEW_DRAW_PANEL_GAL(wxWindow *aParentWindow, wxWindowID aWindowId, const wxPoint &aPosition, const wxSize &aSize, KIGFX::GAL_DISPLAY_OPTIONS &aOptions, GAL_TYPE aGalType=GAL_TYPE_OPENGL)
The base class for create windows for drawing purpose.
void setDefaultLayerDeps()
< Set rendering targets & dependencies for layers.
DS_PROXY_VIEW_ITEM * GetDrawingSheet() const
std::unique_ptr< DS_PROXY_VIEW_ITEM > m_drawingSheet
void OnShow() override
Called when the window is shown for the first time.
bool SwitchBackend(GAL_TYPE aGalType) override
Move the selected layer to the top, so it is displayed above all others.
virtual ~GERBVIEW_DRAW_PANEL_GAL()
Take care of display settings for the given layer to be displayed in high contrast mode.
void SetDrawingSheet(DS_PROXY_VIEW_ITEM *aDrawingSheet)
Set or update the drawing-sheet (borders and title block) used by the draw panel.
virtual void SetTopLayer(int aLayer) override
Return the bounding box of the view that should be used if model is not valid.