Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
mantid
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mantidproject
mantid
Commits
2a1f549c
Commit
2a1f549c
authored
6 years ago
by
Dimitar Tasev
Browse files
Options
Downloads
Patches
Plain Diff
Columns in MatrixWorkspaceDisplay are now adjustable, re #24388
parent
211af830
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
qt/python/mantidqt/widgets/matrixworkspacedisplay/view.py
+18
-2
18 additions, 2 deletions
qt/python/mantidqt/widgets/matrixworkspacedisplay/view.py
with
18 additions
and
2 deletions
qt/python/mantidqt/widgets/matrixworkspacedisplay/view.py
+
18
−
2
View file @
2a1f549c
...
@@ -20,6 +20,22 @@ import mantidqt.icons
...
@@ -20,6 +20,22 @@ import mantidqt.icons
from
mantidqt.widgets.matrixworkspacedisplay.table_view_model
import
MatrixWorkspaceTableViewModelType
from
mantidqt.widgets.matrixworkspacedisplay.table_view_model
import
MatrixWorkspaceTableViewModelType
class
MatrixWorkspaceTableView
(
QTableView
):
def
__init__
(
self
,
parent
):
super
(
MatrixWorkspaceTableView
,
self
).
__init__
(
parent
)
self
.
setSelectionBehavior
(
QAbstractItemView
.
SelectItems
)
header
=
self
.
horizontalHeader
()
header
.
sectionDoubleClicked
.
connect
(
self
.
handle_double_click
)
def
resizeEvent
(
self
,
event
):
header
=
self
.
horizontalHeader
()
header
.
setSectionResizeMode
(
QHeaderView
.
Interactive
)
def
handle_double_click
(
self
,
section
):
header
=
self
.
horizontalHeader
()
header
.
resizeSection
(
section
,
header
.
defaultSectionSize
())
class
MatrixWorkspaceDisplayView
(
QTabWidget
):
class
MatrixWorkspaceDisplayView
(
QTabWidget
):
def
__init__
(
self
,
presenter
,
parent
=
None
,
name
=
''
):
def
__init__
(
self
,
presenter
,
parent
=
None
,
name
=
''
):
super
(
MatrixWorkspaceDisplayView
,
self
).
__init__
(
parent
)
super
(
MatrixWorkspaceDisplayView
,
self
).
__init__
(
parent
)
...
@@ -51,8 +67,8 @@ class MatrixWorkspaceDisplayView(QTabWidget):
...
@@ -51,8 +67,8 @@ class MatrixWorkspaceDisplayView(QTabWidget):
self
.
show
()
self
.
show
()
def
add_table
(
self
,
label
):
def
add_table
(
self
,
label
):
tab
=
Q
TableView
()
tab
=
MatrixWorkspace
TableView
(
self
)
tab
.
setSelectionBehavior
(
QAbstractItemView
.
SelectItems
)
self
.
addTab
(
tab
,
label
)
self
.
addTab
(
tab
,
label
)
self
.
tabs
.
append
(
tab
)
self
.
tabs
.
append
(
tab
)
return
tab
return
tab
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment