久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

  • <small id='i2Ra9'></small><noframes id='i2Ra9'>

      <i id='i2Ra9'><tr id='i2Ra9'><dt id='i2Ra9'><q id='i2Ra9'><span id='i2Ra9'><b id='i2Ra9'><form id='i2Ra9'><ins id='i2Ra9'></ins><ul id='i2Ra9'></ul><sub id='i2Ra9'></sub></form><legend id='i2Ra9'></legend><bdo id='i2Ra9'><pre id='i2Ra9'><center id='i2Ra9'></center></pre></bdo></b><th id='i2Ra9'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='i2Ra9'><tfoot id='i2Ra9'></tfoot><dl id='i2Ra9'><fieldset id='i2Ra9'></fieldset></dl></div>

        <bdo id='i2Ra9'></bdo><ul id='i2Ra9'></ul>
    1. <tfoot id='i2Ra9'></tfoot>
    2. <legend id='i2Ra9'><style id='i2Ra9'><dir id='i2Ra9'><q id='i2Ra9'></q></dir></style></legend>

      1. 如何在 tkinter 中創(chuàng)建模態(tài)對話框?

        How to create a modal dialog in tkinter?(如何在 tkinter 中創(chuàng)建模態(tài)對話框?)
        <tfoot id='uKijK'></tfoot>
      2. <i id='uKijK'><tr id='uKijK'><dt id='uKijK'><q id='uKijK'><span id='uKijK'><b id='uKijK'><form id='uKijK'><ins id='uKijK'></ins><ul id='uKijK'></ul><sub id='uKijK'></sub></form><legend id='uKijK'></legend><bdo id='uKijK'><pre id='uKijK'><center id='uKijK'></center></pre></bdo></b><th id='uKijK'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='uKijK'><tfoot id='uKijK'></tfoot><dl id='uKijK'><fieldset id='uKijK'></fieldset></dl></div>

              <tbody id='uKijK'></tbody>

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

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

                  <bdo id='uKijK'></bdo><ul id='uKijK'></ul>
                • 本文介紹了如何在 tkinter 中創(chuàng)建模態(tài)對話框?的處理方法,對大家解決問題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

                  問題描述

                  我有一個(gè) MFC 應(yīng)用程序,它運(yùn)行一些嵌入式 Python 腳本.我正在嘗試制作這個(gè)嵌入式腳本創(chuàng)建的對話框之一,但我沒有取得太大的成功.

                  I have a MFC application which runs some embedded Python scripts. I am trying to make one of the dialogs this embedded script creates modal, but I am not having much success.

                  誰能指點(diǎn)我制作模態(tài)對話框的方法?我需要為此使用 Windows 函數(shù)還是僅使用 Tk 或 Python 函數(shù)就足夠了?

                  Can anyone point me the way to make a modal dialog? Do I need to use a windows functions for this or only Tk or Python functions are enough?

                  對于我在 google 上搜索的內(nèi)容,以下函數(shù)組合應(yīng)該可以發(fā)揮作用,但它們似乎并沒有像我預(yù)期的那樣工作:

                  For what I googled looks like the following combination of functions should do the magic, but they dont seem to work the way I was expecting:

                  focus_set()
                  
                  grab_set()
                  
                  transient(parent)
                  

                  推薦答案

                  grab_set 是使窗口應(yīng)用程序模式"的正確機(jī)制.也就是說,它接受來自同一應(yīng)用程序中所有其他窗口的所有輸入(即:同一進(jìn)程中的其他 Tkinter 窗口),但它允許您與其他應(yīng)用程序進(jìn)行交互.

                  grab_set is the proper mechanism for making a window "application modal". That is, it takes all input from all other windows in the same application (ie: other Tkinter windows in the same process), but it allows you to interact with other applications.

                  如果您希望對話框全局模態(tài),請使用 grab_set_global.這將接管整個(gè)系統(tǒng)的所有鍵盤和鼠標(biāo)輸入.使用此功能時(shí)必須非常小心,因?yàn)槿绻龅阶柚箲?yīng)用釋放抓取的錯(cuò)誤,您可以輕松地將自己鎖定在計(jì)算機(jī)之外.

                  If you want your dialog to be globally modal, use grab_set_global. This will take over all keyboard and mouse input for the entire system. You must be extremely careful when using this because you can easily lock yourself out of your computer if you have have a bug that prevents your app from releasing the grab.

                  當(dāng)我需要這樣做時(shí),在開發(fā)過程中,我會嘗試編寫一個(gè)防彈故障保險(xiǎn),例如一個(gè)在固定時(shí)間后釋放抓斗的計(jì)時(shí)器.

                  When I have the need to do this, during development I'll try to write a bulletproof failsafe such as a timer that will release the grab after a fixed amount of time.

                  這篇關(guān)于如何在 tkinter 中創(chuàng)建模態(tài)對話框?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Recursive file search using C++ MFC?(使用 C++ MFC 進(jìn)行遞歸文件搜索?)
                  Windows 7: how to bring a window to the front no matter what other window has focus?(Windows 7:無論其他窗口有焦點(diǎn),如何將窗口置于最前面?)
                  Which Font is the default for MFC Dialog Controls?(哪種字體是 MFC 對話框控件的默認(rèn)字體?)
                  How to create a resizable CDialog in MFC?(如何在 MFC 中創(chuàng)建可調(diào)整大小的 CDialog?)
                  Windows Media Foundation recording audio(Windows Media Foundation 錄制音頻)
                  How can I enumerate/list all installed applications in Windows XP?(如何枚舉/列出 Windows XP 中所有已安裝的應(yīng)用程序?)
                  • <bdo id='aI3FA'></bdo><ul id='aI3FA'></ul>
                      <tbody id='aI3FA'></tbody>
                      <legend id='aI3FA'><style id='aI3FA'><dir id='aI3FA'><q id='aI3FA'></q></dir></style></legend>

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

                      <i id='aI3FA'><tr id='aI3FA'><dt id='aI3FA'><q id='aI3FA'><span id='aI3FA'><b id='aI3FA'><form id='aI3FA'><ins id='aI3FA'></ins><ul id='aI3FA'></ul><sub id='aI3FA'></sub></form><legend id='aI3FA'></legend><bdo id='aI3FA'><pre id='aI3FA'><center id='aI3FA'></center></pre></bdo></b><th id='aI3FA'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='aI3FA'><tfoot id='aI3FA'></tfoot><dl id='aI3FA'><fieldset id='aI3FA'></fieldset></dl></div>

                        1. <tfoot id='aI3FA'></tfoot>

                            主站蜘蛛池模板: 国产a一区二区 | 一级黄a视频 | 精品日韩在线 | 欧美一区二区精品 | av一级在线观看 | 国产精品久久久乱弄 | 精品一区二区三区四区 | 在线视频国产一区 | 免费一区二区三区 | 不卡视频在线 | 日本久久黄色 | 亚洲一区久久 | 午夜精品一区二区三区免费视频 | 天天综合网91 | 日韩视频国产 | 欧美精品一区三区 | 亚洲一区二区免费 | 欧美在线国产精品 | 久久亚洲一区 | 成人午夜高清 | 蜜桃在线播放 | 国产在线观看一区二区 | 精品欧美久久 | 毛片免费看 | 欧美一区二区免费视频 | 国产精品久久久久久久久久免费看 | 黄色大片网 | 日韩三区在线 | 日韩欧美精品 | 久草影视在线 | 国产高清在线精品一区二区三区 | 国产一区视频在线 | 精品久久一区 | 中文字幕 国产精品 | 日韩视频一级 | 免费成人在线网站 | 9久9久9久女女女九九九一九 | 精品久久精品 | 午夜影院在线观看 | 国产精品精品 | 国产精品毛片一区二区在线看 |