Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
CFA Analysis
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository 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
JOSSOUD Olivier
CFA Analysis
Commits
44416483
Commit
44416483
authored
4 years ago
by
JOSSOUD Olivier
Browse files
Options
Downloads
Patches
Plain Diff
PicarroCalib. Fix Table size to avoid font/column/row going outside the widget.
Solves (?) issue
#7
.
parent
8ccfc79a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
pyqt/mainwindow.ui
+18
-0
18 additions, 0 deletions
pyqt/mainwindow.ui
src/gui/uimainwindow.py
+9
-0
9 additions, 0 deletions
src/gui/uimainwindow.py
src/uim/picarrocalibuim.py
+15
-0
15 additions, 0 deletions
src/uim/picarrocalibuim.py
with
42 additions
and
0 deletions
pyqt/mainwindow.ui
+
18
−
0
View file @
44416483
...
...
@@ -710,6 +710,24 @@
<height>
121
</height>
</rect>
</property>
<property
name=
"sizePolicy"
>
<sizepolicy
hsizetype=
"Expanding"
vsizetype=
"Expanding"
>
<horstretch>
0
</horstretch>
<verstretch>
0
</verstretch>
</sizepolicy>
</property>
<property
name=
"verticalScrollBarPolicy"
>
<enum>
Qt::ScrollBarAlwaysOff
</enum>
</property>
<property
name=
"horizontalScrollBarPolicy"
>
<enum>
Qt::ScrollBarAlwaysOff
</enum>
</property>
<property
name=
"sizeAdjustPolicy"
>
<enum>
QAbstractScrollArea::AdjustToContents
</enum>
</property>
<property
name=
"verticalScrollMode"
>
<enum>
QAbstractItemView::ScrollPerPixel
</enum>
</property>
<row>
<property
name=
"text"
>
<string>
H2O
</string>
...
...
This diff is collapsed.
Click to expand it.
src/gui/uimainwindow.py
+
9
−
0
View file @
44416483
...
...
@@ -270,6 +270,15 @@ class Ui_MainWindow(object):
self
.
gridLayout
.
addWidget
(
self
.
picarro_label_plateau_duration
,
0
,
0
,
1
,
1
)
self
.
picarro_tablewidget
=
QtWidgets
.
QTableWidget
(
self
.
groupBox
)
self
.
picarro_tablewidget
.
setGeometry
(
QtCore
.
QRect
(
10
,
100
,
251
,
121
))
sizePolicy
=
QtWidgets
.
QSizePolicy
(
QtWidgets
.
QSizePolicy
.
Expanding
,
QtWidgets
.
QSizePolicy
.
Expanding
)
sizePolicy
.
setHorizontalStretch
(
0
)
sizePolicy
.
setVerticalStretch
(
0
)
sizePolicy
.
setHeightForWidth
(
self
.
picarro_tablewidget
.
sizePolicy
().
hasHeightForWidth
())
self
.
picarro_tablewidget
.
setSizePolicy
(
sizePolicy
)
self
.
picarro_tablewidget
.
setVerticalScrollBarPolicy
(
QtCore
.
Qt
.
ScrollBarAlwaysOff
)
self
.
picarro_tablewidget
.
setHorizontalScrollBarPolicy
(
QtCore
.
Qt
.
ScrollBarAlwaysOff
)
self
.
picarro_tablewidget
.
setSizeAdjustPolicy
(
QtWidgets
.
QAbstractScrollArea
.
AdjustToContents
)
self
.
picarro_tablewidget
.
setVerticalScrollMode
(
QtWidgets
.
QAbstractItemView
.
ScrollPerPixel
)
self
.
picarro_tablewidget
.
setObjectName
(
"
picarro_tablewidget
"
)
self
.
picarro_tablewidget
.
setColumnCount
(
2
)
self
.
picarro_tablewidget
.
setRowCount
(
3
)
...
...
This diff is collapsed.
Click to expand it.
src/uim/picarrocalibuim.py
+
15
−
0
View file @
44416483
...
...
@@ -24,6 +24,7 @@ class PicarroCalibUim:
self
.
config
=
config
self
.
main_ui
.
picarro_pushbutton_dataset_load
.
clicked
.
connect
(
self
.
__load_dataset__
)
self
.
__init_tablewidget_dimensions__
()
# Injection's properties
self
.
injection_prop_dict
=
dict
()
...
...
@@ -54,6 +55,20 @@ class PicarroCalibUim:
def
__update_current_dataset__
(
self
,
dataset
:
DatasetReader
):
self
.
__create_plot__
()
def
__init_tablewidget_dimensions__
(
self
):
table
=
self
.
main_ui
.
picarro_tablewidget
table
.
verticalHeader
().
setStyleSheet
(
"
QHeaderView { font-size: 10pt; }
"
)
table
.
horizontalHeader
().
setStyleSheet
(
"
QHeaderView { font-size: 10pt; }
"
)
table
.
verticalHeader
().
setFixedWidth
(
50
)
# Width of the Row header
table
.
setColumnWidth
(
0
,
99
)
table
.
setColumnWidth
(
1
,
98
)
table
.
horizontalHeader
().
setFixedHeight
(
24
)
# Height of the Column header
table
.
setRowHeight
(
0
,
32
)
table
.
setRowHeight
(
1
,
32
)
table
.
setRowHeight
(
2
,
32
)
####################################################################
# Standard "true" value file management
...
...
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