python - 使用乌龟的python中的警报框
问题描述
当我使用海龟图形运行程序时,如何使警告框出现?我们有 textinput() 但它要求用户输入一些东西,但我只想在那里显示一些文本。海龟图形有可能吗?
解决方案
尝试这个:
from tkinter import *
from tkinter import messagebox
root = Tk()
messagebox.showinfo("showinfo", "Information") # The alert.
root.mainloop()
推荐阅读
- python-3.x - seaborn中的分组条形图
- javascript - 如何禁止运行小书签?
- react-native - 链接后反应本机矢量图标显示为 X
- javascript - 无法再次从区域设置存储中获取数据
- java - 使用动态投影对子实体进行 Spring JPA 分页
- c# - 确定 excel 单元格是否包含公式(VSTO:C# 或 VB)
- python - BST(二叉搜索树)元素过滤功能不断遇到“NoneType”对象
- reactjs - next-i18next 翻译整个应用和子页面
- typescript - 如何覆盖完全不同类型的包中的@types?
- python - Windows 上的詹金斯奴隶