概念実証として、これにより Entry ウィジェットが作成され、それらが配列に配置されます。問題は、Windows の 3.3.1 では 26 個、Lubuntu の 3.3.1 では 28 個の Entry ウィジェットではなく、24 個しか得られないことです。なんで?どうすればこれを修正できますか?
EDIT2:問題のある部分だけにコードを簡略化http://i.imgur.com/u0OmcCI.png : http://pastebin.com/2791MFRu
from tkinter import *
class test:
def __init__(self, root):
self.variables = []
for i in range(26):
self.variables.append(StringVar())
self.frames = []
self.labels = []
self.entrys = []
for i in range(2):
self.frames.append(Frame(root))
for ii in range(26):
char = str(chr(ord('A') + ii))
if i == 0:
self.labels.append(Label(self.frames[0] , text = char))
self.labels[-1].grid(padx=0, pady=0, row=ii, column=i)
else:
self.entrys.append(Entry(self.frames[1], textvariable =self.variables[ii]))
self.entrys[-1].grid(padx=0, pady=0, row=ii, column=i)
self.frames[i].grid(row = 0,column=i)
root = Tk()
root.geometry("200x600+50+50")
T = test(root)
root.mainloop()