• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

cantor/src/lib

  • sources
  • kde-4.14
  • kdeedu
  • cantor
  • src
  • lib
latexrenderer.h
Go to the documentation of this file.
1 /*
2  This program is free software; you can redistribute it and/or
3  modify it under the terms of the GNU General Public License
4  as published by the Free Software Foundation; either version 2
5  of the License, or (at your option) any later version.
6 
7  This program is distributed in the hope that it will be useful,
8  but WITHOUT ANY WARRANTY; without even the implied warranty of
9  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  GNU General Public License for more details.
11 
12  You should have received a copy of the GNU General Public License
13  along with this program; if not, write to the Free Software
14  Foundation, Inc., 51 Franklin Street, Fifth Floor,
15  Boston, MA 02110-1301, USA.
16 
17  ---
18  Copyright (C) 2011 Alexander Rieder <alexanderrieder@gmail.com>
19  */
20 
21 #ifndef _LATEXRENDERER_H
22 #define _LATEXRENDERER_H
23 
24 #include <QObject>
25 #include "cantor_export.h"
26 
27 namespace Cantor{
28 class LatexRendererPrivate;
29 
30 class CANTOR_EXPORT LatexRenderer : public QObject
31 {
32  Q_OBJECT
33  public:
34  enum Method{ LatexMethod = 0, MmlMethod = 1};
35  enum EquationType{ InlineEquation = 0, FullEquation = 1};
36  LatexRenderer( QObject* parent = 0);
37  ~LatexRenderer();
38 
39  QString latexCode() const;
40  void setLatexCode(const QString& src);
41  QString header() const;
42  void addHeader(const QString& header);
43  void setHeader(const QString& header);
44  Method method() const;
45  void setMethod( Method method);
46  void setEquationOnly(bool isEquationOnly);
47  bool isEquationOnly() const;
48  void setEquationType(EquationType type);
49  EquationType equationType() const;
50 
51  QString errorMessage() const;
52  bool renderingSuccessful() const;
53 
54  QString imagePath() const;
55 
56  Q_SIGNALS:
57  void done();
58  void error();
59 
60  public slots:
61  void render();
62 
63  void renderBlocking();
64 
65  private:
66  void setErrorMessage(const QString& msg);
67 
68  private Q_SLOTS:
69  void renderWithLatex();
70  void renderWithMml();
71  void convertToPs();
72  void convertingDone();
73 
74  private:
75  LatexRendererPrivate* d;
76 };
77 }
78 #endif /* _LATEXRENDERER_H */
CANTOR_EXPORT
#define CANTOR_EXPORT
Definition: cantor_export.h:33
QObject
Cantor::LatexRenderer
Definition: latexrenderer.h:30
QString
Cantor::LatexRenderer::Method
Method
Definition: latexrenderer.h:34
Cantor::LatexRenderer::EquationType
EquationType
Definition: latexrenderer.h:35
cantor_export.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:16:33 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

cantor/src/lib

Skip menu "cantor/src/lib"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal