<tfoot id='xHQJr'></tfoot>

        <small id='xHQJr'></small><noframes id='xHQJr'>

      1. <i id='xHQJr'><tr id='xHQJr'><dt id='xHQJr'><q id='xHQJr'><span id='xHQJr'><b id='xHQJr'><form id='xHQJr'><ins id='xHQJr'></ins><ul id='xHQJr'></ul><sub id='xHQJr'></sub></form><legend id='xHQJr'></legend><bdo id='xHQJr'><pre id='xHQJr'><center id='xHQJr'></center></pre></bdo></b><th id='xHQJr'></th></span></q></dt></tr></i><div id='xHQJr'><tfoot id='xHQJr'></tfoot><dl id='xHQJr'><fieldset id='xHQJr'></fieldset></dl></div>
      2. <legend id='xHQJr'><style id='xHQJr'><dir id='xHQJr'><q id='xHQJr'></q></dir></style></legend>

        • <bdo id='xHQJr'></bdo><ul id='xHQJr'></ul>

        格式化 Kivy 弹出窗口以消除弹出背景

        时间:2023-06-07

          <legend id='QwqrP'><style id='QwqrP'><dir id='QwqrP'><q id='QwqrP'></q></dir></style></legend>

                <tbody id='QwqrP'></tbody>
              <i id='QwqrP'><tr id='QwqrP'><dt id='QwqrP'><q id='QwqrP'><span id='QwqrP'><b id='QwqrP'><form id='QwqrP'><ins id='QwqrP'></ins><ul id='QwqrP'></ul><sub id='QwqrP'></sub></form><legend id='QwqrP'></legend><bdo id='QwqrP'><pre id='QwqrP'><center id='QwqrP'></center></pre></bdo></b><th id='QwqrP'></th></span></q></dt></tr></i><div id='QwqrP'><tfoot id='QwqrP'></tfoot><dl id='QwqrP'><fieldset id='QwqrP'></fieldset></dl></div>
                <bdo id='QwqrP'></bdo><ul id='QwqrP'></ul>
                <tfoot id='QwqrP'></tfoot>
              • <small id='QwqrP'></small><noframes id='QwqrP'>

                1. 本文介绍了格式化 Kivy 弹出窗口以消除弹出背景的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我们在 kivy 应用程序中使用图像作为弹出窗口,但似乎无法让弹出窗口的背景适合图像的大小.生成的弹出窗口中的图像在图像的左侧、顶部和右侧周围带有深灰色边框.有人可以帮我们消除弹出窗口的背景,以便只看到图像和半透明滤镜吗?

                  we're using an image as a popup in our kivy app but can't seem to get the popup's background to fit the size of the image. The resulting popup has the image with a dark gray border around the left side, top, and right side of the image. Can someone help us eliminate the popup's background so that only the image and the semi-transparent filter are visible?

                  Main.py 代码:

                  Main.py code:

                  popup = Popup(title="",
                                    content=Image(source='img/popup'),
                                    auto_dismiss=True,
                                    size_hint=(None, None),
                                    size=(400, 146),
                                    separator_height=0
                                    )
                  

                  谢谢

                  推荐答案

                  如果你没有标题,也许一个简单的 ModalView 会更适合你的目的.

                  If you don't have a title, maybe a simple ModalView would better fit your purposes.

                  无论哪种方式,背景都由 backgroundbackground_color 属性控制.要完全摆脱它,设置 popup.background_color=(0, 0, 0, 0) (即透明)可能是最简单的.

                  Either way, the background is controlled by the background and background_color properties. To get rid of it entirely, it's probably simplest to set popup.background_color=(0, 0, 0, 0) (i.e. transparent).

                  这篇关于格式化 Kivy 弹出窗口以消除弹出背景的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:kivy 官方 pong 教程:'NoneType' 对象没有属性 'center' 下一篇:kivy 使用附加类来存储来自多个屏幕的数据

                  相关文章

                2. <legend id='bZ4WY'><style id='bZ4WY'><dir id='bZ4WY'><q id='bZ4WY'></q></dir></style></legend>
                    <bdo id='bZ4WY'></bdo><ul id='bZ4WY'></ul>

                  <small id='bZ4WY'></small><noframes id='bZ4WY'>

                      <i id='bZ4WY'><tr id='bZ4WY'><dt id='bZ4WY'><q id='bZ4WY'><span id='bZ4WY'><b id='bZ4WY'><form id='bZ4WY'><ins id='bZ4WY'></ins><ul id='bZ4WY'></ul><sub id='bZ4WY'></sub></form><legend id='bZ4WY'></legend><bdo id='bZ4WY'><pre id='bZ4WY'><center id='bZ4WY'></center></pre></bdo></b><th id='bZ4WY'></th></span></q></dt></tr></i><div id='bZ4WY'><tfoot id='bZ4WY'></tfoot><dl id='bZ4WY'><fieldset id='bZ4WY'></fieldset></dl></div>
                    1. <tfoot id='bZ4WY'></tfoot>