mirror of
https://invent.kde.org/graphics/okular
synced 2024-09-13 13:11:41 +00:00
kdelibs4support--
This commit is contained in:
parent
2d8df45845
commit
8f8b70d893
|
@ -25,12 +25,10 @@
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include <QTime>
|
#include <QTime>
|
||||||
#include <kconfig.h>
|
#include <kconfig.h>
|
||||||
#include <kglobal.h>
|
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
#include <QMimeType>
|
#include <QMimeType>
|
||||||
#include <QMimeDatabase>
|
#include <QMimeDatabase>
|
||||||
#include <kstandarddirs.h>
|
#include <QVBoxLayout>
|
||||||
#include <kvbox.h>
|
|
||||||
|
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QCheckBox>
|
#include <QCheckBox>
|
||||||
|
@ -280,11 +278,14 @@ void dviRenderer::showThatSourceInformationIsPresent()
|
||||||
KDialogBase dialog(i18n("KDVI: Information"), KDialogBase::Yes, KDialogBase::Yes, KDialogBase::Yes,
|
KDialogBase dialog(i18n("KDVI: Information"), KDialogBase::Yes, KDialogBase::Yes, KDialogBase::Yes,
|
||||||
parentWidget, "information", true, true, KStandardGuiItem::ok());
|
parentWidget, "information", true, true, KStandardGuiItem::ok());
|
||||||
|
|
||||||
KVBox *topcontents = new KVBox (&dialog);
|
QWidget *topcontents = new QWidget (&dialog);
|
||||||
topcontents->setSpacing(KDialog::spacingHint()*2);
|
QVBoxLayout *topcontentsVBoxLayout = new QVBoxLayout(topcontents);
|
||||||
topcontents->setMargin(KDialog::marginHint()*2);
|
topcontentsVBoxLayout->setMargin(0);
|
||||||
|
topcontentsVBoxLayout->setSpacing(KDialog::spacingHint()*2);
|
||||||
|
topcontentsVBoxLayout->setMargin(KDialog::marginHint()*2);
|
||||||
|
|
||||||
QWidget *contents = new QWidget(topcontents);
|
QWidget *contents = new QWidget(topcontents);
|
||||||
|
topcontentsVBoxLayout->addWidget(contents);
|
||||||
QHBoxLayout * lay = new QHBoxLayout(contents);
|
QHBoxLayout * lay = new QHBoxLayout(contents);
|
||||||
lay->setSpacing(KDialog::spacingHint()*2);
|
lay->setSpacing(KDialog::spacingHint()*2);
|
||||||
|
|
||||||
|
@ -300,6 +301,7 @@ void dviRenderer::showThatSourceInformationIsPresent()
|
||||||
lay->addStretch(1);
|
lay->addStretch(1);
|
||||||
QSize extraSize = QSize(50,30);
|
QSize extraSize = QSize(50,30);
|
||||||
QCheckBox *checkbox = new QCheckBox(i18n("Do not show this message again"), topcontents);
|
QCheckBox *checkbox = new QCheckBox(i18n("Do not show this message again"), topcontents);
|
||||||
|
topcontentsVBoxLayout->addWidget(checkbox);
|
||||||
extraSize = QSize(50,0);
|
extraSize = QSize(50,0);
|
||||||
dialog.setHelpLinkText(i18n("Explain in more detail..."));
|
dialog.setHelpLinkText(i18n("Explain in more detail..."));
|
||||||
dialog.setHelp("inverse-search", "kdvi");
|
dialog.setHelp("inverse-search", "kdvi");
|
||||||
|
|
|
@ -25,19 +25,19 @@
|
||||||
#include "dviRenderer.h"
|
#include "dviRenderer.h"
|
||||||
#include "debug_dvi.h"
|
#include "debug_dvi.h"
|
||||||
|
|
||||||
#include <KStandardDirs>
|
|
||||||
#include <kfiledialog.h>
|
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
#include <kmessagebox.h>
|
#include <kmessagebox.h>
|
||||||
#include <kprocess.h>
|
#include <kprocess.h>
|
||||||
#include <ktemporaryfile.h>
|
|
||||||
|
|
||||||
#include <QEventLoop>
|
#include <QEventLoop>
|
||||||
#include <QFileInfo>
|
#include <QFileInfo>
|
||||||
#include <QLabel>
|
#include <QLabel>
|
||||||
#include <QtPrintSupport/QPrinter>
|
#include <QtPrintSupport/QPrinter>
|
||||||
|
#include <QTemporaryFile>
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
|
#include <QStandardPaths>
|
||||||
|
|
||||||
|
|
||||||
DVIExport::DVIExport(dviRenderer& parent)
|
DVIExport::DVIExport(dviRenderer& parent)
|
||||||
|
@ -125,7 +125,7 @@ DVIExportToPDF::DVIExportToPDF(dviRenderer& parent, const QString& output_name)
|
||||||
if (!input.exists() || !input.isReadable())
|
if (!input.exists() || !input.isReadable())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (KStandardDirs::findExe("dvipdfm").isEmpty()) {
|
if (QStandardPaths::findExecutable("dvipdfm").isEmpty()) {
|
||||||
emit error(i18n("<qt><p>Okular could not locate the program <em>dvipdfm</em> on your computer. This program is "
|
emit error(i18n("<qt><p>Okular could not locate the program <em>dvipdfm</em> on your computer. This program is "
|
||||||
"essential for the export function to work. You can, however, convert "
|
"essential for the export function to work. You can, however, convert "
|
||||||
"the DVI-file to PDF using the print function of Okular, but that will often "
|
"the DVI-file to PDF using the print function of Okular, but that will often "
|
||||||
|
@ -182,7 +182,7 @@ DVIExportToPS::DVIExportToPS(dviRenderer& parent,
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (KStandardDirs::findExe("dvips").isEmpty()) {
|
if (QStandardPaths::findExecutable("dvips").isEmpty()) {
|
||||||
emit error(i18n("<qt><p>Okular could not locate the program <em>dvips</em> on your computer. "
|
emit error(i18n("<qt><p>Okular could not locate the program <em>dvips</em> on your computer. "
|
||||||
"That program is essential for the export function to work.</p>"
|
"That program is essential for the export function to work.</p>"
|
||||||
"<p>Hint to the perplexed system administrator: Okular uses the PATH environment "
|
"<p>Hint to the perplexed system administrator: Okular uses the PATH environment "
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
|
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
#include <kprocess.h>
|
#include <kprocess.h>
|
||||||
#include <ktemporaryfile.h>
|
#include <qtemporaryfile.h>
|
||||||
#include <kurl.h>
|
#include <kurl.h>
|
||||||
|
|
||||||
#include <QtCore/qloggingcategory.h>
|
#include <QtCore/qloggingcategory.h>
|
||||||
|
|
Loading…
Reference in a new issue