我正在使用tkinter / ttk在python中编写警报GUI。对于本节,我的代码看起来像
self.checkFrame = ttk.Frame(self.alarm1)
self.checkFrame.grid(row = 1)
self.mon = ttk.Checkbutton(self.checkFrame, text = 'MON')
self.mon.grid(column = 0, row = 0)
self.tue = ttk.Checkbutton(self.checkFrame, text = 'TUE')
self.tue.grid(column = 1, row = 0)
self.wed = ttk.Checkbutton(self.checkFrame, text = 'WED')
self.wed.grid(column = 2, row = 0)
self.thur = ttk.Checkbutton(self.checkFrame, text = 'THUR')
self.thur.grid(column = 3, row = 0)
self.fri = ttk.Checkbutton(self.checkFrame, text = 'FRI')
self.fri.grid(column = 4, row = 0)
self.sat = ttk.Checkbutton(self.checkFrame, text = 'SAT')
self.sat.grid(column = 5, row = 0)
self.sun = ttk.Checkbutton(self.checkFrame, text = 'SUN')
self.sun.grid(column = 6, row = 0)
除了文本显示在按钮右侧之外,一切看起来都很好。我想知道是否有可以将这些文本移到按钮下方。