Engauge Digitizer
2
Loading...
Searching...
No Matches
Export
ExportImageForRegression.cpp
Go to the documentation of this file.
1
/******************************************************************************************************
2
* (C) 2014 markummitchell@github.com. This file is part of Engauge Digitizer, which is released *
3
* under GNU General Public License version 2 (GPLv2) or (at your option) any later version. See file *
4
* LICENSE or go to gnu.org/licenses for details. Distribution requires prior written permission. *
5
******************************************************************************************************/
6
7
#include "
ExportImageForRegression.h
"
8
#include <QFile>
9
#include <QMessageBox>
10
#include <QObject>
11
#include <QPixmap>
12
#include <QString>
13
#include <QTextStream>
14
15
ExportImageForRegression::ExportImageForRegression
(
const
QPixmap
&pixmap) :
16
m_width (pixmap.width ()),
17
m_height (pixmap.
height
())
18
{
19
}
20
21
void
ExportImageForRegression::fileExport
(
const
QString
&
filename
)
const
22
{
23
QFile
file
(
filename
);
24
if
(!
file
.open (QIODevice::WriteOnly)) {
25
QMessageBox::critical (
nullptr
,
26
QObject::tr (
"Export Image"
),
27
QObject::tr (
"Cannot export file"
));
28
}
else
{
29
30
QTextStream
str
(&
file
);
31
32
str
<< m_width <<
"x"
<< m_height <<
"\n"
;
33
34
file
.close ();
35
}
36
}
INNER_RADIUS_MIN
const int INNER_RADIUS_MIN
Definition
DlgSettingsDigitizeCurve.cpp:35
ExportImageForRegression.h
ExportImageForRegression::fileExport
void fileExport(const QString &filename) const
Export to the specified file. This is called when the Transformation has not been defined.
Definition
ExportImageForRegression.cpp:21
ExportImageForRegression::ExportImageForRegression
ExportImageForRegression(const QPixmap &pixmap)
Single constructor.
Definition
ExportImageForRegression.cpp:15
Generated on Wed Aug 3 2022 00:00:00 for Engauge Digitizer by
1.10.0