KiCad PCB EDA Suite
draw_frame.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) 2009 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
5  * Copyright (C) 2011 Wayne Stambaugh <stambaughw@gmail.com>
6  * Copyright (C) 1992-2017 KiCad Developers, see AUTHORS.txt for contributors.
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License
10  * as published by the Free Software Foundation; either version 2
11  * of the License, or (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, you may find one here:
20  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
21  * or you may search the http://www.gnu.org website for the version 2 license,
22  * or you may write to the Free Software Foundation, Inc.,
23  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
24  */
25 
26 #ifndef DRAW_FRAME_H_
27 #define DRAW_FRAME_H_
28 
29 #include <eda_base_frame.h>
30 #include <kiway_player.h>
31 #include <climits>
33 #include <gal/color4d.h>
34 #include <class_draw_panel_gal.h>
35 
36 class wxSingleInstanceChecker;
37 class EDA_HOTKEY;
38 
39 using KIGFX::COLOR4D;
40 
41 namespace KIGFX
42 {
43  class GAL_DISPLAY_OPTIONS;
44 }
45 
46 #define DEFAULT_MAX_UNDO_ITEMS 0
47 #define ABS_MAX_UNDO_ITEMS (INT_MAX / 2)
48 
55 {
58  friend class EDA_DRAW_PANEL;
59 
61  int m_toolId;
62 
64 
65  bool m_snapToGrid;
67 
69 
71  std::unique_ptr<KIGFX::GAL_DISPLAY_OPTIONS> m_galDisplayOptions;
72 
73 protected:
74 
75  std::unique_ptr<wxSingleInstanceChecker> m_file_checker;
76 
78  int m_LastGridSizeId; // the command id offset (>= 0) of the last selected grid
79  // 0 is for the grid corresponding to
80  // a wxCommand ID = ID_POPUP_GRID_LEVEL_1000.
81  bool m_drawGrid; // hide/Show grid
85  double m_zoomLevelCoeff;
87  // to a zoom level value which rougly gives 1.0 when the board/schematic
88  // is at scale = 1
90  // to screens
91 
94 
98 
101 
104 
107 
111 
114 
117 
119  wxChoice* m_gridSelectBox;
120 
122  wxChoice* m_zoomSelectBox;
123 
126  wxAuiToolBar* m_drawToolBar;
127 
129  wxAuiToolBar* m_optionsToolBar;
130 
133 
135 
136 #ifdef USE_WX_OVERLAY
137  // MAC Uses overlay to workaround the wxINVERT and wxXOR miss
138  wxOverlay m_overlay;
139 #endif
140 
143 
146 
149 
150  void SetScreen( BASE_SCREEN* aScreen ) { m_currentScreen = aScreen; }
151 
152  double bestZoom( double sizeX, double sizeY, double scaleFactor, wxPoint centre );
153 
161  virtual void unitsChangeRefresh();
162 
172  bool GeneralControlKeyMovement( int aHotKey, wxPoint *aPos, bool aSnapToGrid );
173 
177  void RefreshCrossHair( const wxPoint &aOldPos, const wxPoint &aEvtPos, wxDC* aDC );
178 
182  bool isBusy() const;
183 
187  EDA_DRAW_PANEL_GAL::GAL_TYPE loadCanvasTypeSetting() const;
188 
192  bool saveCanvasTypeSetting( EDA_DRAW_PANEL_GAL::GAL_TYPE aCanvasType );
193 
195  static const wxChar CANVAS_TYPE_KEY[];
196 
197 public:
198  EDA_DRAW_FRAME( KIWAY* aKiway, wxWindow* aParent,
199  FRAME_T aFrameType,
200  const wxString& aTitle,
201  const wxPoint& aPos, const wxSize& aSize,
202  long aStyle,
203  const wxString& aFrameName );
204 
205  ~EDA_DRAW_FRAME();
206 
213  virtual void OnCharHook( wxKeyEvent& event );
214 
221  bool LockFile( const wxString& aFileName );
222 
227  void ReleaseFile();
228 
229  virtual void SetPageSettings( const PAGE_INFO& aPageSettings ) = 0;
230  virtual const PAGE_INFO& GetPageSettings() const = 0;
231 
237  virtual const wxSize GetPageSizeIU() const = 0;
238 
243  virtual const wxPoint& GetAuxOrigin() const = 0;
244  virtual void SetAuxOrigin( const wxPoint& aPosition ) = 0;
245 
252  virtual const wxPoint& GetGridOrigin() const = 0;
253  virtual void SetGridOrigin( const wxPoint& aPosition ) = 0;
254 
255  //-----<BASE_SCREEN API moved here>------------------------------------------
262  wxPoint GetCrossHairPosition( bool aInvertY = false ) const;
263 
272  void SetCrossHairPosition( const wxPoint& aPosition, bool aSnapToGrid = true );
273 
282  wxPoint GetCursorPosition( bool aOnGrid, wxRealPoint* aGridSize = NULL ) const;
283 
292  wxPoint GetNearestGridPosition( const wxPoint& aPosition, wxRealPoint* aGridSize = NULL ) const;
293 
299  wxPoint GetCrossHairScreenPosition() const;
300 
301  void SetMousePosition( const wxPoint& aPosition );
302 
313  wxPoint RefPos( bool useMouse ) const;
314 
315  const wxPoint& GetScrollCenterPosition() const;
316  void SetScrollCenterPosition( const wxPoint& aPoint );
317 
318  //-----</BASE_SCREEN API moved here>-----------------------------------------
319 
320 
321  virtual const TITLE_BLOCK& GetTitleBlock() const = 0;
322  virtual void SetTitleBlock( const TITLE_BLOCK& aTitleBlock ) = 0;
323 
324  // the background color of the draw canvas:
325  // Virtual because some frames can have a specific way to get/set the bg color
329  virtual COLOR4D GetDrawBgColor() const { return m_drawBgColor; }
330 
334  virtual void SetDrawBgColor( COLOR4D aColor) { m_drawBgColor= aColor ; }
335 
336  bool GetShowBorderAndTitleBlock() const { return m_showBorderAndTitleBlock; }
337 
338  void SetShowBorderAndTitleBlock( bool aShow ) { m_showBorderAndTitleBlock = aShow; }
339  bool ShowPageLimits() const { return m_showPageLimits; }
340  void SetShowPageLimits( bool aShow ) { m_showPageLimits = aShow; }
341 
342  EDA_DRAW_PANEL* GetCanvas() { return m_canvas; }
343 
344  virtual wxString GetScreenDesc() const;
345 
352  virtual BASE_SCREEN* GetScreen() const { return m_currentScreen; }
353 
363  virtual void ExecuteRemoteCommand( const char* cmdline ){}
364 
365  void OnMenuOpen( wxMenuEvent& event );
366  void OnMouseEvent( wxMouseEvent& event );
367 
379  void SkipNextLeftButtonReleaseEvent();
380 
382  int WriteHotkeyConfig( struct EDA_HOTKEY_CONFIG* aDescList, wxString* aFullFileName = NULL ) override;
383 
388  EDA_HOTKEY_CONFIG* GetHotkeyConfig() const { return m_hotkeysDescrList; }
389 
397  virtual EDA_HOTKEY* GetHotKeyDescription( int aCommand ) const = 0;
398 
399  virtual bool OnHotKey( wxDC* aDC, int aHotKey, const wxPoint& aPosition,
400  EDA_ITEM* aItem = NULL );
401 
408  virtual void AddMenuZoomAndGrid( wxMenu* aMasterMenu );
409 
419  virtual const wxString GetZoomLevelIndicator() const;
420 
425  inline double GetZoomLevelCoeff() const { return m_zoomLevelCoeff; }
426 
427  void EraseMsgBox();
428  void Process_PageSettings( wxCommandEvent& event );
429 
430  virtual void ReCreateHToolbar() = 0;
431  virtual void ReCreateVToolbar() = 0;
432  virtual void ReCreateMenuBar() override;
433  virtual void ReCreateAuxiliaryToolbar();
434 
435  // Toolbar accessors
436  wxAuiToolBar* GetMainToolBar() const { return m_mainToolBar; }
437 
445  bool GetToolToggled( int aToolId )
446  {
447  return ( m_mainToolBar->GetToolToggled( aToolId ) ||
448  m_optionsToolBar->GetToolToggled( aToolId ) ||
449  m_drawToolBar->GetToolToggled( aToolId ) );
450  }
451 
464  virtual void SetToolID( int aId, int aCursor, const wxString& aToolMsg );
465 
469  virtual void SetNoToolSelected();
470 
476  int GetToolId() const { return m_toolId; }
477 
478  /* These 4 functions provide a basic way to show/hide grid
479  * and /get/set grid color.
480  * These parameters are saved in KiCad config for each main frame
481  */
486  virtual bool IsGridVisible() const
487  {
488  return m_drawGrid;
489  }
490 
496  virtual void SetGridVisibility( bool aVisible )
497  {
498  m_drawGrid = aVisible;
499  }
500 
506  {
507  return m_gridColor;
508  }
509 
514  virtual void SetGridColor( COLOR4D aColor )
515  {
516  m_gridColor = aColor;
517  }
518 
527  wxPoint GetGridPosition( const wxPoint& aPosition ) const;
528 
533  virtual void SetNextGrid();
534 
539  virtual void SetPrevGrid();
540 
546  void SetPresetGrid( int aIndex );
547 
558  virtual void OnSelectGrid( wxCommandEvent& event );
559 
567  virtual void OnSelectZoom( wxCommandEvent& event );
568 
569  // Command event handlers shared by all applications derived from EDA_DRAW_FRAME.
570  void OnToggleGridState( wxCommandEvent& aEvent );
571  void OnSelectUnits( wxCommandEvent& aEvent );
572  void OnToggleCrossHairStyle( wxCommandEvent& aEvent );
573 
574  // Update user interface event handlers shared by all applications derived from
575  // EDA_DRAW_FRAME.
576  void OnUpdateUndo( wxUpdateUIEvent& aEvent );
577  void OnUpdateRedo( wxUpdateUIEvent& aEvent );
578  void OnUpdateGrid( wxUpdateUIEvent& aEvent );
579  void OnUpdateUnits( wxUpdateUIEvent& aEvent );
580  void OnUpdateCrossHairStyle( wxUpdateUIEvent& aEvent );
581 
594  virtual bool GeneralControl( wxDC* aDC, const wxPoint& aPosition, EDA_KEY aHotKey = 0 )
595  {
596  return false;
597  }
598 
603  virtual void OnSize( wxSizeEvent& event );
604 
605  void OnEraseBackground( wxEraseEvent& SizeEvent );
606 
607  virtual void OnZoom( wxCommandEvent& event );
608 
613  void SetNextZoom();
614 
619  void SetPrevZoom();
620 
626  void SetPresetZoom( int aIndex );
627 
635  void RedrawScreen( const wxPoint& aCenterPoint, bool aWarpPointer );
636 
642  void RedrawScreen2( const wxPoint& posBefore );
643 
649  void Zoom_Automatique( bool aWarpPointer );
650 
651  /* Set the zoom level to show the area Rect */
652  void Window_Zoom( EDA_RECT& Rect );
653 
655  virtual double BestZoom() = 0;
656 
661  double GetZoom();
662 
673  void DrawWorkSheet( wxDC* aDC, BASE_SCREEN* aScreen, int aLineWidth,
674  double aScale, const wxString &aFilename,
675  const wxString &aSheetLayer = wxEmptyString );
676 
677  void DisplayToolMsg( const wxString& msg );
678  virtual void RedrawActiveWindow( wxDC* DC, bool EraseBg ) = 0;
679  virtual void OnLeftClick( wxDC* DC, const wxPoint& MousePos ) = 0;
680  virtual void OnLeftDClick( wxDC* DC, const wxPoint& MousePos );
681  virtual bool OnRightClick( const wxPoint& MousePos, wxMenu* PopMenu ) = 0;
682  virtual void ToolOnRightClick( wxCommandEvent& event );
683  void AdjustScrollBars( const wxPoint& aCenterPosition );
684 
691  virtual void OnActivate( wxActivateEvent& event );
692 
706  virtual void UpdateStatusBar();
707 
712  void DisplayUnitsMsg();
713 
714  /* Handlers for block commands */
715  virtual void InitBlockPasteInfos();
716 
726  virtual bool HandleBlockBegin( wxDC* aDC, EDA_KEY aKey, const wxPoint& aPosition,
727  int aExplicitCommand = 0 );
728 
738  virtual int BlockCommand( EDA_KEY aKey );
739 
747  virtual void HandleBlockPlace( wxDC* DC );
748 
759  virtual bool HandleBlockEnd( wxDC* DC );
760 
765  void CopyToClipboard( wxCommandEvent& event );
766 
767  /* interprocess communication */
768  void OnSockRequest( wxSocketEvent& evt );
769  void OnSockRequestServer( wxSocketEvent& evt );
770 
771  void LoadSettings( wxConfigBase* aCfg ) override;
772 
773  void SaveSettings( wxConfigBase* aCfg ) override;
774 
787  void AppendMsgPanel( const wxString& textUpper, const wxString& textLower,
788  COLOR4D color, int pad = 6 );
789 
793  void ClearMsgPanel( void );
794 
801  void SetMsgPanel( const std::vector< MSG_PANEL_ITEM >& aList );
802 
803  void SetMsgPanel( EDA_ITEM* aItem );
804 
809  virtual void UpdateMsgPanel();
810 
818  void PushPreferences( const EDA_DRAW_PANEL* aParentCanvas );
819 
829  virtual void PrintPage( wxDC* aDC, LSET aPrintMask, bool aPrintMirrorMode, void* aData = NULL );
830 
840  wxString CoordinateToString( int aValue, bool aConvertToMils = false ) const;
841 
851  wxString LengthDoubleToString( double aValue, bool aConvertToMils = false ) const;
852 
859  virtual void UseGalCanvas( bool aEnable );
860 
866  virtual bool SwitchCanvas( EDA_DRAW_PANEL_GAL::GAL_TYPE aCanvasType );
867 
874  bool IsGalCanvasActive() const { return m_galCanvasActive; }
875 
882  EDA_DRAW_PANEL_GAL* GetGalCanvas() const { return m_galCanvas; }
883  void SetGalCanvas( EDA_DRAW_PANEL_GAL* aPanel ) { m_galCanvas = aPanel; }
884 
889  TOOL_MANAGER* GetToolManager() const { return m_toolManager; }
890 
897  virtual void* GetDisplayOptions() { return NULL; }
898 
903  KIGFX::GAL_DISPLAY_OPTIONS& GetGalDisplayOptions() { return *m_galDisplayOptions; }
904 
905  DECLARE_EVENT_TABLE()
906 };
907 
908 #endif // DRAW_FRAME_H_
bool ShowPageLimits() const
Definition: draw_frame.h:339
TOOL_MANAGER * m_toolManager
Definition: draw_frame.h:95
wxString CoordinateToString(int aValue, bool aConvertToMils)
Function CoordinateToString is a helper to convert the integer coordinate aValue to a string in inche...
Definition: base_units.cpp:118
double GetZoom()
Definition: draw_panel.cpp:283
Class KIWAY_PLAYER is a wxFrame capable of the OpenProjectFiles function, meaning it can load a porti...
Definition: kiway_player.h:111
std::unique_ptr< KIGFX::GAL_DISPLAY_OPTIONS > m_galDisplayOptions
Definition: draw_frame.h:71
Structure EDA_HOTKEY_CONFIG contains the information required to save hot key information to a config...
Definition: hotkeys_basic.h:87
bool m_galCanvasActive
whether to use new GAL engine
Definition: draw_frame.h:66
wxAuiToolBar * GetMainToolBar() const
Definition: draw_frame.h:436
KIGFX::GAL_DISPLAY_OPTIONS & GetGalDisplayOptions()
Function GetGalDisplayOptions Returns a reference to the gal rendering options used by GAL for render...
Definition: draw_frame.h:903
Class CAIRO_GAL is the cairo implementation of the graphics abstraction layer.
Definition: class_module.h:57
bool m_showAxis
True shows the X and Y axis indicators.
Definition: draw_frame.h:103
TOOL_DISPATCHER * m_toolDispatcher
Definition: draw_frame.h:96
EDA_DRAW_PANEL * GetCanvas()
Definition: draw_frame.h:342
FRAME_T
Enum FRAME_T is the set of EDA_BASE_FRAME derivatives, typically stored in EDA_BASE_FRAME::m_Ident.
Definition: frame_type.h:34
EDA_DRAW_PANEL_GAL::GAL_TYPE m_canvasType
The current canvas type.
Definition: draw_frame.h:148
void SetScreen(BASE_SCREEN *aScreen)
Definition: draw_frame.h:150
int color
Definition: DXF_plotter.cpp:62
virtual void SetDrawBgColor(COLOR4D aColor)
Definition: draw_frame.h:334
EDA_HOTKEY_CONFIG * GetHotkeyConfig() const
Function GetHotkeyConfig() Returns a structure containing currently used hotkey mapping.
Definition: draw_frame.h:388
bool GetShowBorderAndTitleBlock() const
Definition: draw_frame.h:336
void SetGalCanvas(EDA_DRAW_PANEL_GAL *aPanel)
Definition: draw_frame.h:883
virtual void SetGridColor(COLOR4D aColor)
Function SetGridColor() , virtual.
Definition: draw_frame.h:514
class EDA_MSG_PANEL is a panel to display various information messages.
Definition: msgpanel.h:111
Class EDA_DRAW_FRAME is the base class for create windows for drawing purpose.
Definition: draw_frame.h:54
COLOR4D m_drawBgColor
the background color of the draw canvas BLACK for Pcbnew, BLACK or WHITE for eeschema ...
Definition: draw_frame.h:84
Class TITLE_BLOCK holds the information shown in the lower right corner of a plot, printout, or editing view.
Definition: title_block.h:39
wxChoice * m_gridSelectBox
Choice box to choose the grid size.
Definition: draw_frame.h:119
COLOR4D m_gridColor
Grid color.
Definition: draw_frame.h:83
std::unique_ptr< wxSingleInstanceChecker > m_file_checker
prevents opening same file multiple times.
Definition: draw_frame.h:75
double GetZoomLevelCoeff() const
Function GetZoomLevelCoeff returns the coefficient to convert internal display scale factor to zoom l...
Definition: draw_frame.h:425
void OnMouseEvent(wxMouseEvent &event)
virtual bool IsGridVisible() const
Function IsGridVisible() , virtual.
Definition: draw_frame.h:486
bool m_canvasTypeDirty
Flag indicating that drawing canvas type needs to be saved to config.
Definition: draw_frame.h:145
virtual void ExecuteRemoteCommand(const char *cmdline)
Execute a remote command send via a socket to the application, port KICAD_PCB_PORT_SERVICE_NUMBER (cu...
Definition: draw_frame.h:363
Class TOOL_MANAGER.
Definition: tool_manager.h:49
bool m_showOriginAxis
True shows the origin axis used to indicate the coordinate offset for drill, gerber, and component position files.
Definition: draw_frame.h:110
virtual BASE_SCREEN * GetScreen() const
Function GetScreen returns a pointer to a BASE_SCREEN or one of its derivatives.
Definition: draw_frame.h:352
Class LSET is a set of PCB_LAYER_IDs.
wxAuiToolBar * m_optionsToolBar
The options tool bar typcially located on the left edge of the main window.
Definition: draw_frame.h:129
BASE_SCREEN * m_currentScreen
current used SCREEN
Definition: draw_frame.h:63
virtual COLOR4D GetDrawBgColor() const
Definition: draw_frame.h:329
EDA_HOTKEY_CONFIG * m_hotkeysDescrList
Definition: draw_frame.h:77
void OnEraseBackground(wxEraseEvent &event)
EDA_MSG_PANEL * m_messagePanel
Panel used to display information at the bottom of the main window.
Definition: draw_frame.h:132
Class PAGE_INFO describes the page size and margins of a paper page on which to eventually print or p...
Definition: page_info.h:49
bool m_showBorderAndTitleBlock
True shows the drawing border and title block.
Definition: draw_frame.h:113
Class BASE_SCREEN handles how to draw a screen (a board, a schematic ...)
Definition: base_screen.h:76
wxChoice * m_zoomSelectBox
Choice box to choose the zoom value.
Definition: draw_frame.h:122
std::unique_ptr< wxSingleInstanceChecker > LockFile(const wxString &aFileName)
Function LockFile tests to see if aFileName can be locked (is not already locked) and only then retur...
Definition: lockfile.cpp:32
Base window classes and related definitions.
bool m_showGridAxis
True shows the grid axis indicators.
Definition: draw_frame.h:106
Class KIWAY is a minimalistic software bus for communications between various DLLs/DSOs (DSOs) within...
Definition: kiway.h:258
uint32_t EDA_KEY
Definition: common.h:52
wxString LengthDoubleToString(double aValue, bool aConvertToMils)
Function LengthDoubleToString is a helper to convert the double length aValue to a string in inches...
Definition: base_units.cpp:123
bool IsGalCanvasActive() const
Function IsGalCanvasActive is used to check which canvas (GAL-based or standard) is currently in use...
Definition: draw_frame.h:874
int m_UndoRedoCountMax
default Undo/Redo command Max depth, to be handed
Definition: draw_frame.h:89
int m_LastGridSizeId
Definition: draw_frame.h:78
virtual COLOR4D GetGridColor()
Function GetGridColor() , virtual.
Definition: draw_frame.h:505
wxAuiToolBar * m_drawToolBar
The tool bar that contains the buttons for quick access to the application draw tools.
Definition: draw_frame.h:126
Class TOOL_DISPATCHER.
EDA_DRAW_PANEL_GAL * m_galCanvas
GAL display options - this is the frame&#39;s interface to setting GAL display options.
Definition: draw_frame.h:68
EDA_DRAW_PANEL * m_canvas
The area to draw on.
Definition: draw_frame.h:93
TOOL_MANAGER * GetToolManager() const
Function GetToolManager returns the tool manager instance, if any.
Definition: draw_frame.h:889
class EDA_HOTKEY is a class to handle hot key commands.
Definition: hotkeys_basic.h:57
void OnCharHook(wxKeyEvent &event)
int m_MsgFrameHeight
Definition: draw_frame.h:134
void OnActivate(wxActivateEvent &event)
Function OnActivate handles window activation events.
Definition: draw_panel.cpp:414
int GetToolId() const
Definition: draw_frame.h:476
Class EDA_RECT handles the component boundary box.
Definition: eda_rect.h:44
Class EDA_ITEM is a base class for most all the KiCad significant classes, used in schematics and boa...
Definition: base_struct.h:180
bool m_showPageLimits
true to display the page limits
Definition: draw_frame.h:82
bool OnRightClick(wxMouseEvent &event)
Function OnRightClick builds and displays a context menu on a right mouse button click.
Definition: draw_panel.cpp:900
Class ACTIONS.
Definition: actions.h:41
virtual bool GeneralControl(wxDC *aDC, const wxPoint &aPosition, EDA_KEY aHotKey=0)
Function GeneralControl performs application specific control using aDC at aPosition in logical units...
Definition: draw_frame.h:594
EDA_DRAW_PANEL_GAL * GetGalCanvas() const
Function GetGalCanvas returns a pointer to GAL-based canvas of given EDA draw frame.
Definition: draw_frame.h:882
virtual void SetGridVisibility(bool aVisible)
Function SetGridVisibility() , virtual It may be overloaded by derived classes.
Definition: draw_frame.h:496
void SetShowPageLimits(bool aShow)
Definition: draw_frame.h:340
bool GetToolToggled(int aToolId)
Checks all the toolbars and returns true if the given tool id is toggled.
Definition: draw_frame.h:445
ACTIONS * m_actions
Definition: draw_frame.h:97
bool m_movingCursorWithKeyboard
One-shot to avoid a recursive mouse event during hotkey movement.
Definition: draw_frame.h:142
int m_lastDrawToolId
Tool ID of previously active draw tool bar button.
Definition: draw_frame.h:100
void SetShowBorderAndTitleBlock(bool aShow)
Definition: draw_frame.h:338
virtual void * GetDisplayOptions()
Function GetDisplayOptions A way to pass info to draw functions.
Definition: draw_frame.h:897
long m_firstRunDialogSetting
Key to control whether first run dialog is shown on startup.
Definition: draw_frame.h:116
bool m_snapToGrid
Indicates if cursor should be snapped to grid.
Definition: draw_frame.h:65
Class COLOR4D is the color representation with 4 components: red, green, blue, alpha.
Definition: color4d.h:39