Search found 28 matches

by Nefarious
Thu May 18, 2017 10:18 pm
Forum: C++ Development
Topic: Using new wxEventType
Replies: 1
Views: 369

Using new wxEventType

I have two wxPanel classes that have their own cpp and hpp files. One of the classes wants to send a message to the other and I can't see how to make the simple discussion here https://wiki.wxwidgets.org/Custom_Events work. If I use wxDEFINE_EVENT(MY_DIRTY_COMMAND, wxCommandEvent); in one file, I ca...
by Nefarious
Thu May 18, 2017 8:50 pm
Forum: C++ Development
Topic: Custom Control message event handler not being called
Replies: 3
Views: 417

Re: Custom Control message event handler not being called

Thank you for the help. I somehow got it to work, not sure what I did. The real questions is, is there a way to look at the event handler list and see what is defined for a wxWindow. If something is wrong, I haven't found a way to systematically look at the right things to get my app to execute prop...
by Nefarious
Wed May 17, 2017 7:47 pm
Forum: C++ Development
Topic: Custom Control message event handler not being called
Replies: 3
Views: 417

Custom Control message event handler not being called

I am just trying to figure this out so I can build a real control. I have a class that sub classes wxPanel. at the end of the class definition for this class I added wxDECLARE_EVENT_TABLE(); } The event table for the class is simple and has one entry and and si_CONTROL_FREQUENCY_SLIDER is an enum at...
by Nefarious
Thu Apr 27, 2017 5:20 pm
Forum: C++ Development
Topic: Text Based Spinner
Replies: 3
Views: 438

Re: Text Based Spinner

That's exactly what I thought to do. There is one issue in that the wxSpinCtrl manages the text control and the spinner as a single control and adjusts the size of the wxSpinner to fit in the same space when inserted into sizer. I tried a wxSpinCtrl and a wxStaticText + wxSpinner in two rows of the ...
by Nefarious
Thu Apr 27, 2017 4:33 pm
Forum: C++ Development
Topic: Text Based Spinner
Replies: 3
Views: 438

Text Based Spinner

Has anyone built a spinner that chooses between a set of text values instead of numbers? The use is a little different then the standard spinner in that the user would not be able to type in the text control to edit the value. If this could be done to the wxSpinCtrl then hooking the spin up and spin...
by Nefarious
Wed Apr 26, 2017 2:45 pm
Forum: C++ Development
Topic: wxStaticBox with wxGridSizer cuts off wxStaticBox label
Replies: 1
Views: 373

wxStaticBox with wxGridSizer cuts off wxStaticBox label

I create a static box and a grid sizer so I can put some controls in it as follows: mImageControl = new wxStaticBox(this, wxID_ANY, "Image Control", wxDefaultPosition, wxDefaultSize, 0, "Image"); wxGridSizer* pGSizer = new wxGridSizer(2, 0, 0); // two columns and no gap pGSizer->Add(CreateCeilingCon...
by Nefarious
Fri Apr 07, 2017 7:46 pm
Forum: C++ Development
Topic: wxSizer Detach
Replies: 4
Views: 706

Re: wxSizer Detach

Good to know, I am pretty new to wxWidgets and am just learning the ropes.

I just went to wxSimpleBook and it seems to be good enough for the demo. I do appreciate your input, I will try that over the weekend after I give the demo :)
by Nefarious
Fri Apr 07, 2017 6:59 pm
Forum: C++ Development
Topic: wxSizer Detach
Replies: 4
Views: 706

wxSizer Detach

I have a deadline for tonight to put together a demo and I was hoping I could make the following work. I will use SimpleBook if I have to but why doesn't this work? I have two wxPanel derived classes, PanelOne and PanelTwo; I create an instance of both of them and add pPanelOne to a sizer and set th...
by Nefarious
Fri Apr 07, 2017 5:25 pm
Forum: C++ Development
Topic: wxToolBar and AddStreachableSpace
Replies: 5
Views: 519

Re: wxToolBar and AddStreachableSpace

I called Realize() on the toolbar. I added a call to Layout() and it is the same. I changed the order of things and it now works correct. The toolbar has to be added before the sizer is set and fit. The toolbar has to be added before the call SetSizerAndFit(mpSizer); The toolbar shows up and works c...
by Nefarious
Fri Apr 07, 2017 3:51 pm
Forum: C++ Development
Topic: wxToolBar and AddStreachableSpace
Replies: 5
Views: 519

Re: wxToolBar and AddStreachableSpace

I just want the application to run with the toolbar with the stretch applied?
by Nefarious
Fri Apr 07, 2017 3:26 pm
Forum: C++ Development
Topic: wxToolBar and AddStreachableSpace
Replies: 5
Views: 519

wxToolBar and AddStreachableSpace

I am implementing a toolbar that has AddStretchableSpace() between a couple of buttons. When the application comes up the at first the stretch isn't added. When I resize the application the stretch appears. I have followed the toolbar sample but my application is much simpler, there are no controls ...
by Nefarious
Fri Apr 07, 2017 3:14 pm
Forum: Compiler / Linking / IDE Related
Topic: Freechart 1.6
Replies: 5
Views: 1305

Re: Freechart 1.6

There is a significant issue with using wxFreechart to dynamically draw graphs. First there is no easy way to change the data in a dataset, at least that I have found. And the instance variable for the data is private to the class. I am not sure about exactly how the license work, but this makes it ...
by Nefarious
Thu Apr 06, 2017 4:34 pm
Forum: Compiler / Linking / IDE Related
Topic: Freechart 1.6
Replies: 5
Views: 1305

Re: Freechart 1.6

I got a chart to draw by including the src and include directories into my project. This is not for production use, it is just a tool so although it is cumbersome, it works. All that said, is this project dead? I assume there are people using it, is there a place to ask questions? I am using a bar c...
by Nefarious
Thu Apr 06, 2017 5:44 am
Forum: Compiler / Linking / IDE Related
Topic: Freechart 1.6
Replies: 5
Views: 1305

Freechart 1.6

I am trying to use freechart 1.6 with wxWidgets.3.1.0 and I can't make sense of how to map the options. I tried all possibilities of: nmake -fmakefile.vc WX_DIR=C:\wxSpace WX_UNICODE=0 WX_DEBUG=0 WX_SHARED=0 WX_MONOLITHIC=0 and for every option after the one I thought should work gives the message: ...
by Nefarious
Wed Mar 22, 2017 9:45 pm
Forum: C++ Development
Topic: wxSpinButton
Replies: 9
Views: 1155

Re: wxSpinButton

I have it all working now. The spin button has the correct value after the event is complete. During the event I use event.GetInt() for the new value and after the event I use spinButton->GetValue(); It just turns out that I was using spinButton->GetValue() in a method called by the handler and I ne...