def _load_browse_data(self):
self.data = self._get_current_browse_list()
self.pathLabel['text'] = "> " + self.dir_browser.get_friendly_path_name(" + ")
self.tree.delete(*self.tree.get_children())
# add data to the tree
self.tree_index = dict()
for idx in range(len(self.dataCols)):
self.tree.column(self.dataCols[idx], width=10)
for item in self.data:
index = self.tree.insert('', 'end', values=item[1:])
self.tree_index[index] = item
for idx in range(len(self.dataCols)):
iwidth = Font().measure(item[idx + 1]) + 10
if self.tree.column(self.dataCols[idx], 'width') < iwidth:
self.tree.column(self.dataCols[idx], width=iwidth)
评论列表
文章目录