回答編集履歴
1
Fixed.
test
CHANGED
@@ -32,7 +32,7 @@
|
|
32
32
|
|
33
33
|
|
34
34
|
|
35
|
-
columns =
|
35
|
+
columns = 10
|
36
36
|
|
37
37
|
data = []
|
38
38
|
|
@@ -40,7 +40,7 @@
|
|
40
40
|
|
41
41
|
data.append([i, i+1, i+2, i+3, i+4])
|
42
42
|
|
43
|
-
self.tree = ttk.Treeview(self.win, selectmode
|
43
|
+
self.tree = ttk.Treeview(self.win, selectmode='browse')
|
44
44
|
|
45
45
|
self.tree.grid(row=0, column=0, rowspan=2, columnspan=2, sticky="nsew", padx=5, pady=5)
|
46
46
|
|
@@ -68,27 +68,17 @@
|
|
68
68
|
|
69
69
|
command=self.tree.yview)
|
70
70
|
|
71
|
-
self.verscrlbar.grid(row=0, column=2, sticky="nsew")
|
71
|
+
self.verscrlbar.grid(row=0, column=2,rowspan=2, sticky="nsew")
|
72
72
|
|
73
|
-
self.
|
73
|
+
self.hozscrlbar = ttk.Scrollbar(self.win,
|
74
74
|
|
75
|
+
orient="horizontal",
|
75
76
|
|
77
|
+
command=self.tree.xview)
|
76
78
|
|
77
|
-
|
79
|
+
self.hozscrlbar.grid(row=2, column=0, sticky="nsew")
|
78
80
|
|
79
|
-
# self.button1.grid(row=0, column=2, sticky="nsew")
|
80
|
-
|
81
|
-
|
81
|
+
self.tree.configure(yscrollcommand=self.verscrlbar.set, xscrollcommand=self.hozscrlbar.set)
|
82
|
-
|
83
|
-
# self.button2.grid(row=1, column=2, sticky="nsew")
|
84
|
-
|
85
|
-
# self.button3 = tk.Button(self.win, text="◀", command=self.push_button3)
|
86
|
-
|
87
|
-
# self.button3.grid(row=2, column=0, sticky="nsew")
|
88
|
-
|
89
|
-
# self.button4 = tk.Button(self.win, text="▶", command=self.push_button4)
|
90
|
-
|
91
|
-
# self.button4.grid(row=2, column=1, sticky="nsew")
|
92
82
|
|
93
83
|
|
94
84
|
|