Misc changes

This commit is contained in:
Timothy Warren 2015-04-01 15:15:29 -04:00
parent a4449a64b3
commit 7d94beb874
5 changed files with 24 additions and 12 deletions

View File

@ -5,7 +5,7 @@ END_EVENT_TABLE()
DocFrame::DocFrame(wxWindow *parent, wxWindowID id)
{
//editor = new wxStyledTextCtrl(this);
editor = new wxStyledTextCtrl(parent);
}
DocFrame::~DocFrame()

View File

@ -13,7 +13,7 @@ public:
DocFrame(wxWindow *parent, wxWindowID id);
~DocFrame();
private:
//wxStyledTextCtrl *editor;
wxStyledTextCtrl *editor;
DECLARE_EVENT_TABLE()
};

View File

@ -28,9 +28,7 @@ TyroFrame::TyroFrame(wxFrame *frame, const wxString& title)
this->SetupMenu();
// create a status bar with some information about the used wxWidgets version
CreateStatusBar(2);
SetStatusText(_(""), 0);
SetStatusText(_(""), 1);
// Set up control layout
wxBoxSizer *base_sizer = new wxBoxSizer(wxVERTICAL);
@ -51,6 +49,17 @@ TyroFrame::TyroFrame(wxFrame *frame, const wxString& title)
TyroFrame::~TyroFrame() {}
void TyroFrame::SetupStatusBar()
{
CreateStatusBar(2);
SetStatusText(_(""), 0);
SetStatusText(_(""), 1);
}
void TyroFrame::SetupToolbar()
{
}
void TyroFrame::SetupMenu()
{
// create a menu bar
@ -95,10 +104,10 @@ wxAuiNotebook *TyroFrame::CreateNotebook()
wxAuiNotebook *ctrl = new wxAuiNotebook(this);
//DocFrame *editor = new DocFrame(ctrl, wxID_ANY);
wxWindow *editor = new wxWindow(ctrl, wxID_ANY);
DocFrame *editor = new DocFrame(ctrl, wxID_ANY);
//wxWindow *editor = new wxWindow(ctrl, wxID_ANY);
ctrl->AddPage(editor, "Untitled");
//ctrl->AddPage(editor, "Untitled");
return ctrl;
}

View File

@ -29,6 +29,8 @@ class TyroFrame: public wxFrame
idMenuAbout
};
void SetupMenu();
void SetupToolbar();
void SetupStatusBar();
void OnMenuFileOpen(wxCommandEvent &event);
void OnMenuFileSave(wxCommandEvent &event);
void OnClose(wxCloseEvent &event);

View File

@ -11,6 +11,7 @@
#define TYROAPP_H
#include <wx/app.h>
#include <wx/debug.h>
#include <wx/aui/aui.h>
class TyroApp : public wxApp