wxPython menu doesn't display image

后端 未结 2 1944
小鲜肉
小鲜肉 2021-01-06 11:45

I am creating a menu and assigning images to menu items, sometime first item in menu doesn\'t display any image, I am not able to find the reason. I have tried to make a sim

2条回答
  •  星月不相逢
    2021-01-06 12:21

    This hack does not appear to be necessary if you create each menu item with wx.MenuItem(), set its bitmap, and only then append it to the menu. This causes the bitmaps to show up correctly. I'm testing with wxPython 2.8.10.1 on Windows.

提交回复
热议问题