57 self.exceptionsTable.verticalHeader().setMinimumSectionSize(-1) |
57 self.exceptionsTable.verticalHeader().setMinimumSectionSize(-1) |
58 for section in range(self.__exceptionsModel.columnCount()): |
58 for section in range(self.__exceptionsModel.columnCount()): |
59 header = self.exceptionsTable.horizontalHeader().sectionSizeHint( |
59 header = self.exceptionsTable.horizontalHeader().sectionSizeHint( |
60 section) |
60 section) |
61 if section == 0: |
61 if section == 0: |
62 header = fm.width("averagebiglonghost.averagedomain.info") |
62 try: |
|
63 header = fm.horizontalAdvance( |
|
64 "averagebiglonghost.averagedomain.info") |
|
65 except AttributeError: |
|
66 header = fm.width( |
|
67 "averagebiglonghost.averagedomain.info") |
63 elif section == 1: |
68 elif section == 1: |
64 header = fm.width(self.tr("Allow For Session")) |
69 try: |
65 buffer = fm.width("mm") |
70 header = fm.horizontalAdvance(self.tr("Allow For Session")) |
|
71 except AttributeError: |
|
72 header = fm.width(self.tr("Allow For Session")) |
|
73 try: |
|
74 buffer = fm.horizontalAdvance("mm") |
|
75 except AttributeError: |
|
76 buffer = fm.width("mm") |
66 header += buffer |
77 header += buffer |
67 self.exceptionsTable.horizontalHeader().resizeSection( |
78 self.exceptionsTable.horizontalHeader().resizeSection( |
68 section, header) |
79 section, header) |
69 |
80 |
70 def setDomainName(self, domain): |
81 def setDomainName(self, domain): |