Fix file picker control with wxFLP_USE_TEXTCTRL on macOS Tahoe (PR #26952)

35 views
Skip to first unread message

Viktor Ivanov

unread,
Aug 29, 2026, 8:29:19 AM (3 days ago) Aug 29
to wx-...@googlegroups.com, Subscribed

Before:
Image: image (view on web)

After:
Image: image (view on web)


You can view, comment on, or merge this pull request online at:

  https://github.com/wxWidgets/wxWidgets/pull/26952

Commit Summary

  • 0a29cc3 Fix file picker control with wxFLP_USE_TEXTCTRL on macOS Tahoe

File Changes

(1 file)

Patch Links:


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952@github.com>

VZ

unread,
Aug 30, 2026, 7:07:58 PM (2 days ago) Aug 30
to wx-...@googlegroups.com, Subscribed

@vadz commented on this pull request.

Thanks for the patch! We need to fix this, of course, but I find the idea of sprinkling the common code with the calls to MacClipsToBounds() a bit suboptimal... @csomor Can we do it automatically somehow? Does it need to be done for any control which has children? If so, could we call it from AddChild()? Or what are the exact conditions triggering the need for this call?


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/review/5062138647@github.com>

Stefan Csomor

unread,
Aug 31, 2026, 3:27:13 AM (yesterday) Aug 31
to wx-...@googlegroups.com, Subscribed
csomor left a comment (wxWidgets/wxWidgets#26952)

@vadz the problem is the "bleeding" of macOS Tahoe TextControl Borders outside the control's area.

I had to introduce clipping because of problems like #23916 in Sonoma, went too far with it, @vslavik then added 74d75d4 so right now wxPanels do clip by default, so we keep the fix from above, but we have to turn it off for composite controls where the textcontrol is packed tightly, like the wxSpinCtrlGeneric,

I don't think we should turn it off by default as soon as a text control is added because this could reintroduce the problem of bleeding wxPanels when in a scrolling area.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/c5475158692@github.com>

Václav Slavík

unread,
Aug 31, 2026, 3:31:12 AM (yesterday) Aug 31
to wx-...@googlegroups.com, Subscribed
vslavik left a comment (wxWidgets/wxWidgets#26952)

FWIW I agree with Stefan here.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/c5475196359@github.com>

VZ

unread,
Aug 31, 2026, 10:05:47 AM (22 hours ago) Aug 31
to wx-...@googlegroups.com, Subscribed
vadz left a comment (wxWidgets/wxWidgets#26952)

I see, thanks for the explanation. It would still be great to find some way to do this automatically because the same problem affects any composite controls defined in the user code.

What about the following hack: in wxTextCtrl::DoSetSize() check if it's been positioned at (0,0) in its parent1 and disable clipping in this case? This should take care of both this and of the existing use of MacClipsToBounds() in wxSpinCtrlGeneric code added by Vaclav in cc0fd2c (Improve wxSpinCtrl sizing and appearance on macOS, 2025-09-07). It is definitely a hack, but I don't see anything better and this is, IMHO, better than nothing.

Footnotes

  1. It could be generalized by checking if any side of wxTextCtrl is exactly at the border of the parent.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/c5479513223@github.com>

Stefan Csomor

unread,
Aug 31, 2026, 10:11:05 AM (22 hours ago) Aug 31
to wx-...@googlegroups.com, Subscribed
csomor left a comment (wxWidgets/wxWidgets#26952)

Yes, we could try to come up with some scheme like this, I'll try to find out whether this would not trigger false positives


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/c5479578926@github.com>

Viktor Ivanov

unread,
Aug 31, 2026, 10:54:38 AM (21 hours ago) Aug 31
to wx-...@googlegroups.com, Subscribed
itmo153277 left a comment (wxWidgets/wxWidgets#26952)

Not sure if my opinion matters much, but I would prefer if users could control whether clipping is needed. It could be exposed via window styles or something similar. There are a bunch of msw-only styles, so there could be a mac-only one too. Auto-detection is good, but I hate doing hacks around it if it fails when there is no proper manual control over how it behaves.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/c5480125537@github.com>

VZ

unread,
Aug 31, 2026, 10:59:48 AM (21 hours ago) Aug 31
to wx-...@googlegroups.com, Subscribed
vadz left a comment (wxWidgets/wxWidgets#26952)

Everybody's opinion is welcome, of course.

But I dislike styles, I don't see how does using a style is better than just calling MacClipsToBounds() from your code. The latter requires preprocessor checks, but we could promote it down to wxWindowBase::SetClipsToBounds() and just let it do nothing under non-Mac platforms for now.

Neither style nor function is discoverable, however, which is why I think it's important for things to work out of the box in as many cases as possible (even if I agree that we still need a way to override the auto-detection).


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26952/c5480188447@github.com>

Reply all
Reply to author
Forward
0 new messages