Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
ceef7725
Commit
ceef7725
authored
3 years ago
by
Wuttke, Joachim
Browse files
Options
Downloads
Patches
Plain Diff
member class -> anon ns
parent
183ad6a7
No related branches found
No related tags found
1 merge request
!427
Reduce include dependences in GUI; break cyclic dependence between View and Model
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
GUI/View/Intensity/SavePlotAssistant.cpp
+20
-13
20 additions, 13 deletions
GUI/View/Intensity/SavePlotAssistant.cpp
GUI/View/Intensity/SavePlotAssistant.h
+0
-7
0 additions, 7 deletions
GUI/View/Intensity/SavePlotAssistant.h
with
20 additions
and
20 deletions
GUI/View/Intensity/SavePlotAssistant.cpp
+
20
−
13
View file @
ceef7725
...
@@ -29,25 +29,32 @@ const QString int_extension = ".int";
...
@@ -29,25 +29,32 @@ const QString int_extension = ".int";
const
QString
tif_extension
=
".tif"
;
const
QString
tif_extension
=
".tif"
;
const
QString
txt_extension
=
".txt"
;
const
QString
txt_extension
=
".txt"
;
const
QVector
<
SavePlotAssistant
::
Format
>
outFormats
=
{
class
Format
{
SavePlotAssistant
::
Format
(
png_extension
,
"png Image (*.png)"
),
public:
SavePlotAssistant
::
Format
(
jpg_extension
,
"jpg Image (*.jpg)"
),
Format
()
{}
SavePlotAssistant
::
Format
(
pdf_extension
,
"pdf File (*.pdf)"
),
Format
(
const
QString
&
file_extention
,
const
QString
&
filter
);
SavePlotAssistant
::
Format
(
int_extension
,
"BornAgain ASCII format (*.int)"
),
QString
m_file_extention
;
SavePlotAssistant
::
Format
(
txt_extension
,
"Simple ASCII table (*.txt)"
),
QString
m_filter
;
#ifdef BORNAGAIN_TIFF_SUPPORT
SavePlotAssistant
::
Format
(
tif_extension
,
"32-bits TIFF files (*.tif)"
),
#endif
};
};
}
// namespace
Format
::
Format
(
const
QString
&
file_extention
,
const
QString
&
filter
)
SavePlotAssistant
::
Format
::
Format
(
const
QString
&
file_extention
,
const
QString
&
filter
)
:
m_file_extention
(
file_extention
),
m_filter
(
filter
)
:
m_file_extention
(
file_extention
),
m_filter
(
filter
)
{
{
}
}
const
QVector
<
Format
>
outFormats
=
{
Format
(
png_extension
,
"png Image (*.png)"
),
Format
(
jpg_extension
,
"jpg Image (*.jpg)"
),
Format
(
pdf_extension
,
"pdf File (*.pdf)"
),
Format
(
int_extension
,
"BornAgain ASCII format (*.int)"
),
Format
(
txt_extension
,
"Simple ASCII table (*.txt)"
),
#ifdef BORNAGAIN_TIFF_SUPPORT
Format
(
tif_extension
,
"32-bits TIFF files (*.tif)"
),
#endif
};
}
// namespace
void
SavePlotAssistant
::
savePlot
(
const
QString
&
dirname
,
QCustomPlot
*
plot
,
void
SavePlotAssistant
::
savePlot
(
const
QString
&
dirname
,
QCustomPlot
*
plot
,
OutputData
<
double
>*
output_data
)
OutputData
<
double
>*
output_data
)
...
...
This diff is collapsed.
Click to expand it.
GUI/View/Intensity/SavePlotAssistant.h
+
0
−
7
View file @
ceef7725
...
@@ -26,13 +26,6 @@ template <class T> class OutputData;
...
@@ -26,13 +26,6 @@ template <class T> class OutputData;
class
SavePlotAssistant
{
class
SavePlotAssistant
{
public:
public:
class
Format
{
public:
Format
()
{}
Format
(
const
QString
&
file_extention
,
const
QString
&
filter
);
QString
m_file_extention
;
QString
m_filter
;
};
void
savePlot
(
const
QString
&
dirname
,
QCustomPlot
*
plot
,
OutputData
<
double
>*
output_data
);
void
savePlot
(
const
QString
&
dirname
,
QCustomPlot
*
plot
,
OutputData
<
double
>*
output_data
);
...
...
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