我有一个需要双零的旋转盒,就像一个时钟.无论我尝试什么,我只得到1.是否有可能让旋转框显示双零?
# all give same options: 0 - 15 - 30 - 45
Spinbox(root, from_=00, to=45, increment=15)
Spinbox(root, values=('00', '15', '30', '45'))
Run Code Online (Sandbox Code Playgroud)
完全可能!使用该format=选项.
Spinbox(root, from_=00, to=45, increment=15, format="%02.0f")
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1177 次 |
| 最近记录: |