Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
XRD
darfix
Commits
dcaaef0c
Commit
dcaaef0c
authored
Jul 16, 2021
by
Julia Garriga Ferrer
Browse files
[gui][magnification] Add setter and getter properties for magnification value
parent
21b79202
Changes
1
Hide whitespace changes
Inline
Side-by-side
darfix/gui/magnificationWidget.py
View file @
dcaaef0c
...
...
@@ -101,6 +101,24 @@ class MagnificationWidget(qt.QMainWindow):
else
:
self
.
_okButton
.
setEnabled
(
True
)
@
property
def
magnification
(
self
):
return
self
.
_magnification
@
magnification
.
setter
def
magnification
(
self
,
magnification
):
self
.
_magnification
=
magnification
if
self
.
magnification
==
Value
.
PIXEL_2X
.
value
:
self
.
_check2x
(
True
)
self
.
_checkbox2x
.
setChecked
(
True
)
elif
self
.
magnification
==
Value
.
PIXEL_10X
.
value
:
self
.
_checkbox10x
.
setChecked
(
True
)
self
.
_check10x
(
True
)
else
:
self
.
_manualLE
.
setText
(
str
(
self
.
_magnification
))
self
.
_checkManual
(
True
)
self
.
_checkboxManual
.
setChecked
(
True
)
def
getDataset
(
self
):
return
self
.
dataset
,
self
.
indices
,
self
.
bg_indices
,
self
.
bg_dataset
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment