mirror of https://github.com/m-labs/artiq.git
gui: auto resize of table columns
This commit is contained in:
parent
0b10f72c2b
commit
aa2acb9137
|
@ -23,6 +23,8 @@ class LogDock(dockarea.Dock):
|
|||
|
||||
self.log = QtGui.QTableView()
|
||||
self.log.setSelectionMode(QtGui.QAbstractItemView.NoSelection)
|
||||
self.log.horizontalHeader().setResizeMode(
|
||||
QtGui.QHeaderView.ResizeToContents)
|
||||
self.addWidget(self.log)
|
||||
|
||||
@asyncio.coroutine
|
||||
|
|
|
@ -39,6 +39,8 @@ class ParametersDock(dockarea.Dock):
|
|||
|
||||
self.table = QtGui.QTableView()
|
||||
self.table.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
|
||||
self.table.horizontalHeader().setResizeMode(
|
||||
QtGui.QHeaderView.ResizeToContents)
|
||||
grid.addWidget(self.table, 1, 0)
|
||||
|
||||
def search_parameters(self):
|
||||
|
|
|
@ -39,6 +39,8 @@ class ResultsDock(dockarea.Dock):
|
|||
|
||||
self.table = QtGui.QTableView()
|
||||
self.table.setSelectionMode(QtGui.QAbstractItemView.NoSelection)
|
||||
self.table.horizontalHeader().setResizeMode(
|
||||
QtGui.QHeaderView.ResizeToContents)
|
||||
grid.addWidget(self.table, 0, 0)
|
||||
|
||||
add_display_box = QtGui.QGroupBox("Add display")
|
||||
|
|
|
@ -54,6 +54,8 @@ class ScheduleDock(dockarea.Dock):
|
|||
self.table = QtGui.QTableView()
|
||||
self.table.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
|
||||
self.table.setSelectionMode(QtGui.QAbstractItemView.SingleSelection)
|
||||
self.table.horizontalHeader().setResizeMode(
|
||||
QtGui.QHeaderView.ResizeToContents)
|
||||
self.addWidget(self.table)
|
||||
|
||||
self.table.setContextMenuPolicy(QtCore.Qt.ActionsContextMenu)
|
||||
|
|
Loading…
Reference in New Issue