Files
CrossGen/wxCrossGen/wxgui.hpp
2015-05-30 18:07:04 +03:00

85 lines
2.0 KiB
C++

// -*- C++ -*-
//
// generated by wxGlade 0.6.8 on Wed May 20 12:40:03 2015
//
// Example for compiling a single file project under Linux using g++:
// g++ MyApp.cpp $(wx-config --libs) $(wx-config --cxxflags) -o MyApp
//
// Example for compiling a multi file project under Linux using g++:
// g++ main.cpp $(wx-config --libs) $(wx-config --cxxflags) -o MyApp Dialog1.cpp Frame1.cpp
//
#ifndef WXGUI_HPP
#define WXGUI_HPP
#include <map>
#include <set>
#include <vector>
#include <wx/wx.h>
#include <wx/image.h>
#include "wx/intl.h"
typedef std::map<wxString,wxString> DictType;
typedef std::vector< std::vector<wxChar> > GridType;
typedef std::vector< std::vector<wxChar> > CurGridType;
// Первый индекс -- длина слова
typedef std::vector< std::vector<wxString> > AllWordsType;
typedef std::set< wxString > UsedWords;
struct WordInfo {
size_t x;
size_t y;
size_t len;
size_t ind;
//true for vertical and false for horisontal
bool direct;
};
#ifndef APP_CATALOG
#define APP_CATALOG "app" // replace with the appropriate catalog name
#endif
// begin wxGlade: ::dependencies
// end wxGlade
// begin wxGlade: ::extracode
// end wxGlade
class MainFrame: public wxFrame {
public:
// begin wxGlade: MainFrame::ids
// end wxGlade
MainFrame(wxWindow* parent, int id, const wxString& title, const wxPoint& pos=wxDefaultPosition, const wxSize& size=wxDefaultSize, long style=wxDEFAULT_FRAME_STYLE);
private:
// begin wxGlade: MainFrame::methods
void set_properties();
void do_layout();
// end wxGlade
protected:
// begin wxGlade: MainFrame::attributes
wxStaticText* label_1;
wxTextCtrl* tPath;
wxButton* btnPath;
wxTextCtrl* tOutput;
wxButton* btnGenerate;
wxStaticBitmap* bPreview;
std::vector<wxString> _words;
// end wxGlade
DECLARE_EVENT_TABLE();
public:
virtual void OnbtnPathClick(wxCommandEvent &event);
virtual void OnbtnGenerateClick(wxCommandEvent &event);
void SetGridImage(GridType &grid, size_t w=400);
}; // wxGlade: end class
#endif // WXGUI_H