mirror of
https://invent.kde.org/graphics/okular
synced 2024-10-02 14:14:10 +00:00
Sync QDVI and KDVI header files as much as possible.
#include <config.h> in all .cpp files. svn path=/trunk/KDE/kdegraphics/kviewshell/plugins/dvi/; revision=470366
This commit is contained in:
parent
8533a28e9b
commit
d175df8ace
|
@ -1,3 +1,4 @@
|
|||
#include <config.h>
|
||||
|
||||
#include "glyph.h"
|
||||
#include "TeXFont.h"
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
#ifndef _TEXFONT_H
|
||||
#define _TEXFONT_H
|
||||
|
||||
#include "TeXFontDefinition.h"
|
||||
#include "glyph.h"
|
||||
#include "TeXFontDefinition.h"
|
||||
|
||||
|
||||
class TeXFont {
|
||||
|
|
|
@ -15,12 +15,10 @@
|
|||
#ifndef _FONT_H
|
||||
#define _FONT_H
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <Q3IntDict>
|
||||
#include <QString>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <cstdio>
|
||||
|
||||
class dviRenderer;
|
||||
class TeXFont;
|
||||
|
|
|
@ -10,6 +10,8 @@
|
|||
|
||||
// Add header files alphabetically
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
#include <qimage.h>
|
||||
|
|
|
@ -9,9 +9,6 @@
|
|||
// This file is compiled only if the FreeType library is present on
|
||||
// the system
|
||||
|
||||
#include "config.h"
|
||||
#ifdef HAVE_FREETYPE
|
||||
|
||||
#ifndef _TEXFONT_PFB_H
|
||||
#define _TEXFONT_PFB_H
|
||||
|
||||
|
@ -42,4 +39,3 @@ class TeXFont_PFB : public TeXFont {
|
|||
};
|
||||
|
||||
#endif
|
||||
#endif // HAVE_FREETYPE
|
||||
|
|
|
@ -49,6 +49,8 @@
|
|||
* and Luis Miguel Silveira, MIT RLE.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
#include <math.h>
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
|
||||
// Add header files alphabetically
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
#include <qdatastream.h>
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
// (C) 2003 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
|
||||
|
|
|
@ -49,6 +49,7 @@
|
|||
* and Luis Miguel Silveira, MIT RLE.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
|
|
|
@ -16,8 +16,8 @@
|
|||
#include <Q3IntDict>
|
||||
#include <Q3MemArray>
|
||||
#include <QIODevice>
|
||||
#include <QMap>
|
||||
#include <QString>
|
||||
#include <qmap.h>
|
||||
|
||||
class fontPool;
|
||||
class pageSize;
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
|
||||
#include "dviPageCache.h"
|
||||
|
|
|
@ -8,6 +8,8 @@
|
|||
// Distributed under the GPL
|
||||
//
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
|
|
@ -51,6 +51,8 @@
|
|||
|
||||
//#define DEBUG_RENDER 0
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include "dviRenderer.h"
|
||||
#include "dvi.h"
|
||||
#include "dviFile.h"
|
||||
|
@ -78,7 +80,6 @@
|
|||
|
||||
extern QPainter *foreGroundPainter;
|
||||
|
||||
|
||||
/** Routine to print characters. */
|
||||
|
||||
void dviRenderer::set_char(unsigned int cmd, unsigned int ch)
|
||||
|
|
|
@ -25,6 +25,8 @@
|
|||
// of kdvi.
|
||||
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kapplication.h>
|
||||
#include <kmessagebox.h>
|
||||
#include <kdebug.h>
|
||||
|
|
|
@ -5,6 +5,8 @@
|
|||
// (C) 2003--2004 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include "dviRenderer.h"
|
||||
#include "dvi.h"
|
||||
#include "dviFile.h"
|
||||
|
|
|
@ -8,6 +8,8 @@
|
|||
// Distributed under the GPL
|
||||
//
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
|
||||
|
|
|
@ -6,6 +6,8 @@
|
|||
// Copyright: See COPYING file that comes with this distribution
|
||||
//
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <qdir.h>
|
||||
#include <kdebug.h>
|
||||
|
||||
|
|
|
@ -6,10 +6,6 @@
|
|||
// (C) 2003 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include "config.h"
|
||||
#ifdef HAVE_FREETYPE
|
||||
|
||||
|
||||
#ifndef _FONTENCODING_H
|
||||
#define _FONTENCODING_H
|
||||
|
||||
|
@ -88,4 +84,3 @@ class fontEncoding {
|
|||
};
|
||||
|
||||
#endif
|
||||
#endif // HAVE_FREETYPE
|
||||
|
|
|
@ -6,9 +6,6 @@
|
|||
// (C) 2003 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include "config.h"
|
||||
#ifdef HAVE_FREETYPE
|
||||
|
||||
#ifndef _FONTENCODINGPOOL_H
|
||||
#define _FONTENCODINGPOOL_H
|
||||
|
||||
|
@ -30,4 +27,3 @@ class fontEncodingPool {
|
|||
};
|
||||
|
||||
#endif
|
||||
#endif // HAVE_FREETYPE
|
||||
|
|
|
@ -9,9 +9,6 @@
|
|||
#ifndef _FONTMAP_H
|
||||
#define _FONTMAP_H
|
||||
|
||||
#include "config.h"
|
||||
#ifdef HAVE_FREETYPE
|
||||
|
||||
#include <QMap>
|
||||
#include <QString>
|
||||
|
||||
|
@ -118,5 +115,4 @@ class fontMap {
|
|||
QMap<QString, fontMapEntry> fontMapEntries;
|
||||
};
|
||||
|
||||
#endif // ifdef HAVE_FREETYPE
|
||||
#endif // ifndef _FONTMAP_H
|
||||
|
|
|
@ -4,6 +4,8 @@
|
|||
// (C) 2001-2004 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <kinstance.h>
|
||||
#include <klocale.h>
|
||||
|
|
125
fontpool.h
125
fontpool.h
|
@ -7,8 +7,6 @@
|
|||
#ifndef _FONTPOOL_H
|
||||
#define _FONTPOOL_H
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include "fontEncodingPool.h"
|
||||
#include "fontMap.h"
|
||||
#include "fontprogress.h"
|
||||
|
@ -23,7 +21,6 @@
|
|||
#endif
|
||||
|
||||
class KProcess;
|
||||
class KShellProcess;
|
||||
|
||||
|
||||
/**
|
||||
|
@ -136,76 +133,76 @@ signals:
|
|||
void setStatusBarText( const QString& );
|
||||
|
||||
public slots:
|
||||
// Locates font files on the disk using the kpsewhich program. If
|
||||
// 'locateTFMonly' is true, the method does not look for PFB- or
|
||||
// PK-fonts. Instead, only TFM-files are searched. This option can be
|
||||
// used as a 'last resort': if a found cannot be found, one can at
|
||||
// least use the TFM file to draw filled rectangles for the
|
||||
// characters. If not null, the bool pointed at by virtualFontsFound
|
||||
// is set to true if one of the fonts found is a virtual font. If no
|
||||
// virtual font is found, the variable remains untouched.
|
||||
void locateFonts();
|
||||
|
||||
// Locates font files on the disk using the kpsewhich program. If
|
||||
// 'locateTFMonly' is true, the method does not look for PFB- or
|
||||
// PK-fonts. Instead, only TFM-files are searched. This option can be
|
||||
// used as a 'last resort': if a found cannot be found, one can at
|
||||
// least use the TFM file to draw filled rectangles for the
|
||||
// characters. If not null, the bool pointed at by virtualFontsFound
|
||||
// is set to true if one of the fonts found is a virtual font. If no
|
||||
// virtual font is found, the variable remains untouched.
|
||||
void locateFonts();
|
||||
|
||||
private:
|
||||
// This method goes through the list of fonts, and marks each of them
|
||||
// as 'located'. Used, e.g. after a fatal error in the font lookup
|
||||
// process to ensure that the problematic kpsewhich is not used again
|
||||
void markFontsAsLocated();
|
||||
// This method goes through the list of fonts, and marks each of them
|
||||
// as 'located'. Used, e.g. after a fatal error in the font lookup
|
||||
// process to ensure that the problematic kpsewhich is not used again
|
||||
void markFontsAsLocated();
|
||||
|
||||
// Checks if all the fonts file names have been located, and returns
|
||||
// true if that is so.
|
||||
bool areFontsLocated();
|
||||
// Checks if all the fonts file names have been located, and returns
|
||||
// true if that is so.
|
||||
bool areFontsLocated();
|
||||
|
||||
// This flag is used by PFB fonts to determine if the FREETYPE engine
|
||||
// should use hinted fonts or not
|
||||
bool useFontHints;
|
||||
|
||||
// Resolution of the output device.
|
||||
double displayResolution_in_dpi;
|
||||
|
||||
// Number of centimeters per DVI unit
|
||||
double CMperDVIunit;
|
||||
// This flag is used by PFB fonts to determine if the FREETYPE engine
|
||||
// should use hinted fonts or not
|
||||
bool useFontHints;
|
||||
|
||||
// Resolution of the output device.
|
||||
double displayResolution_in_dpi;
|
||||
|
||||
// Number of centimeters per DVI unit
|
||||
double CMperDVIunit;
|
||||
|
||||
|
||||
/** Members used for font location */
|
||||
|
||||
// Locates font files on the disk using the kpsewhich program. If
|
||||
// 'locateTFMonly' is true, the method does not look for PFB- or
|
||||
// PK-fonts. Instead, only TFM-files are searched. This option can be
|
||||
// used as a 'last resort': if a found cannot be found, one can at
|
||||
// least use the TFM file to draw filled rectangles for the
|
||||
// characters. If not null, the bool pointed at by virtualFontsFound
|
||||
// is set to true if one of the fonts found is a virtual font. If no
|
||||
// virtual font is found, the variable remains untouched.
|
||||
void locateFonts(bool makePK, bool locateTFMonly, bool *virtualFontsFound=0);
|
||||
/** Members used for font location */
|
||||
|
||||
// This QString is used internally by the mf_output_receiver()
|
||||
// method. This string is set to QString::null in locateFonts(bool,
|
||||
// bool, bool *). Values are set and read by the
|
||||
// mf_output_receiver(...) method
|
||||
QString MetafontOutput;
|
||||
// Locates font files on the disk using the kpsewhich program. If
|
||||
// 'locateTFMonly' is true, the method does not look for PFB- or
|
||||
// PK-fonts. Instead, only TFM-files are searched. This option can be
|
||||
// used as a 'last resort': if a found cannot be found, one can at
|
||||
// least use the TFM file to draw filled rectangles for the
|
||||
// characters. If not null, the bool pointed at by virtualFontsFound
|
||||
// is set to true if one of the fonts found is a virtual font. If no
|
||||
// virtual font is found, the variable remains untouched.
|
||||
void locateFonts(bool makePK, bool locateTFMonly, bool *virtualFontsFound=0);
|
||||
|
||||
// This QString is used internally by the mf_output_receiver()
|
||||
// method. This string is set to QString::null in locateFonts(bool,
|
||||
// bool, bool *). Values are set and read by the
|
||||
// mf_output_receiver(...) method
|
||||
QString MetafontOutput;
|
||||
|
||||
// This QString is used to collect the output of kpsewhich and
|
||||
// MetaFont. The string is set to QString::null in the
|
||||
// locateFonts()-method, and content is gathered by the
|
||||
// mf_output_receiver(). This string is used by locateFonts() and
|
||||
// locateFonts(bool, bool, bool *) to display error messages.
|
||||
QString kpsewhichOutput;
|
||||
|
||||
// This string is set to the DVI file's path. It is used to set the
|
||||
// current working directory for the kpsewhich command, so that
|
||||
// kpsewhich will find fonts that are stored in the DVI file's
|
||||
// directory. Used by the locateFonts() and the locateFonts(bool,
|
||||
// bool, bool *) method. Values are set by the
|
||||
// setExtraSearchPath(...) method
|
||||
QString extraSearchPath;
|
||||
|
||||
// FontProgress; the progress dialog used when generating fonts.
|
||||
fontProgressDialog progress;
|
||||
|
||||
// This QString is used to collect the output of kpsewhich and
|
||||
// MetaFont. The string is set to QString::null in the
|
||||
// locateFonts()-method, and content is gathered by the
|
||||
// mf_output_receiver(). This string is used by locateFonts() and
|
||||
// locateFonts(bool, bool, bool *) to display error messages.
|
||||
QString kpsewhichOutput;
|
||||
|
||||
// This string is set to the DVI file's path. It is used to set the
|
||||
// current working directory for the kpsewhich command, so that
|
||||
// kpsewhich will find fonts that are stored in the DVI file's
|
||||
// directory. Used by the locateFonts() and the locateFonts(bool,
|
||||
// bool, bool *) method. Values are set by the
|
||||
// setExtraSearchPath(...) method
|
||||
QString extraSearchPath;
|
||||
|
||||
// FontProgress; the progress dialog used when generating fonts.
|
||||
fontProgressDialog progress;
|
||||
|
||||
private slots:
|
||||
/** Members used for font location */
|
||||
|
||||
|
||||
// For internal purposess only. This slot is called when MetaFont is
|
||||
// run via the kpsewhich programm. The MetaFont output is
|
||||
// transmitted to the fontpool via this slot. This method calles
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
// (C) 2001--2004 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include "fontprogress.h"
|
||||
|
||||
#include <kdebug.h>
|
||||
|
|
|
@ -40,11 +40,12 @@ public:
|
|||
/** The number of steps already done is increased, the text received
|
||||
here is analyzed and presented to the user. */
|
||||
void increaseNumSteps(const QString& explanation);
|
||||
|
||||
/** Used to initialize the progress bar. If the argument proc is
|
||||
non-zero, the associated process will be killed when the "abort"
|
||||
button is pressed. The FontProgress uses a QGuarderPtr
|
||||
internally, so it is save to delete the KProcIO anytime. */
|
||||
|
||||
/** Used to initialize the progress bar. If the argument @c proc is
|
||||
non-zero, the associated process will be killed when the "abort"
|
||||
button is pressed. The pointer is stored internally inside a
|
||||
QPointer, so it is safe to delete the real KProcIO instance
|
||||
at any time. */
|
||||
void setTotalSteps(int, KProcIO *proc=0);
|
||||
|
||||
QLabel* TextLabel2;
|
||||
|
|
|
@ -6,6 +6,8 @@
|
|||
* written by Stefan Kebekus, originally based on code by Paul Vojta
|
||||
* and a large number of co-authors */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
|
||||
#include "glyph.h"
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
// (C) 2001-2003 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <kio/global.h>
|
||||
#include <klocale.h>
|
||||
|
|
2
kdvi.h
2
kdvi.h
|
@ -1,5 +1,5 @@
|
|||
// -*- C++ -*-
|
||||
// kdvi.h
|
||||
// kdvi.h
|
||||
//
|
||||
// global variables and definitions for kdvi.
|
||||
//
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
#ifndef KDVIMULTIPAGE_H
|
||||
#define KDVIMULTIPAGE_H
|
||||
|
||||
#include "kmultipage.h"
|
||||
#include "dviRenderer.h"
|
||||
#include "kmultipage.h"
|
||||
|
||||
#include <QStringList>
|
||||
|
||||
|
@ -94,5 +94,4 @@ private:
|
|||
KAction *exportPSAction;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
// Please report bugs or improvements, etc. via the "Report bug"-Menu
|
||||
// of kdvi.
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kaction.h>
|
||||
#include <kdebug.h>
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
|
||||
// Add header files alphabetically
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
|
||||
#include <kcombobox.h>
|
||||
|
|
1
psgs.cpp
1
psgs.cpp
|
@ -6,6 +6,7 @@
|
|||
// (C) 2004 Stefan Kebekus
|
||||
// Distributed under the GPL
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
|
|
2
psgs.h
2
psgs.h
|
@ -10,10 +10,10 @@
|
|||
#ifndef _PSGS_H_
|
||||
#define _PSGS_H_
|
||||
|
||||
#include <Q3IntDict>
|
||||
#include <QColor>
|
||||
#include <QObject>
|
||||
#include <QString>
|
||||
#include <Q3IntDict>
|
||||
|
||||
class PageNumber;
|
||||
class QPainter;
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include "renderedDviPagePixmap.h"
|
||||
#include "hyperlink.h"
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
|
||||
// Copyright 2000--2004, Stefan Kebekus (kebekus@kde.org).
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
|
|
2
util.cpp
2
util.cpp
|
@ -49,6 +49,8 @@
|
|||
* and Luis Miguel Silveira, MIT RLE.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <kmessagebox.h>
|
||||
#include <klocale.h>
|
||||
|
|
1
vf.cpp
1
vf.cpp
|
@ -23,6 +23,7 @@
|
|||
* SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <kdebug.h>
|
||||
#include <klocale.h>
|
||||
|
|
Loading…
Reference in a new issue