BT-MatML-Editor 0.1.4
Editor for the MatML 3.1 XML Schema
BT_MatML_Geometry_GUI.h
1
2// Name: BT_MatML_Geometry_GUI.h
3// Purpose: Classes of Geometry_GUI Base and Derived.
4// Author: Paul McGrath
5// Modified by:
6// Created:
7// Copyright: (c) Paul McGrath
8// Licence: CC licence
10#pragma once
11
12
13// For compilers that support precompilation, includes "wx/wx.h".
14#include "wx/wxprec.h"
15
16
17#ifndef WX_PRECOMP
18#include "wx/wx.h"
19#endif
20
21#include <wx/dcsvg.h>
22#include <wx/notebook.h>
23#include <wx/string.h>
24
25#include <math.h>
26#include <string.h>
27#include "StringStream.h"
28
29#include "matml31.hxx"
30
31#include "BT_MatML_Base_GUI.h"
32#include "BT_MatML_MatMLInfo_GUI.h"
33
34#include "BT_MatML_GUI.h"
35#include "BT_MatML_MatMLTreeItemData.h"
36#include "BT_MatML_TreeCtrlSorted.h"
37
38namespace bellshire {
39
41 {
42 public:
43 wxNotebook* m_GUI;
44
46 Geometry_GUI_Base(wxWindow* parent);
47 static wxNotebook* Create(wxWindow* parent);
48 virtual ~Geometry_GUI_Base();
49
50 void Show(bool show = true) { if (m_GUI != nullptr) m_GUI->Show(show); };
51 bool IsShown() { return m_GUI->IsShown(); };
52 wxNotebook* get() { return m_GUI; };
53
54 void Update( Geometry* element);
55 static wxTreeItemId SetupMatMLTreeCtrl(TreeCtrlSorted*& MatMLTreeCtrl,
56 const wxTreeItemId& ParentId,
58 const wxTreeItemId& PreviousId
59 );
60
61 void SetConnect() {};
62 virtual void OnInsertShape(wxCommandEvent& event) { event.Skip(); }
63 virtual void OnInsertDimensions(wxCommandEvent& event){ event.Skip(); }
64 virtual void OnInsertOrientation(wxCommandEvent& event){ event.Skip(); }
65 virtual void OnInsertNotes(wxCommandEvent& event){ event.Skip(); }
66
67 virtual void OnDeleteNotes(wxCommandEvent& event) { event.Skip(); }
68
69 virtual void OnPasteShape(wxCommandEvent& event) { event.Skip(); }
70 virtual void OnPasteDimensions(wxCommandEvent& event) { event.Skip(); }
71 virtual void OnPasteOrientation(wxCommandEvent& event) { event.Skip(); }
72 virtual void OnPasteNotes(wxCommandEvent& event) { event.Skip(); }
73
74 private:
75 };
76
77
79 {
80 public:
81 TreeCtrlSorted* m_MatMLTreeCtrl;//Required before Event Handling.
82 ::boost::any m_MatMLItemToCopy;//Required before Paste Event Handling.
83
85 Geometry_GUI(wxWindow* parent);
86
87 virtual ~Geometry_GUI();
88
89 void SetEvtHandlerVar(TreeCtrlSorted*& MatMLTreeCtrl);//Required before Event Handling.
90 void SetMatMLTreeCtrl(TreeCtrlSorted*& MatMLTreeCtrl);
91 void SetMatMLItemToCopy(const ::boost::any& MatMLItemToCopy);//Required before paste Event Handling.
92
93 //Overwrites the base class functions
94 void OnInsertShape(wxCommandEvent& event);
95 void OnInsertDimensions(wxCommandEvent& event);
96 void OnInsertOrientation(wxCommandEvent& event);
97 void OnInsertNotes(wxCommandEvent& event);
98
99 void OnDeleteNotes(wxCommandEvent& event);
100
101 void OnPasteShape(wxCommandEvent& event);
102 void OnPasteDimensions(wxCommandEvent& event);
103 void OnPasteOrientation(wxCommandEvent& event);
104 void OnPasteNotes(wxCommandEvent& event);
105
106 private:
107 };
108
109}; //namespace bellshire end
110#pragma once
Definition: matml31.hxx:1705
Definition: matml31.hxx:1941
Definition: BT_MatML_Geometry_GUI.h:41
static wxNotebook * Create(wxWindow *parent)
Create the GUI for the Geometry MatML Data and Info
Definition: BT_MatML_Geometry_GUI.cpp:27
static wxTreeItemId SetupMatMLTreeCtrl(TreeCtrlSorted *&MatMLTreeCtrl, const wxTreeItemId &ParentId, Geometry &Element, const wxTreeItemId &PreviousId)
This set-up the Parent MatML Data into a wxTreeCtrl element and then call on the Children to do the s...
Definition: BT_MatML_Geometry_GUI.cpp:73
Definition: BT_MatML_Geometry_GUI.h:79
Geometry_GUI()
Constructor for the derived class
Definition: BT_MatML_Geometry_GUI.cpp:129
void SetEvtHandlerVar(TreeCtrlSorted *&MatMLTreeCtrl)
Function used to set up this objects member variables which is used in the EventHandler's functions....
Definition: BT_MatML_Geometry_GUI.cpp:160
void SetMatMLTreeCtrl(TreeCtrlSorted *&MatMLTreeCtrl)
Set the Event Handler associated with the MatML wxTreeCtrl Required before using the derived class's ...
Definition: BT_MatML_Geometry_GUI.cpp:170
virtual ~Geometry_GUI()
Destructor for the derived class
Definition: BT_MatML_Geometry_GUI.cpp:151
Definition: BT_MatML_Base_GUI.h:163
Definition: BT_MatML_TreeCtrlSorted.h:19
Contains the GUI and GUI associated classes. OnInit() calls the creation of the MaterialFrame GUI
Definition: BT_MatML_App.h:39