QtiPlot
0.9.8.2
Main Page
Related Pages
Classes
Files
File List
File Members
qtiplot
src
plot2D
dialogs
EnrichmentDialog.h
Go to the documentation of this file.
1
/***************************************************************************
2
File : EnrichmentDialog.h
3
Project : QtiPlot
4
--------------------------------------------------------------------
5
Copyright : (C) 2008 by Ion Vasilief
6
Email (use @ for *) : ion_vasilief*yahoo.fr
7
Description : A general properties dialog for the FrameWidget, using article
8
"Using a Simple Web Service with Qt" in Qt Quaterly, Issue 23, Q3 2007
9
10
***************************************************************************/
11
12
/***************************************************************************
13
* *
14
* This program is free software; you can redistribute it and/or modify *
15
* it under the terms of the GNU General Public License as published by *
16
* the Free Software Foundation; either version 2 of the License, or *
17
* (at your option) any later version. *
18
* *
19
* This program is distributed in the hope that it will be useful, *
20
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
21
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
22
* GNU General Public License for more details. *
23
* *
24
* You should have received a copy of the GNU General Public License *
25
* along with this program; if not, write to the Free Software *
26
* Foundation, Inc., 51 Franklin Street, Fifth Floor, *
27
* Boston, MA 02110-1301 USA *
28
* *
29
***************************************************************************/
30
31
#ifndef TEXWIDGETDIALOG_H
32
#define TEXWIDGETDIALOG_H
33
34
#include <QDialog>
35
#include <QProcess>
36
37
class
QComboBox;
38
class
QGroupBox;
39
class
QHttp;
40
class
QLabel;
41
class
QPushButton;
42
class
QTextEdit;
43
class
QTabWidget;
44
class
QCheckBox;
45
class
QLineEdit;
46
class
QCheckBox;
47
class
QSpinBox;
48
class
QSlider;
49
class
QNetworkProxy;
50
51
class
Graph
;
52
class
FrameWidget
;
53
class
LegendWidget
;
54
class
ColorButton
;
55
class
DoubleSpinBox
;
56
class
PatternBox
;
57
class
PenStyleBox
;
58
class
RectangleWidget
;
59
class
TextFormatButtons
;
60
class
ApplicationWindow
;
61
62
class
EnrichmentDialog
:
public
QDialog
63
{
64
Q_OBJECT
65
66
public
:
67
enum
WidgetType
{
Frame
,
Text
,
Image
,
Tex
,
MDIWindow
,
Ellipse
};
68
69
EnrichmentDialog
(
WidgetType
wt,
Graph
*g,
ApplicationWindow
*app, QWidget *parent = 0);
70
~EnrichmentDialog
();
71
72
void
setWidget
(QWidget *w);
73
void
accept
(){
return
apply
();};
74
75
private
slots:
76
void
clearForm
();
77
void
fetchImage
();
78
void
updateForm
(
bool
error);
79
void
apply
();
80
void
customButtons
(QWidget *w);
81
void
chooseImageFile
(
const
QString& fn = QString::null);
82
void
displayCoordinates
(
int
unit);
83
void
adjustHeight
(
double
width);
84
void
adjustWidth
(
double
height);
85
void
saveImagesInternally
(
bool
save);
86
void
setBestSize
();
87
void
frameApplyTo
();
88
void
patternApplyTo
();
89
void
textFormatApplyTo
();
90
void
customFont
();
91
void
updateTransparency
(
int
alpha);
92
void
setTextDefaultValues
();
93
void
setFrameDefaultValues
();
94
void
setRectangleDefaultValues
();
95
void
finishedCompiling
(
int
, QProcess::ExitStatus);
96
void
displayCompileError
(QProcess::ProcessError error);
97
void
createImage
();
98
void
updateCompilerInterface
(
int
);
99
void
updateButtons
();
100
101
private
:
102
void
initTextPage
();
103
void
initEditorPage
();
104
void
initImagePage
();
105
void
initFramePage
();
106
void
initGeometryPage
();
107
void
initPatternPage
();
108
void
setCoordinates
(
int
unit);
109
void
setFrameTo
(
FrameWidget
*fw);
110
void
setPatternTo
(
FrameWidget
*r);
111
void
setTextFormatTo
(
LegendWidget
*l);
112
void
setText
(QTextEdit *editor,
const
QString & t);
113
QString
createTempTexFile
();
114
115
ApplicationWindow
*
d_app
;
116
QHttp *
http
;
117
QProcess *
compileProcess
, *
dvipngProcess
;
118
119
QLabel *
outputLabel
;
120
QPushButton *
clearButton
;
121
QPushButton *
updateButton
;
122
QPushButton *
cancelButton
;
123
QPushButton *
bestSizeButton
;
124
QTextEdit *
equationEditor
, *
textEditBox
;
125
QComboBox *
frameBox
;
126
QTabWidget*
tabWidget
;
127
QWidget *
editPage
, *
framePage
, *
geometryPage
, *
imagePage
, *
patternPage
, *
textPage
;
128
ColorButton
*
frameColorBtn
, *
backgroundColorBtn
, *
patternColorBtn
;
129
QCheckBox *
boxSaveImagesInternally
;
130
QLineEdit *
imagePathBox
;
131
DoubleSpinBox
*
xBox
, *
yBox
, *
widthBox
, *
heightBox
, *
boxFrameWidth
;
132
QComboBox *
unitBox
;
133
PenStyleBox
*
boxFrameLineStyle
;
134
QCheckBox *
keepAspectBox
, *
useFrameColorBox
;
135
QSpinBox *
boxTransparency
, *
boxTextAngle
;
136
PatternBox
*
patternBox
;
137
QPushButton *
textApplyToBtn
;
138
QComboBox *
frameApplyToBox
, *
patternApplyToBox
, *
textApplyToBox
;
139
ColorButton
*
textColorBtn
, *
textBackgroundBtn
;
140
QPushButton *
textFontBtn
;
141
QSpinBox *
boxBackgroundTransparency
;
142
QSlider *
transparencySlider
, *
fillTransparencySlider
;
143
TextFormatButtons
*
formatButtons
, *
texFormatButtons
;
144
QPushButton *
textDefaultBtn
, *
frameDefaultBtn
, *
rectangleDefaultBtn
;
145
QCheckBox *
autoUpdateTextBox
, *
texOutputBox
;
146
QComboBox *
texCompilerBox
;
147
QComboBox*
attachToBox
;
148
149
QFont
textFont
;
150
151
Graph
*
d_plot
;
152
QWidget *
d_widget
;
153
WidgetType
d_widget_type
;
154
double
aspect_ratio
;
155
};
156
157
#endif
Generated on Sat Jun 8 2013 23:27:27 for QtiPlot by
1.8.3.1