【问题标题】:wxPython TextCtrl Transparent BackgroundwxPython TextCtrl 透明背景
【发布时间】:2013-07-28 01:47:18
【问题描述】:

如何使 TextCtrl 具有透明背景?我的意思是看到它背后的桌面。

当前代码:

self.control.SetBackgroundColour(wx.Color(0,0,0,0))

但这只会使背景颜色变黑。

我在 Windows 7 上使用 Python 2.7

【问题讨论】:

    标签: python wxwidgets


    【解决方案1】:

    据我所知textCtrt 不能透明或使用背景图片,但您可以更改背景颜色。

    提示:

    您可以通过找出确切的 HEX 颜色值来使用确切的颜色作为背景图像。

    示例代码:

    self.SetBackgroundColour('#232321')
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2011-03-08
      • 1970-01-01
      • 2021-09-20
      • 2019-02-07
      • 2020-10-15
      • 2017-06-22
      • 2010-10-20
      相关资源
      最近更新 更多