wxQt: invalid use of enum class wxMDIParentFrma::Layout() (Issue #25742)

28 views
Skip to first unread message

oneeyeman1

unread,
Aug 29, 2025, 11:23:55 PMAug 29
to wx-...@googlegroups.com, Subscribed
oneeyeman1 created an issue (wxWidgets/wxWidgets#25742)

Description

Building my application against wxQt, I got the error in the subject line.

The library is built successfully with configure--enable-debug --with-qt

Platform and version information

  • wxWidgets version you use:
  • wxWidgets port you use:
  • OS and its version:
    • GTK version:
    • Which GDK backend is used:
    • Desktop environment :
    • Current theme:


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issues/25742@github.com>

VZ

unread,
Aug 30, 2025, 8:26:23 AMAug 30
to wx-...@googlegroups.com, Subscribed

Closed #25742 as not planned.


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issue/25742/issue_event/19423695494@github.com>

paulcor

unread,
Aug 30, 2025, 2:39:55 PMAug 30
to wx-...@googlegroups.com, Subscribed
paulcor left a comment (wxWidgets/wxWidgets#25742)

It seems like there is a legitimate problem here. Layout() window method is hidden by an enum:
https://github.com/wxWidgets/wxWidgets/blob/510c5d1e084375cafcb9c47c5162074f21b3db1e/include/wx/qt/mdi.h#L39
I don't know if it makes sense to call Layout() on a wxMDIParentFrame, but if something did, it could cause a significant change in behavior with only a compiler warning.

diff --git a/samples/mdi/mdi.cpp b/samples/mdi/mdi.cpp
index 14453fff87..cd259cfa84 100644
--- a/samples/mdi/mdi.cpp
+++ b/samples/mdi/mdi.cpp
@@ -218,6 +218,8 @@ MyFrame::MyFrame()
 
     // connect it only now, after creating m_textWindow
     Bind(wxEVT_SIZE, &MyFrame::OnSize, this);
+
+    Layout();
 }
 
 MyFrame::~MyFrame()
samples/mdi/mdi.cpp:222:13: warning: statement has no effect [-Wunused-value]
  222 |     Layout();
      |             ^


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issues/25742/3239450211@github.com>

VZ

unread,
Aug 30, 2025, 2:51:48 PMAug 30
to wx-...@googlegroups.com, Subscribed

Reopened #25742.


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issue/25742/issue_event/19425065386@github.com>

VZ

unread,
Aug 30, 2025, 2:53:18 PMAug 30
to wx-...@googlegroups.com, Subscribed
vadz left a comment (wxWidgets/wxWidgets#25742)

If the OP provided a way to reproduce the problem, I wouldn't have closed it, but I didn't feel like wasting my time on doing something that would be expected from any bug report.

Anyhow, this enum should probably be renamed to something else, e.g. Kind maybe, to avoid the name conflict. @AliKet what do you think?


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issues/25742/3239456028@github.com>

VZ

unread,
Nov 16, 2025, 12:39:54 PM (4 days ago) Nov 16
to wx-...@googlegroups.com, Subscribed

Closed #25742 as completed via 06a4a1d.


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issue/25742/issue_event/20973231143@github.com>

Reply all
Reply to author
Forward
0 new messages