diff options
| author | jvoisin | 2011-08-18 17:20:39 +0200 |
|---|---|---|
| committer | jvoisin | 2011-08-18 17:20:39 +0200 |
| commit | ed185f7e2cdb28ca10fdba28911f517a3e881504 (patch) | |
| tree | c3cf3d9948e9263c342a881279b0307c2dd74856 /mat-gui | |
| parent | 7a865af16ebbd1f0f8910f1edce27452787149b8 (diff) | |
Column are now resizable
Diffstat (limited to 'mat-gui')
| -rwxr-xr-x | mat-gui | 7 |
1 files changed, 4 insertions, 3 deletions
| @@ -68,7 +68,7 @@ class GUI: | |||
| 68 | self.liststore = gtk.ListStore(object, str, str, str) | 68 | self.liststore = gtk.ListStore(object, str, str, str) |
| 69 | 69 | ||
| 70 | treeview = gtk.TreeView(model=self.liststore) | 70 | treeview = gtk.TreeView(model=self.liststore) |
| 71 | treeview.set_search_column(1) # name column is searchable | 71 | treeview.set_search_column(1) # the filename column is searchable |
| 72 | treeview.set_rules_hint(True) # alternate colors for rows | 72 | treeview.set_rules_hint(True) # alternate colors for rows |
| 73 | treeview.set_rubber_banding(True) # mouse selection | 73 | treeview.set_rubber_banding(True) # mouse selection |
| 74 | self.add_columns(treeview) | 74 | self.add_columns(treeview) |
| @@ -133,7 +133,8 @@ data loss')) | |||
| 133 | filename_column = gtk.CellRendererText() | 133 | filename_column = gtk.CellRendererText() |
| 134 | column = gtk.TreeViewColumn(j, filename_column, text=i + 1) | 134 | column = gtk.TreeViewColumn(j, filename_column, text=i + 1) |
| 135 | column.set_sort_column_id(i + 1) | 135 | column.set_sort_column_id(i + 1) |
| 136 | if i is 0: # place tooltip on this column | 136 | column.set_resizable(True) # column is resizeable |
| 137 | if i is 0: # place cell-specific tooltip on this column | ||
| 137 | tips = TreeViewTooltips(column) | 138 | tips = TreeViewTooltips(column) |
| 138 | tips.add_view(treeview) | 139 | tips.add_view(treeview) |
| 139 | treeview.append_column(column) | 140 | treeview.append_column(column) |
| @@ -356,7 +357,7 @@ cleaning')) | |||
| 356 | add2archive.set_active(self.add2archive) | 357 | add2archive.set_active(self.add2archive) |
| 357 | add2archive.connect('toggled', self.invert, 'add2archive') | 358 | add2archive.connect('toggled', self.invert, 'add2archive') |
| 358 | add2archive.set_tooltip_text(_('Add non-supported (and so \ | 359 | add2archive.set_tooltip_text(_('Add non-supported (and so \ |
| 359 | non-anonymised) file to outputed archive')) | 360 | non-anonymised) file to output archive')) |
| 360 | table.attach(add2archive, 0, 1, 2, 3) | 361 | table.attach(add2archive, 0, 1, 2, 3) |
| 361 | 362 | ||
| 362 | hbox.show_all() | 363 | hbox.show_all() |
