python - .gif 在 python 中没有响应

标签 python django python-3.x

当我运行此代码时,我得到空白屏幕。

screen=turtle.Screen()
print(screen.bgpic())
screen.setup(900, 650)
screen.bgpic("map.gif")
input()

发布下面的图片

Full code

Blank Display

最佳答案

为什么需要 input() ?你可以像这样运行,它应该显示:

import turtle

screen = turtle.Screen()
screen.setup(900, 650)
screen.bgpic("map.gif")

turtle.exitonclick()

关于python - .gif 在 python 中没有响应,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58969412/

相关文章:

python - 使用 html5 视频标签时视频无法在 safari 中播放

python - 使用函数修改数据表 UserProfile 中的值

python - 对数据框进行排序并使用百分比计算值

python - 如何将 Pandas 系列插入现有 Excel 文件的特定列(而不删除该文件中的内容)?

java - Kafka 错误连接到节点 ubuntukafka :9092 (id: 0 rack: null) (org. apache.kafka.clients.NetworkClient) java.net.UnknownHostException:

python - 创建线程评论模型 Django

python - 根据另一个数组的索引将一个数组的子元素重新定位到不同的行中?

Python - 计算有错误的趋势线

python - 关闭浏览器选项卡后保持 Jupyter Notebook 运行

python - celery (4.2): how to get task id for current task