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
Jan Zelenka
prasopes
Commits
86db23e4
Commit
86db23e4
authored
Jul 24, 2019
by
Yan
Browse files
Fixed issues with printer DPI settings
parent
f2cf4c35
Changes
3
Hide whitespace changes
Inline
Side-by-side
prasopes/__main__.py
View file @
86db23e4
...
...
@@ -62,19 +62,18 @@ def load_file(parent, chrom_plot, spc, d_set, ms_s, fn, chrom_s,
def
print_graph
(
data_set
,
mass_spec
,
chrom_spec
,
spect
,
fn
):
def
printimage
(
printdevice
,
img
):
#!TODO: copy the
printer
set
tings from TSQ
printer
.
set
Resolution
(
600
)
painter
=
QtGui
.
QPainter
(
printdevice
)
painter
.
drawImage
(
QtCore
.
QPoint
(
0
,
0
),
img
)
painter
.
drawImage
(
0
,
0
,
img
)
painter
.
end
()
#TODO: substitute the QPrintPreviewDialog with QPrintPreviewWidget
printPreview
=
QtPrintSupport
.
QPrintPreviewDialog
()
printer
=
printPreview
.
printer
()
printer
.
setResolution
(
600
)
printer
.
setPageSize
(
printer
.
A5
)
printer
.
setDuplex
(
printer
.
DuplexNone
)
image
=
imgt
.
paint_image
(
mass_spec
,
spect
,
printer
)
printPreview
.
paintRequested
.
connect
(
lambda
:
printimage
(
printer
,
image
))
printimage
(
printer
,
image
))
printPreview
.
exec
()
...
...
@@ -129,7 +128,7 @@ def about(parent):
QtWidgets
.
QMessageBox
.
information
(
parent
,
"About Prasopes"
,
"Prasopes Finnigan raw file viewer
\n\n
"
"Version: 0.0.1
0
(alpha)"
)
"Version: 0.0.1
1
(alpha)"
)
def
main
():
...
...
prasopes/config.py
View file @
86db23e4
...
...
@@ -39,7 +39,7 @@ def pathlineconf(label, value, config):
browse_button
.
clicked
.
connect
(
lambda
:
pathsearch
(
textfield
,
value
,
config
))
layout
=
QtWidgets
.
QHBoxLayout
()
layout
.
addWidget
(
QtWidgets
.
QLabel
(
"{}:"
.
format
(
label
)))
layout
.
addWidget
(
QtWidgets
.
QLabel
(
str
(
label
)))
layout
.
addWidget
(
textfield
)
layout
.
addWidget
(
browse_button
)
return
layout
...
...
@@ -110,6 +110,7 @@ def dial(parent):
butt_layout
.
addStretch
(
1
)
layout
=
QtWidgets
.
QVBoxLayout
(
dialog
)
layout
.
addWidget
(
QtWidgets
.
QLabel
(
"Changes are saved automatically"
))
layout
.
addWidget
(
tabs
)
layout
.
addStretch
(
1
)
layout
.
addLayout
(
butt_layout
)
...
...
setup.py
View file @
86db23e4
...
...
@@ -5,7 +5,7 @@ with open("README.md", "r") as fh:
setup
(
name
=
"prasopes"
,
version
=
"0.0.1
0
"
,
version
=
"0.0.1
1
"
,
author
=
"Jan Zelenka"
,
author_email
=
"3yanyanyan@gmail.com"
,
description
=
"Thermo/Finnigan .raw file viewer based on rawprasslib"
,
...
...
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