开发者

Access native windows icons for custom wxDialogs

开发者 https://www.devze.com 2023-01-08 00:05 出处:网络
I want to subclass wx.Dialog to get a little more functionality than is provided by the wx.MessageDialog class but I would still like to be able to use the native window开发者_运维百科s icons (ie the

I want to subclass wx.Dialog to get a little more functionality than is provided by the wx.MessageDialog class but I would still like to be able to use the native window开发者_运维百科s icons (ie the ones used in the wx.MessageDialog that can be set by the flags such as wx.ICON_ERROR etc.. )

Is there anyway to access these?

Update:

Thanks to steven for pointing out that this can easily be accomplished with wx.ArtProvider

e.g.

wx.ArtProvider.GetBitmap(wx.ART_ERROR, wx.ART_CMN_DIALOG)


This should do the trick:

wx.ArtProvider.GetBitmap(wx.ART_ERROR, wx.ART_CMN_DIALOG)


Not sure how you'd do in in wx, but here's a Microsoft article on how to do it with the native API:

http://msdn.microsoft.com/en-us/magazine/cc188763.aspx

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号