labplot  2.8.2
About: LabPlot is an application for plotting and analysis of 2D and 3D functions and data. It is a complete rewrite of LabPlot1 and lacks in the first release a lot of features available in the predecessor. On the other hand, the GUI and the usability is more superior.
  Fossies Dox: labplot-2.8.2.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

TeXRenderer.h
Go to the documentation of this file.
1 /***************************************************************************
2  File : TeXRenderer.h
3  Project : LabPlot
4  Description : TeX renderer class
5  --------------------------------------------------------------------
6  Copyright : (C) 2008-2016 by Alexander Semke (alexander.semke@web.de)
7 
8  ***************************************************************************/
9 
10 /***************************************************************************
11  * *
12  * This program is free software; you can redistribute it and/or modify *
13  * it under the terms of the GNU General Public License as published by *
14  * the Free Software Foundation; either version 2 of the License, or *
15  * (at your option) any later version. *
16  * *
17  * This program is distributed in the hope that it will be useful, *
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
20  * GNU General Public License for more details. *
21  * *
22  * You should have received a copy of the GNU General Public License *
23  * along with this program; if not, write to the Free Software *
24  * Foundation, Inc., 51 Franklin Street, Fifth Floor, *
25  * Boston, MA 02110-1301 USA *
26  * *
27  ***************************************************************************/
28 #ifndef TEXRENDERER_H
29 #define TEXRENDERER_H
30 
31 #include <QColor>
32 
33 class QString;
34 class QImage;
35 class QTemporaryFile;
36 
37 class TeXRenderer {
38 public:
39  struct Formatting {
40  QColor fontColor;
42  int fontSize;
43  QString fontFamily;
44  int dpi;
45  };
46 
47  static QImage renderImageLaTeX(const QString&, bool* success, const TeXRenderer::Formatting&);
48  static QImage imageFromPDF(const QTemporaryFile&, const int dpi, const QString& engine, bool* success);
49  static QImage imageFromDVI(const QTemporaryFile&, const int dpi, bool* success);
50  static bool enabled();
51  static bool executableExists(const QString&);
52 };
53 
54 #endif
Implements rendering of latex code to a PNG image.
Definition: TeXRenderer.h:37
static QImage renderImageLaTeX(const QString &, bool *success, const TeXRenderer::Formatting &)
Definition: TeXRenderer.cpp:51
static QImage imageFromDVI(const QTemporaryFile &, const int dpi, bool *success)
static bool executableExists(const QString &)
static bool enabled()
static QImage imageFromPDF(const QTemporaryFile &, const int dpi, const QString &engine, bool *success)