Changeset View
Changeset View
Standalone View
Standalone View
src/lib/expression.h
Show All 19 Lines | |||||
20 | 20 | | |||
21 | #ifndef _EXPRESSION_H | 21 | #ifndef _EXPRESSION_H | ||
22 | #define _EXPRESSION_H | 22 | #define _EXPRESSION_H | ||
23 | 23 | | |||
24 | #include <QObject> | 24 | #include <QObject> | ||
25 | #include <QDomElement> | 25 | #include <QDomElement> | ||
26 | 26 | | |||
27 | #include "cantor_export.h" | 27 | #include "cantor_export.h" | ||
28 | 28 | | |||
asemke: In case we really need the renderer in that function, you can use forward declaration here. | |||||
sirgienko: OK | |||||
29 | class KZip; | 29 | class KZip; | ||
30 | 30 | | |||
31 | /** | 31 | /** | ||
32 | * Namespace collecting all Classes of the Cantor Libraries | 32 | * Namespace collecting all Classes of the Cantor Libraries | ||
33 | */ | 33 | */ | ||
34 | namespace Cantor | 34 | namespace Cantor | ||
35 | { | 35 | { | ||
36 | class Session; | 36 | class Session; | ||
37 | class Result; | 37 | class Result; | ||
38 | class LatexRenderer; | ||||
38 | class ExpressionPrivate; | 39 | class ExpressionPrivate; | ||
39 | 40 | | |||
40 | /** | 41 | /** | ||
41 | * An Expression object is used, to store the information needed when running a command of a Session | 42 | * An Expression object is used, to store the information needed when running a command of a Session | ||
42 | * Evaluation of Expression is an asynchroneous process in most cases, so most of the members | 43 | * Evaluation of Expression is an asynchroneous process in most cases, so most of the members | ||
43 | * of this class are not useful directly after its construction. Therefore there are signals | 44 | * of this class are not useful directly after its construction. Therefore there are signals | ||
44 | * indicating, when the Expression goes through the different stages of the Running process. | 45 | * indicating, when the Expression goes through the different stages of the Running process. | ||
45 | * An Expression is never constructed directly, but by using Session::evaluateExpression() | 46 | * An Expression is never constructed directly, but by using Session::evaluateExpression() | ||
▲ Show 20 Lines • Show All 194 Lines • ▼ Show 20 Line(s) | 227 | protected: | |||
240 | */ | 241 | */ | ||
241 | void setStatus(Status status); | 242 | void setStatus(Status status); | ||
242 | 243 | | |||
243 | protected: | 244 | protected: | ||
244 | //returns a string of latex commands, that is inserted into the header. | 245 | //returns a string of latex commands, that is inserted into the header. | ||
245 | //used for example if special packages are needed | 246 | //used for example if special packages are needed | ||
246 | virtual QString additionalLatexHeaders(); | 247 | virtual QString additionalLatexHeaders(); | ||
247 | private: | 248 | private: | ||
248 | void renderResultAsLatex(); | 249 | void renderResultAsLatex(Result* result); | ||
249 | private Q_SLOTS: | 250 | void latexRendered(LatexRenderer* renderer, Result* result); | ||
250 | void latexRendered(); | | |||
251 | 251 | | |||
252 | private: | 252 | private: | ||
253 | ExpressionPrivate* d; | 253 | ExpressionPrivate* d; | ||
254 | }; | 254 | }; | ||
255 | 255 | | |||
256 | } | 256 | } | ||
257 | #endif /* _EXPRESSION_H */ | 257 | #endif /* _EXPRESSION_H */ |
In case we really need the renderer in that function, you can use forward declaration here.