Search found 19087 matches

by doublemax
Thu Mar 28, 2024 7:55 am
Forum: C++ Development
Topic: Simple serial comms for beginner.
Replies: 3
Views: 34

Re: Simple serial comms for beginner.

There is no serial port support in wxWidgets itself. You can still use wxWidgets for the GUI, and then use another library for the serial port access, e.g. boost asio: https://www.boost.org/doc/libs/1_84_0/doc/html/boost_asio.html Unfortunately the boost documentation is not every beginner friendly....
by doublemax
Thu Mar 28, 2024 6:39 am
Forum: C++ Development
Topic: Easiest method to bind ENTER key to the action method/func for a button
Replies: 2
Views: 33

Re: Easiest method to bind ENTER key to the action method/func for a button

You should have shown how you bind the button event, using Bind() or with an event table. Here's an example using Bind(). As both events generate a wxCommandEvent, you could bind them to the DoAction() method directly. But it's more flexible this way. #include <wx/wx.h> class MyApp : public wxApp { ...
by doublemax
Wed Mar 27, 2024 7:03 pm
Forum: C++ Development
Topic: Main window shuts down on parent refresh
Replies: 2
Views: 44

Re: Main window shuts down on parent refresh

If a program just shuts down, it's most likely a crash in a non-debug build. Suggestion: Create a debug build and learn how to use a debugger. It will save you lots of time. Did you really check all pointers? bSizer54,m_scrolledWindow1, parentDialog ? What type is MainDialog? Why do you call event.S...
by doublemax
Mon Mar 25, 2024 8:29 pm
Forum: C++ Development
Topic: ComboCtrl and ComboPopup focuses can't set at the same time
Replies: 32
Views: 14904

Re: ComboCtrl and ComboPopup focuses can't set at the same time

Did you get some time to look into the query? I don't have much more to add. I still believe you can achieve what you want based on the example in the "combo" sample: https://github.com/wxWidgets/wxWidgets/blob/613a4c46c1807320153685766a466f0022c1e48a/samples/combo/combo.cpp#L513 Instead ...
by doublemax
Mon Mar 25, 2024 8:23 pm
Forum: C++ Development
Topic: wxWidgets inside console DLL
Replies: 3
Views: 61

Re: wxWidgets inside console DLL

Just look at the "console" sample that comes with the wxWidgets sources.
https://github.com/wxWidgets/wxWidgets/ ... onsole.cpp
by doublemax
Sat Mar 23, 2024 9:41 am
Forum: C++ Development
Topic: Suggestion to display list of images and text in twitter clone
Replies: 10
Views: 357

Re: Suggestion to display list of images and text in twitter clone

I added a wxScrollWinEvent event but this only detects the position if the user clicks on the scroll itself. I does *Not* detect it scrolling by mouse wheel down on the wxScrolledWindow client area (It catches the event, not the position of the child windows) void OnScroll(wxScrollWinEvent& eve...
by doublemax
Fri Mar 22, 2024 6:27 pm
Forum: C++ Development
Topic: How to change notebook border color from white to gray?
Replies: 3
Views: 144

Re: How to change notebook border color from white to gray?

As wxWidgets uses native controls where ever possible, the answer is most likely "not possible". But could you post an image that shows which border you're talking about anyway?
by doublemax
Fri Mar 22, 2024 9:14 am
Forum: C++ Development
Topic: wxDataViewListCtrl getting column of selected row
Replies: 14
Views: 3119

Re: wxDataViewListCtrl getting column of selected row

You need to determine the item and column before you show the popup menu. Use wxWindow::GetPopupMenuSelectionFromUser() to show the popup. It's a blocking call, so when it returns, you still have the information about the selected item. https://docs.wxwidgets.org/trunk/classwx_window.html#a9b7de6ea8...
by doublemax
Thu Mar 21, 2024 5:55 pm
Forum: C++ Development
Topic: wxDataViewListCtrl getting column of selected row
Replies: 14
Views: 3119

Re: wxDataViewListCtrl getting column of selected row

zybertanc wrote: Thu Mar 21, 2024 5:20 pm I'm working on Windows.
In that case the code from viewtopic.php?p=182658#p182658 should work. Did you try it?

If yes, what are the exact circumstances under which this does not work?
by doublemax
Thu Mar 21, 2024 8:51 am
Forum: Compiler / Linking / IDE Related
Topic: Albeit statically linked, dll is missing
Replies: 4
Views: 582

Re: Albeit statically linked, dll is missing

Hello, and welcome to the forum! Knowing the name of the DLL would have been helpful... In general, all you did sounds sufficient for a build without external dependencies. I have built (compiled and linked) the wxWidgets libraries (debug, release, debug dll and release dll) from Source Why did you ...
by doublemax
Wed Mar 20, 2024 9:52 pm
Forum: Compiler / Linking / IDE Related
Topic: Visual C++ IDE build error messages: 'static_cast': cannot convert from 'const _T' to 'wchar_t *'
Replies: 9
Views: 347

Re: Visual C++ IDE build error messages: 'static_cast': cannot convert from 'const _T' to 'wchar_t *'

louistent2014 wrote: Wed Mar 20, 2024 7:04 pm Is that possible that you can share your successfully built libs and dlls in the URL link so that I can download them and see if they work with my own project. I appreciate your help.
Link to lib/vc_x64_dll (debug only) files: https://www.sendspace.com/file/mmitlo
by doublemax
Tue Mar 19, 2024 6:23 am
Forum: C++ Development
Topic: How to make a child window of a wxFrame grow with the frame on resize?
Replies: 1
Views: 104

Re: How to make a child window of a wxFrame grow with the frame on resize?

Both variants should work (you should use GetParent()->GetClientSize() to be exact). Complete, working sample: #include <wx/wx.h> class MyApp : public wxApp { public: virtual bool OnInit(); }; wxIMPLEMENT_APP(MyApp); class MyFrame : public wxFrame { public: MyFrame() : wxFrame(NULL, wxID_ANY, "...
by doublemax
Mon Mar 18, 2024 10:36 pm
Forum: C++ Development
Topic: StaticBoxSizer hidden name
Replies: 7
Views: 247

Re: StaticBoxSizer hidden name

bakl wrote: Mon Mar 18, 2024 9:44 pm I'll report it as a bug, but for now any Ideas on how to make it show the whole label?
A quick and dirty way would be to set a minimum width of the staticbox.
by doublemax
Mon Mar 18, 2024 8:47 pm
Forum: C++ Development
Topic: Changing format of LogMessage
Replies: 6
Views: 225

Re: Changing format of LogMessage

Code: Select all

wxString LogFormatter::Format ( wxLogLevel level, const wxString& msg )
Does your Format() method even get called?

According to the documentation it has a different signature:

Code: Select all

wxString Format (wxLogLevel level, const wxString &msg, const wxLogRecordInfo &info) const
by doublemax
Mon Mar 18, 2024 8:31 pm
Forum: C++ Development
Topic: StaticBoxSizer hidden name
Replies: 7
Views: 247

Re: StaticBoxSizer hidden name

The original screenshot looks like it uses a font scaling of around 200-300%. I don't know how this is handled under Linux, but can you try with default settings?