【发布时间】:2017-12-17 13:52:02
【问题描述】:
我尝试使用文本中带有“x”变量的文本制作标签。我的问题是标签有大括号。这是我的代码示例。如何删除它们?
victory_screen=Label(root,compound=CENTER, text=("PLAYER 1 WINS with
",x,"points""\n""\n""\n""\n""\n""\n"))
【问题讨论】:
-
您必须使用连接创建一个字符串。或使用string formatting: PyFormat.info
标签: python-3.x tkinter label