Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native error dialog on MacOS does not show exclamation mark icon #2546

Open
wouterbt opened this issue Apr 3, 2024 · 0 comments
Open

Native error dialog on MacOS does not show exclamation mark icon #2546

wouterbt opened this issue Apr 3, 2024 · 0 comments

Comments

@wouterbt
Copy link

wouterbt commented Apr 3, 2024

Operating system: MacOS 14.2.1 (Sonoma)
wxPython version & source: 4.2.1 (Phoenix) installed by pip from wheel wxPython-4.2.1-cp39-cp39-macosx_10_10_universal2.whl
Python version & source: 3.9.12 included with MacOS

Description of the problem:

wx.MessageDialog uses native dialog windows on MacOS. When used with the wx.ICON_ERROR style, it should show an error icon (exclamation mark) in the dialog. However, it only does this in combination with the wx.YES_NO style:
YES_NO-dialog
And not with the wx.OK style or with no other styles (the default):
OK-dialog
The expected behaviour is that the exclamation mark icon is shown in both instances.

Code Example (click to expand)
import wx
app = wx.App()
frame = wx.Frame()

dlg = wx.MessageDialog(frame, 'text', 'Error', wx.ICON_ERROR | wx.OK)
dlg.ShowModal()
dlg.Destroy()

dlg = wx.MessageDialog(frame, 'text', 'Error', wx.ICON_ERROR | wx.YES_NO)
dlg.ShowModal()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant