This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients patrickmelix, serhiy.storchaka
Date 2021-03-29.09:48:53
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1617011333.2.0.838324458881.issue43655@roundup.psfhosted.org>
In-reply-to
Content
Thank you for your report and PR Patrick.

I agree, it would be better to to set the "type" attribute to "dialog" for the FileDialog window. Tk does it for its dialog windows. But it is more complex.

* It should be set not only for FileDialog, but for other dialog windows implemented in Python too (including dialog windows specific for IDLE). I am in process of working on making dialog windows implemented in Python looking and behaving closer to dialog windows implemented in Tk. The hardest part is writing tests for this.

* This code should be executed only on X Window. On macOS and Windows different code is needed. From Tk sources of ::tk::dialog::file::Create and ::tk::dialog::color:: :

    if {[tk windowingsystem] eq "x11"} {wm attributes $w -type dialog}

And in ::tk_dialog and ::tk::MessageBox :

    if {$windowingsystem eq "aqua"} {
        ::tk::unsupported::MacWindowStyle style $w moveableModal {}
    } elseif {$windowingsystem eq "x11"} {
        wm attributes $w -type dialog
    }

And ::tk::dialog::error::bgerror uses moveableAlert instead of moveableModal.
History
Date User Action Args
2021-03-29 09:48:53serhiy.storchakasetrecipients: + serhiy.storchaka, patrickmelix
2021-03-29 09:48:53serhiy.storchakasetmessageid: <1617011333.2.0.838324458881.issue43655@roundup.psfhosted.org>
2021-03-29 09:48:53serhiy.storchakalinkissue43655 messages
2021-03-29 09:48:53serhiy.storchakacreate