问题描述
我最近在用 Tkinter 写 GUI,如果给 Label 组件指定长度的话,应该怎样让里面的文本左对齐呢?
代码(希望提一下建议)
import tkinter as tk
wd_main = tk.Tk()
# wd_main.geometry("600x300")
lb1 = tk.Label(wd_main, text = "Once upon a time a girl...",
relief = "groove", width = 60).pack(side = "left")
# lb2 = tk.Label(wd_main, text = "test2kasjfkd",
# relief = "groove").pack(side = "left", anchor = "nw")
wd_main.mainloop()