开发者

Make a pygtk stock icon "unavailable"

I have a toolbar that has the typical 开发者_StackOverflow中文版buttons: new, save, save as, etc. Is there a way to gray out/disable/make unavailable icons that are not useful?

For instance, if nothing has been changed, disable and gray out the save button, then re-enabled it when something has changed that requires a save.

Thanks for the help!


myButton.set_sensitive(True) # make button available

myButton.set_sensitive(False) # make button unavailable

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜