PyGTK TreeColumns all exact duplicates
问题 I wrote a simple PyGTK script to show some basic process information in a TreeView: import gtk import os import pwd import grp class ProcParser: """ Parses the status file of a particular process """ def __init__(self, fname): self.lines = map(lambda x: x[:-1], open(fname).readlines()) def get_by_val(self, val): for line in self.lines: if line.startswith(val): return line.split() return [] class Proc: """ A process in the /proc filesystem This class uses a ProcParser to determine it's own