c++ - How can I change the border? -
I create a simple window with wxwidgets How can I change the border? Also, how can I call deleted function (onclos) with the right arrow button press?
#include & lt; Wx / wx.h & gt; Square _frame: public wxframe {public: _Frame (wxFrame * frame, const wxString and title); Private: Zero onClose (wxCloseEvent and Event); DECLARE_EVENT_TABLE ()}; BEGIN_EVENT_TABLE (_Frame, wxFrame) END_EVENT_TABLE () _Frame :: _ frame (wxFrame * frame, constant wxString & title): wxFrame (frame, -1, title) {} zero _Frame :: OnClose (wxCloseEvent & Event) {Destroyed (); } Class _App: Public wxApp {Public: Virtual Bull OnInit (); }; IMPLEMENT_APP (_App); Bool _App :: OnInit () {_Frame * frame = new_frame (0L, _ ("wxWidgets app template")); Frame & gt; Show (); Back true; } Right after the window closes on the item "itemprop =" text "> after the" div class = "
Then there is a need:
header file:
zero onChar (wxKeyEvent & incident);
Source file:
zero _Frame :: OnChar (wxKeyEvent & Incident) {if (event.GetKeyCode () == WXK_RIGHT) {wxCommandEvent Pass (wxEVT_CLOSE_WINDOW); AddPendingEvent (Nearby); } Event.Skip (); } BEGIN_EVENT_TABLE (_Frame, wxFrame) EVT_CHAR (_Frame :: OnChar) END_EVENT_TABLE ()
Comments
Post a Comment