Description: <short summary of the patch>
 TODO: Put a short summary on the line above and replace this paragraph
 with a longer explanation of this change. Complete the meta-information
 with other relevant fields (see below for details). To make it easier, the
 information below has been extracted from the changelog. Adjust it or drop
 it.
 .
 ktikz (0.13.2+ds1-1) unstable; urgency=medium
 .
   * New upstream release.
   * Set upstream metadata fields: Bug-Database, Bug-Submit.
   * Fix day-of-week for changelog entry 0.10~svn112-1.
   * Update standards version to 4.6.0, no changes needed.
Author: Stuart Prescott <stuart@debian.org>

---
The information above should follow the Patch Tagging Guidelines, please
checkout https://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:

Origin: (upstream|backport|vendor|other), (<patch-url>|commit:<commit-id>)
Bug: <upstream-bugtracker-url>
Bug-Debian: https://bugs.debian.org/<bugnumber>
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
Forwarded: (no|not-needed|<patch-forwarded-url>)
Applied-Upstream: <version>, (<commit-url>|commit:<commid-id>)
Reviewed-By: <name and email of someone who approved/reviewed the patch>
Last-Update: 2025-04-08

--- ktikz-0.13.2+ds1.orig/app/app.pri
+++ ktikz-0.13.2+ds1/app/app.pri
@@ -6,7 +6,7 @@ LANGUAGE = C++
 CONFIG += qt warn_on thread
 QT += core gui
 greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
-greaterThan(QT_MAJOR_VERSION, 6): QT += core5compat pdf
+greaterThan(QT_MAJOR_VERSION, 5): QT += core5compat pdf
 
 DEFINES += QT_STL QT_NO_CAST_FROM_ASCII QT_NO_CAST_TO_ASCII QT_NO_CAST_FROM_BYTEARRAY QT_STRICT_ITERATORS QT_NO_URL_CAST_FROM_STRING QT_NO_KEYWORDS
 #DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x050200
@@ -15,6 +15,7 @@ DEFINES += QT_STL QT_NO_CAST_FROM_ASCII
 #QMAKE_CXXFLAGS += -Wall -Wextra -Wpedantic -Weffc++ -Wlogical-op -Wmissing-declarations -Wold-style-cast -Woverloaded-virtual -Wshadow -Wstrict-null-sentinel -Wswitch-default -Wuseless-cast -Wzero-as-null-pointer-constant -fmessage-length=0 -fdiagnostics-show-location=every-line
 #QMAKE_CXXFLAGS += -Wall -Wextra -Wpedantic -Wlogical-op -Wmissing-declarations -Wold-style-cast -Woverloaded-virtual
 #QMAKE_CXX = clang
+QMAKE_CXXFLAGS += -Og -ggdb
 
 DEFINES += ORGNAME=\\\"$${ORGNAME}\\\"
 DEFINES += APPNAME=\\\"$${APPNAME}\\\"
--- ktikz-0.13.2+ds1.orig/app/configappearancewidget.cpp
+++ ktikz-0.13.2+ds1/app/configappearancewidget.cpp
@@ -115,8 +115,12 @@ void ConfigAppearanceWidget::setItemTool
 {
 	const QFontMetrics metrics(font);
 	ui.itemTable->setRowHeight(m_itemHighlighted, metrics.height() + m_itemMargin);
-	if (metrics.width(item->text()) >= ui.itemTable->contentsRect().width() - 30)
-		item->setToolTip(item->text());
+#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
+    if (metrics.horizontalAdvance(item->text()) >= ui.itemTable->contentsRect().width() - 30)
+#else
+    if (metrics.width(item->text()) >= ui.itemTable->contentsRect().width() - 30)
+#endif
+        item->setToolTip(item->text());
 	else
 		item->setToolTip(QString());
 }
--- ktikz-0.13.2+ds1.orig/app/configeditorwidget.cpp
+++ ktikz-0.13.2+ds1/app/configeditorwidget.cpp
@@ -22,7 +22,11 @@
 #include "configeditorwidget.h"
 
 #include <QtCore/QSettings>
+#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
+#include <QtCore5Compat/QTextCodec>
+#else
 #include <QTextCodec>
+#endif
 #if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
 #include <QtWidgets/QApplication>
 #else
@@ -197,8 +201,12 @@ void ConfigEditorWidget::fillCodecComboB
 	QVector<ComboItem> ciList; ciList.reserve(ca.length());
 	Q_FOREACH(const QByteArray &ba , ca)
 		ciList.append(ComboItem(codecNameToString(ba), ba));
-	qSort(ciList);
-	Q_FOREACH (const ComboItem& ci, ciList) {
+#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
+    std::sort(ciList.begin(), ciList.end());
+#else
+    qSort(ciList);
+#endif
+    Q_FOREACH (const ComboItem& ci, ciList) {
 		cb->addItem(ci.text, ci.data);
 	}
 }
--- ktikz-0.13.2+ds1.orig/app/editreplacecurrentwidget.cpp
+++ ktikz-0.13.2+ds1/app/editreplacecurrentwidget.cpp
@@ -50,7 +50,11 @@ ReplaceCurrentWidget::ReplaceCurrentWidg
 	buttonsLayout->addWidget(dontReplaceButton);
 	buttonsLayout->addWidget(cancelButton);
 	buttonsLayout->addStretch();
-	buttonsLayout->setMargin(0);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
+    buttonsLayout->setContentsMargins(0, 0, 0, 0);
+#else
+    buttonsLayout->setMargin(0);
+#endif
 	buttonsWidget->setLayout(buttonsLayout);
 	mainLayout->addWidget(m_replaceLabel);
 	mainLayout->addWidget(buttonsWidget);
--- ktikz-0.13.2+ds1.orig/app/editreplacewidget.cpp
+++ ktikz-0.13.2+ds1/app/editreplacewidget.cpp
@@ -100,7 +100,7 @@ void ReplaceWidget::doFind()
 	if (ui.comboBoxFind->findText(currentText) < 0)
 		ui.comboBoxFind->addItem(currentText);
 
-	QTextDocument::FindFlags flags = 0;
+    QTextDocument::FindFlags flags = (QTextDocument::FindFlags)0;
 	if (ui.checkBoxCaseSensitive->isChecked())
 		flags |= QTextDocument::FindCaseSensitively;
 	if (ui.checkBoxWholeWords->isChecked())
@@ -121,7 +121,7 @@ void ReplaceWidget::doReplace()
 	if (ui.comboBoxReplace->findText(replacementText) < 0)
 		ui.comboBoxReplace->addItem(replacementText);
 
-	QTextDocument::FindFlags flags = 0;
+    QTextDocument::FindFlags flags = (QTextDocument::FindFlags)0;
 	if (ui.checkBoxCaseSensitive->isChecked())
 		flags |= QTextDocument::FindCaseSensitively;
 	if (ui.checkBoxWholeWords->isChecked())
--- ktikz-0.13.2+ds1.orig/app/linenumberwidget.cpp
+++ ktikz-0.13.2+ds1/app/linenumberwidget.cpp
@@ -74,7 +74,11 @@ void LineNumberWidget::paintEvent(QPaint
 			{
 				if (userBookmarks.at(i) == lineNumber)
 				{
-					painter.fillRect(2, top, fm.width(QLatin1Char('B')) + 4, lineHeight, m_highlightBrush);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+                    painter.fillRect(2, top, fm.horizontalAdvance(QLatin1Char('B')) + 4, lineHeight, m_highlightBrush);
+#else
+                    painter.fillRect(2, top, fm.width(QLatin1Char('B')) + 4, lineHeight, m_highlightBrush);
+#endif
 					painter.setPen(m_highlightedTextPen);
 					painter.drawText(4, top, width() - 4, lineHeight, Qt::AlignLeft | Qt::AlignTop, QLatin1String("B"));
 					painter.setPen(m_highlightPen);
@@ -97,8 +101,12 @@ void LineNumberWidget::paintEvent(QPaint
 void LineNumberWidget::mousePressEvent(QMouseEvent *event)
 {
 	event->accept();
-	const QPoint p = m_editor->viewport()->mapFromGlobal(event->globalPos());
-	const int lineNumber = m_editor->cursorForPosition(p).blockNumber() + 1;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const QPointF p = m_editor->viewport()->mapFromGlobal(event->globalPosition());
+#else
+    const QPoint p = m_editor->viewport()->mapFromGlobal(event->globalPos());
+#endif
+    const int lineNumber = m_editor->cursorForPosition(p.toPoint()).blockNumber() + 1;
 	if (lineNumber <= 0)
 		return;
 
--- ktikz-0.13.2+ds1.orig/app/loghighlighter.cpp
+++ ktikz-0.13.2+ds1/app/loghighlighter.cpp
@@ -37,7 +37,11 @@ LogHighlighter::LogHighlighter(QTextDocu
 	                << tr("This program will not work!");
 	Q_FOREACH (const QString &pattern, keywordPatterns)
 	{
-		rule.pattern = QRegExp(pattern);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        rule.pattern = QRegularExpression(pattern);
+#else
+        rule.pattern = QRegExp(pattern);
+#endif
 		rule.format = keywordFormat;
 		m_highlightingRules.append(rule);
 	}
@@ -45,7 +49,11 @@ LogHighlighter::LogHighlighter(QTextDocu
 	QTextCharFormat commandFormat;
 	commandFormat.setForeground(Qt::darkBlue);
 	commandFormat.setFontWeight(QFont::Bold);
-	rule.pattern = QRegExp(QLatin1String("^\\[[^\\]\\d][^\\]]*\\]"));
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    rule.pattern = QRegularExpression(QLatin1String("^\\[[^\\]\\d][^\\]]*\\]"));
+#else
+    rule.pattern = QRegExp(QLatin1String("^\\[[^\\]\\d][^\\]]*\\]"));
+#endif
 	rule.format = commandFormat;
 	m_highlightingRules.append(rule);
 
@@ -65,8 +73,19 @@ void LogHighlighter::highlightBlock(cons
 	{
 //		const QRegExp expression(rule.pattern);
 //		int index = text.indexOf(expression);
-		QRegExp expression(rule.pattern);
-		int index = expression.indexIn(text);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        QRegularExpression expression(rule.pattern);
+        QRegularExpressionMatch match = expression.match(text);
+        while (match.hasMatch())
+        {
+            const int length = match.capturedLength();
+            setFormat(match.capturedStart(), length, rule.format);
+//			index = text.indexOf(expression, index + length);
+            match = expression.match(text, match.capturedEnd() + 1);
+        }
+#else
+        QRegExp expression(rule.pattern);
+        int index = text.indexOf(expression);
 		while (index >= 0)
 		{
 			const int length = expression.matchedLength();
@@ -74,7 +93,8 @@ void LogHighlighter::highlightBlock(cons
 //			index = text.indexOf(expression, index + length);
 			index = expression.indexIn(text, index + length);
 		}
-	}
+#endif
+    }
 
 	// Highlight statistics (at the end of the log)
 	setCurrentBlockState(0); // The current block state tracks multiline formatting
--- ktikz-0.13.2+ds1.orig/app/loghighlighter.h
+++ ktikz-0.13.2+ds1/app/loghighlighter.h
@@ -23,6 +23,7 @@
 
 #include <QtGui/QSyntaxHighlighter>
 #include <QtGui/QTextCharFormat>
+#include <QRegularExpression>
 
 /** A simple, incomplete highlighter for LaTeX .log files
  * @author Florian Hackenberger <florian@hackenberger.at>
@@ -44,7 +45,11 @@ protected:
 private:
 	struct LogHighlightingRule
 	{
-		QRegExp pattern; /// The pattern to match for formatting
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        QRegularExpression pattern; /// The pattern to match for formatting
+#else
+        QRegExp pattern; /// The pattern to match for formatting
+#endif
 		QTextCharFormat format; /// The style of the formatting
 	};
 	/// All highlighting rules with their formatting for easy iteration
--- ktikz-0.13.2+ds1.orig/app/logtextedit.cpp
+++ ktikz-0.13.2+ds1/app/logtextedit.cpp
@@ -69,7 +69,11 @@ void LogTextEdit::setLogPalette(bool run
 	if (runFailed)
 	{
 		QPalette failedPalette(QApplication::palette());
-		failedPalette.setColor(QPalette::Background, QColor(255, 102, 102));
+#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
+        failedPalette.setColor(QPalette::Window, QColor(255, 102, 102));
+#else
+        failedPalette.setColor(QPalette::Background, QColor(255, 102, 102));
+#endif
 		setAutoFillBackground(true);
 		setPalette(failedPalette);
 	}
--- ktikz-0.13.2+ds1.orig/app/mainwindow.cpp
+++ ktikz-0.13.2+ds1/app/mainwindow.cpp
@@ -37,7 +37,11 @@
 
 #include <QMenuBar>
 #include <QStatusBar>
+#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
+#include <QtCore5Compat/QTextCodec>
+#else
 #include <QtCore/QTextCodec>
+#endif
 #include <QtCore/QProcess>
 #include <QtCore/QSettings>
 #include <QtCore/QTextStream>
@@ -45,7 +49,9 @@
 #include <QtGui/QCloseEvent>
 #include <QtGui/QDesktopServices>
 #if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
+#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
 #include <QtWidgets/QDesktopWidget>
+#endif
 #include <QtWidgets/QDockWidget>
 #include <QtWidgets/QLabel>
 #include <QtWidgets/QMessageBox>
@@ -94,7 +100,7 @@
 
 QList<MainWindow*> MainWindow::s_mainWindowList;
 
-MainWindow::MainWindow()
+MainWindow::MainWindow() : 	m_doOverrideEncoder(false), m_doOverrideDecoder(false)
 {
 //QTime t = QTime::currentTime();
 #ifndef KTIKZ_USE_KDE
@@ -107,6 +113,9 @@ MainWindow::MainWindow()
 
 	s_mainWindowList.append(this);
 
+    qRegisterMetaType<QPdfDocument>();
+    qRegisterMetaType<QPdfDocument*>();
+
 #ifndef KTIKZ_USE_KDE
 	QStringList themeSearchPaths;
 	themeSearchPaths << QDir::homePath() + QLatin1String("/.local/share/icons/");
@@ -154,7 +163,11 @@ MainWindow::MainWindow()
 	QWidget *mainWidget = new QWidget(this);
 	QVBoxLayout *mainLayout = new QVBoxLayout(mainWidget);
 	mainLayout->setSpacing(0);
-	mainLayout->setMargin(0);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    mainLayout->setContentsMargins(0, 0, 0, 0);
+#else
+    mainLayout->setMargin(0);
+#endif
 	mainLayout->addWidget(m_tikzPreviewController->templateWidget());
 	mainLayout->addWidget(m_tikzEditorView);
 
@@ -908,11 +921,40 @@ void MainWindow::applySettings()
 	updateCompleter();
 	settings.beginGroup(QLatin1String("encoding"));
 		QVariant qv = settings.value(QLatin1String("default"));
-		setCurrentEncoding( qv.isNull() ? QTextCodec::codecForLocale() : QTextCodec::codecForName(qv.toByteArray())) ;
-		qv = settings.value(QLatin1String("encoder"));
-		m_overrideEncoder = qv.isNull() ? NULL : QTextCodec::codecForName(qv.toByteArray()) ;
-		qv = settings.value(QLatin1String("decoder"));
-		m_overrideDecoder = qv.isNull() ? NULL : QTextCodec::codecForName(qv.toByteArray()) ;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        if (qv.isNull())
+        {
+            setCurrentEncoding( QStringConverter::System ) ;
+        } else {
+            std::optional<QStringConverter::Encoding> currentEncoding = QStringConverter::encodingForName(qv.toString().toStdString().c_str());
+            setCurrentEncoding( currentEncoding.value_or( QStringConverter::System ) ) ;
+        }
+
+        qv = settings.value(QLatin1String("encoder"));
+        if (qv.isNull())
+        {
+            m_doOverrideEncoder = false;
+        } else {
+            std::optional<QStringConverter::Encoding> overrideEncoding = QStringConverter::encodingForName(qv.toString().toStdString().c_str());
+            m_doOverrideEncoder = overrideEncoding.has_value();
+            m_overrideEncoder = overrideEncoding.value_or( QStringConverter::System ) ;
+        }
+        qv = settings.value(QLatin1String("decoder"));
+        if (qv.isNull())
+        {
+            m_doOverrideDecoder = false;
+        } else {
+            std::optional<QStringConverter::Encoding> overrideDecoding = QStringConverter::encodingForName(qv.toString().toStdString().c_str());
+            m_doOverrideDecoder = overrideDecoding.has_value();
+            m_overrideDecoder = overrideDecoding.value_or( QStringConverter::System ) ;
+        }
+#else
+        setCurrentEncoding( qv.isNull() ? QTextCodec::codecForLocale() : QTextCodec::codecForName(qv.toByteArray())) ;
+        qv = settings.value(QLatin1String("encoder"));
+        m_overrideEncoder = qv.isNull() ? NULL : QTextCodec::codecForName(qv.toByteArray()) ;
+        qv = settings.value(QLatin1String("decoder"));
+        m_overrideDecoder = qv.isNull() ? NULL : QTextCodec::codecForName(qv.toByteArray()) ;
+#endif
 		m_encoderBom = settings.value(QLatin1String("bom"), true).toBool();
 	settings.endGroup();
 
@@ -936,7 +978,11 @@ void MainWindow::readSettings()
 
 	QSettings settings;
 	settings.beginGroup(QLatin1String("MainWindow"));
-	const int screenWidth = QApplication::desktop()->availableGeometry().width();
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const int screenWidth = screen()->availableGeometry().width();
+#else
+    const int screenWidth = QApplication::desktop()->availableGeometry().width();
+#endif
 	QSize size;
 	if (screenWidth > 1200)
 		size = settings.value(QLatin1String("size"), QSize(1200, 600)).toSize();
@@ -1048,7 +1094,11 @@ void MainWindow::loadUrl(const QUrl &url
 		QApplication::setOverrideCursor(Qt::WaitCursor);
 		this->configureStreamDecoding(in);
 		m_tikzQtEditorView->editor()->setPlainText(in.readAll());
-		setCurrentEncoding(in.codec());
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        setCurrentEncoding(in.encoding());
+#else
+        setCurrentEncoding(in.codec());
+#endif
 	}
 
   QApplication::restoreOverrideCursor();
@@ -1107,11 +1157,19 @@ bool MainWindow::saveUrl(const QUrl &url
 	return true;
 }
 
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+void MainWindow::setCurrentEncoding(QStringConverter::Encoding codec )
+{
+    m_currentEncoding = codec;
+   // TODO: implement user warning and suggestion to reload the file.
+}
+#else
 void MainWindow::setCurrentEncoding(QTextCodec *codec )
 {
-	m_currentEncoding = codec;
+    m_currentEncoding = codec;
    // TODO: implement user warning and suggestion to reload the file.
 }
+#endif
 
 QUrl MainWindow::url() const
 {
@@ -1134,18 +1192,29 @@ QString MainWindow::strippedName(const Q
 	return (fileName.isEmpty()) ? QLatin1String("untitled.txt") : fileName;
 }
 
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+QStringConverter::Encoding MainWindow::getEncoder() const
+{
+    return this->m_doOverrideEncoder ? this->m_overrideEncoder : this->m_currentEncoding;
+}
+#else
 QTextCodec *MainWindow::getEncoder() const
 {
-	return this->m_overrideEncoder ? this->m_overrideEncoder : this->m_currentEncoding;
+    return this->m_overrideEncoder ? this->m_overrideEncoder : this->m_currentEncoding;
 }
+#endif
 
 void MainWindow::configureStreamEncoding(QTextStream& textStream)
 {
-	QTextCodec* encoder = this->getEncoder();
-	if(Q_LIKELY(encoder)) // should be true
-		textStream.setCodec(encoder);
-	else
-		qWarning("The encoder variable should not be null.");
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    textStream.setEncoding(this->getEncoder());
+#else
+    QTextCodec* encoder = this->getEncoder();
+    if(Q_LIKELY(encoder)) // should be true
+        textStream.setCodec(encoder);
+    else
+        qWarning("The encoder variable should not be null.");
+#endif
 
 	textStream.setGenerateByteOrderMark(this->m_encoderBom);
 
@@ -1153,10 +1222,17 @@ void MainWindow::configureStreamEncoding
 
 void MainWindow::configureStreamDecoding(QTextStream &textStream)
 {
-	if(m_overrideDecoder)
-	{
-		textStream.setCodec(m_overrideDecoder);
-	}
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    if(m_doOverrideDecoder)
+    {
+        textStream.setEncoding(m_overrideDecoder);
+    }
+#else
+    if(m_overrideDecoder)
+    {
+        textStream.setCodec(m_overrideDecoder);
+    }
+#endif
 	textStream.setAutoDetectUnicode(true);
 }
 
--- ktikz-0.13.2+ds1.orig/app/mainwindow.h
+++ ktikz-0.13.2+ds1/app/mainwindow.h
@@ -29,6 +29,7 @@
 #include <QtCore/QtGlobal>
 #if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
 #include <QtWidgets/QMainWindow>
+#include <QtPdf/QPdfDocument>
 #else
 #include <QtGui/QMainWindow>
 #endif
@@ -45,6 +46,7 @@ class QDockWidget;
 class QLabel;
 class QMenu;
 class QToolButton;
+class QTextCodec;
 
 class Action;
 class ConfigDialog;
@@ -58,6 +60,9 @@ class TikzHighlighter;
 class TikzPreviewController;
 class UserCommandInserter;
 
+Q_DECLARE_METATYPE(QPdfDocument)
+Q_DECLARE_METATYPE(QPdfDocument*)
+
 /** Provides a tiny application for simple editing of TikZ graphics
  * @author Florian Hackenberger
  */
@@ -139,7 +144,11 @@ private Q_SLOTS:
 	void updateCompleter();
 	/// Change the codec for the current document
 	/// @param isUserRequest set to true if the user requested the changement (in this case, the application should warn the user -- not implemented yet.).
-  void setCurrentEncoding(QTextCodec* codec /*, bool isUserRequest = false */ );
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    void setCurrentEncoding(QStringConverter::Encoding codec );
+#else
+    void setCurrentEncoding(QTextCodec* codec /*, bool isUserRequest = false */ );
+#endif
 
 private:
 	void createActions();
@@ -230,15 +239,29 @@ private:
 	QPointer<ConfigDialog> m_configDialog;
 
 	QUrl m_currentUrl;
-	QTextCodec* m_currentEncoding;
-	/// If not null, override the encoder (rather than @ref m_currentEncoding)
-	QTextCodec* m_overrideEncoder;
-	/// If not null, override the decoder
-	QTextCodec* m_overrideDecoder;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    QStringConverter::Encoding m_currentEncoding;
+    /// If true, override the encoder (rather than @ref m_currentEncoding)
+    bool m_doOverrideEncoder;
+    QStringConverter::Encoding m_overrideEncoder;
+    /// If true, override the decoder
+    bool m_doOverrideDecoder;
+    QStringConverter::Encoding m_overrideDecoder;
+#else
+    QTextCodec* m_currentEncoding;
+    /// If not null, override the encoder (rather than @ref m_currentEncoding)
+    QTextCodec* m_overrideEncoder;
+    /// If not null, override the decoder
+    QTextCodec* m_overrideDecoder;
+#endif
 	/// True if a BOM must be added to the PGF-file
 	bool m_encoderBom;
 	/// Return the current encoder (m_currentEncoding or another if encoder is overriden).
-	/*virtual*/ QTextCodec* getEncoder() const;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    /*virtual*/ QStringConverter::Encoding getEncoder() const;
+#else
+    /*virtual*/ QTextCodec* getEncoder() const;
+#endif
 
 	QUrl m_lastUrl;
 	QDateTime m_lastInternalModifiedDateTime;
--- ktikz-0.13.2+ds1.orig/app/tikzcommandinserter.cpp
+++ ktikz-0.13.2+ds1/app/tikzcommandinserter.cpp
@@ -55,12 +55,15 @@
 #include <QtGui/QStackedWidget>
 #include <QtGui/QToolTip>
 #endif
+#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
+#include <QtCore5Compat/QRegExp>
+#endif
 
 #include "tikzeditorhighlighter.h"
 #include "tikzcommandwidget.h"
 #include "../common/utils/combobox.h"
 
-static const QString s_completionPlaceHolder(0x2022);
+static const QString s_completionPlaceHolder(QChar(0x2022));
 
 TikzCommandList TikzCommandInserter::m_tikzSections;
 QList<TikzCommand> TikzCommandInserter::m_tikzCommandsList;
@@ -102,11 +105,15 @@ static TikzCommand newCommand(const QStr
 static QString translateOptions(const QString &text)
 {
 	QString translatedText;
-	for (int pos = 0, oldPos = 0; pos >= 0;)
+    for (qsizetype pos = 0, oldPos = 0; pos >= 0;)
 	{
 		oldPos = pos;
 		pos = text.indexOf(QLatin1Char('<'), pos); // option is between < and >
-		translatedText += text.midRef(oldPos, pos - oldPos + 1); // add text between the current option and the previous option; this also adds the end of the original string, except when there are no options
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        translatedText += text.mid(oldPos, pos - oldPos + 1); // add text between the current option and the previous option; this also adds the end of the original string, except when there are no options
+#else
+        translatedText += text.midRef(oldPos, pos - oldPos + 1); // add text between the current option and the previous option; this also adds the end of the original string, except when there are no options
+#endif
 		if (pos >= 0)
 		{
 			oldPos = pos;
@@ -504,8 +511,13 @@ void TikzCommandInserter::addListWidgetI
 		QString itemText = commandList.children.at(i).title;
 		item->setText(itemText.remove(QLatin1Char('&')));
 
-		item->setBackgroundColor(titleBg);
-		item->setTextColor(titleFg);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        item->setBackground(titleBg);
+        item->setForeground(titleFg);
+#else
+        item->setBackgroundColor(titleBg);
+        item->setTextColor(titleFg);
+#endif
 		item->setFont(titleFont);
 
 		addListWidgetItems(listWidget, standardPalette, commandList.children.at(i));
@@ -579,7 +591,11 @@ QDockWidget *TikzCommandInserter::getDoc
 	tikzLayout->addWidget(commandsComboLabel, 0, 0);
 	tikzLayout->addWidget(m_commandsCombo, 0, 1);
 	tikzLayout->addWidget(m_commandsStack, 1, 0, 1, 2);
-	tikzLayout->setMargin(5);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    tikzLayout->setContentsMargins(5, 5, 5, 5);
+#else
+    tikzLayout->setMargin(5);
+#endif
 
 	TikzCommandWidget *tikzWidget = new TikzCommandWidget;
 	tikzWidget->setLayout(tikzLayout);
@@ -807,7 +823,11 @@ void TikzCommandInserter::insertTag(cons
 
     // replace all options (between <...>) by a place holder
     QString insertWord = tag;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const QRegularExpression rx(QLatin1String("<[^<>]*>"));
+#else
     const QRegExp rx(QLatin1String("<[^<>]*>"));
+#endif
     insertWord.replace(rx, s_completionPlaceHolder);
 
     QTextCursor cur = m_mainEdit->textCursor();
--- ktikz-0.13.2+ds1.orig/app/tikzeditor.cpp
+++ ktikz-0.13.2+ds1/app/tikzeditor.cpp
@@ -58,7 +58,7 @@
 
 #include "linenumberwidget.h"
 
-static const QString s_completionPlaceHolder(0x2022);
+static const QString s_completionPlaceHolder(QChar(0x2022));
 
 TikzEditor::TikzEditor(QWidget *parent)
 	: QPlainTextEdit(parent)
@@ -314,7 +314,11 @@ void TikzEditor::paintSpace(QPainter &pa
 void TikzEditor::printWhiteSpaces(QPainter &painter)
 {
 	const QFontMetrics fontMetrics = QFontMetrics(document()->defaultFont());
-	const int spaceWidth = fontMetrics.width(QLatin1Char(' '));
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const int spaceWidth = fontMetrics.horizontalAdvance(QLatin1Char(' '));
+#else
+    const int spaceWidth = fontMetrics.width(QLatin1Char(' '));
+#endif
 	const int fontHeight = fontMetrics.height();
 	QTextCursor cursor = textCursor();
 
@@ -511,7 +515,7 @@ void TikzEditor::keyPressEvent(QKeyEvent
 	{
 		QTextCursor cursor = textCursor();
 		QTextBlock block = cursor.block();
-		QTextDocument::FindFlags flags = 0;
+        QTextDocument::FindFlags flags = (QTextDocument::FindFlags)0;
 		if (event->key() == Qt::Key_Backtab)
 			flags = QTextDocument::FindBackward;
 		if (cursor.hasSelection() && cursor.selectedText().contains(QChar::ParagraphSeparator))
@@ -634,8 +638,13 @@ void TikzEditor::insertCompletion(const
 
 	// remove all options (between <...>) and put cursor at the first option
 	QString insertWord = completion.right(extra);
-	const QRegExp rx(QLatin1String("<[^<>]*>"));
-	const int offset = rx.indexIn(insertWord) - 1; // put cursor at the first option
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const QRegularExpression rx(QLatin1String("<[^<>]*>"));
+    const int offset = insertWord.indexOf(rx) - 1; // put cursor at the first option
+#else
+    const QRegExp rx(QLatin1String("<[^<>]*>"));
+    const int offset = rx.indexIn(insertWord) - 1; // put cursor at the first option
+#endif
 	insertWord.replace(rx, s_completionPlaceHolder);
 
 	cursor.insertText(insertWord);
@@ -774,7 +783,7 @@ int TikzEditor::lineNumberAreaWidth()
 		++digits;
 	digits = qMax(4, digits) + 1;
 
-	return m_showLineNumberArea ? 3 + fontMetrics().width(QLatin1Char('9')) * digits : 0;
+    return m_showLineNumberArea ? 3 + fontMetrics().horizontalAdvance(QLatin1Char('9')) * digits : 0;
 }
 
 void TikzEditor::updateLineNumberAreaWidth()
--- ktikz-0.13.2+ds1.orig/app/tikzeditorhighlighter.cpp
+++ ktikz-0.13.2+ds1/app/tikzeditorhighlighter.cpp
@@ -53,13 +53,13 @@ void TikzHighlighter::setHighlightingRul
 	Q_FOREACH (const QString &pattern, keywordPatterns)
 	{
 		rule.type = highlightTypeNames.at(currentIndex);
-		rule.pattern = QRegExp(pattern);
+        rule.pattern = QRegExp(pattern);
 		rule.isRegExp = true;
 		m_highlightingRules.append(rule);
 	}
 	// comments
 	rule.type = highlightTypeNames.at(currentIndex + 1);
-	rule.pattern = QRegExp(QLatin1String("%[^\n]*"));
+    rule.pattern = QRegExp(QLatin1String("%[^\n]*"));
 	rule.isRegExp = true;
 	m_highlightingRules.append(rule);
 
--- ktikz-0.13.2+ds1.orig/app/tikzeditorhighlighter.h
+++ ktikz-0.13.2+ds1/app/tikzeditorhighlighter.h
@@ -22,12 +22,15 @@
 #define TIKZEDITORHIGHLIGHTER_H
 
 #include <QtGui/QSyntaxHighlighter>
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+#include <QtCore5Compat/QRegExp>
+#endif
 
 struct HighlightingRule
 {
 	QString type; /// The name of the formatting type
 	QString matchString; /// The string to match for formatting; only used when pattern is empty
-	QRegExp pattern; /// The pattern to match for formatting; overrides usage of matchString
+    QRegExp pattern; /// The pattern to match for formatting
 	bool isRegExp;
 };
 
--- ktikz-0.13.2+ds1.orig/app/tikzeditorview.cpp
+++ ktikz-0.13.2+ds1/app/tikzeditorview.cpp
@@ -65,7 +65,11 @@ TikzEditorView::TikzEditorView(QWidget *
 
 	QVBoxLayout *mainLayout = new QVBoxLayout(this);
 	mainLayout->setSpacing(0);
-	mainLayout->setMargin(0);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    mainLayout->setContentsMargins(0, 0, 0, 0);
+#else
+    mainLayout->setMargin(0);
+#endif
 	mainLayout->addWidget(m_tikzEditor);
 
 	createActions();
@@ -147,7 +151,11 @@ void TikzEditorView::setFont(const QFont
 	fm.setFontPointSize(editorFont.pointSize());
 	m_tikzEditor->setCurrentCharFormat(fm);
 
-	m_tikzEditor->setTabStopWidth(m_tikzEditor->fontMetrics().width(QLatin1String("    ")));
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    m_tikzEditor->setTabStopDistance(m_tikzEditor->fontMetrics().horizontalAdvance(QLatin1String("    ")));
+#else
+    m_tikzEditor->setTabStopWidth(m_tikzEditor->fontMetrics().width(QLatin1String("    ")));
+#endif
 }
 
 void TikzEditorView::createActions()
--- ktikz-0.13.2+ds1.orig/app/tikzeditorview.h
+++ ktikz-0.13.2+ds1/app/tikzeditorview.h
@@ -92,10 +92,10 @@ private Q_SLOTS:
 	void editReplace();
 	void tabIndent(bool isUnindenting = false);
 	void indent(QChar insertChar, int numOfInserts, bool isUnindenting = false);
-	bool search(const QString &text, QTextDocument::FindFlags flags = 0, bool startAtCursor = true, bool continueFromBeginning = false);
+    bool search(const QString &text, QTextDocument::FindFlags flags = (QTextDocument::FindFlags)0, bool startAtCursor = true, bool continueFromBeginning = false);
 	void search();
 	void replace(const QString &replacement);
-	void replace(const QString &text, const QString &replacement, QTextDocument::FindFlags flags = 0, bool startAtCursor = true);
+    void replace(const QString &text, const QString &replacement, QTextDocument::FindFlags flags = (QTextDocument::FindFlags)0, bool startAtCursor = true);
 	void replace();
 	void replaceAll();
 
--- ktikz-0.13.2+ds1.orig/app/usercommandeditdialog.cpp
+++ ktikz-0.13.2+ds1/app/usercommandeditdialog.cpp
@@ -20,7 +20,7 @@
 
 #include <QtCore/QSettings>
 
-static const QString s_completionPlaceHolder(0x2022);
+static const QString s_completionPlaceHolder(QChar(0x2022));
 
 UserCommandEditDialog::UserCommandEditDialog(QWidget *parent)
 	: QDialog(parent),
--- ktikz-0.13.2+ds1.orig/app/usercommandinserter.cpp
+++ ktikz-0.13.2+ds1/app/usercommandinserter.cpp
@@ -29,7 +29,7 @@
 #include "tikzcommandinserter.h"
 #include "usercommandeditdialog.h"
 
-static const QString s_completionPlaceHolder(0x2022);
+static const QString s_completionPlaceHolder(QChar(0x2022));
 
 UserCommandInserter::UserCommandInserter(QWidget *parent)
 	: QObject(parent)
--- ktikz-0.13.2+ds1.orig/common/common.pri
+++ ktikz-0.13.2+ds1/common/common.pri
@@ -1,6 +1,8 @@
 greaterThan(QT_MAJOR_VERSION, 4): QT *= widgets printsupport
+greaterThan(QT_MAJOR_VERSION, 6): QT *= core5compat pdf
 
-include($${_PRO_FILE_PWD_}/qmake/findpoppler.pri)
+
+#include($${_PRO_FILE_PWD_}/qmake/findpoppler.pri)
 
 DEFINES += KTIKZ_TEMPLATES_INSTALL_DIR=\\\"$${TEMPLATES_INSTALL_DIR}\\\"
 
--- ktikz-0.13.2+ds1.orig/common/tikzpreview.cpp
+++ ktikz-0.13.2+ds1/common/tikzpreview.cpp
@@ -69,7 +69,11 @@ TikzPreview::TikzPreview(QWidget *parent
 	createActions();
 
 	m_tikzPreviewRenderer = new TikzPreviewRenderer();
-	connect(this, SIGNAL(generatePreview(Poppler::Document*,qreal,int)), m_tikzPreviewRenderer, SLOT(generatePreview(Poppler::Document*,qreal,int)));
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    connect(this, SIGNAL(generatePreview(QPdfDocument*,qreal,int)), m_tikzPreviewRenderer, SLOT(generatePreview(QPdfDocument*,qreal,int)));
+#else
+    connect(this, SIGNAL(generatePreview(Poppler::Document*,qreal,int)), m_tikzPreviewRenderer, SLOT(generatePreview(Poppler::Document*,qreal,int)));
+#endif
 	connect(m_tikzPreviewRenderer, SIGNAL(showPreview(QImage,qreal)), this, SLOT(showPreview(QImage,qreal)));
 }
 
@@ -95,7 +99,11 @@ void TikzPreview::contextMenuEvent(QCont
 
 QSize TikzPreview::sizeHint() const
 {
-	const int screenWidth = QApplication::desktop()->availableGeometry().width();
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const int screenWidth = QApplication::primaryScreen()->availableGeometry().width();
+#else
+    const int screenWidth = QApplication::desktop()->availableGeometry().width();
+#endif
 	if (screenWidth > 1200)
 		return QSize(500, 400);
 	else if (screenWidth > 1024)
@@ -210,16 +218,28 @@ void TikzPreview::showPreviousPage()
 	if (m_currentPage > 0)
 		--m_currentPage;
 	m_previousPageAction->setEnabled(m_currentPage > 0);
-	m_nextPageAction->setEnabled(m_currentPage < m_tikzPdfDoc->numPages() - 1);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    m_nextPageAction->setEnabled(m_currentPage < m_tikzPdfDoc->pageCount() - 1);
+#else
+    m_nextPageAction->setEnabled(m_currentPage < m_tikzPdfDoc->numPages() - 1);
+#endif
 	showPdfPage();
 }
 
 void TikzPreview::showNextPage()
 {
-	if (m_currentPage < m_tikzPdfDoc->numPages() - 1)
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    if (m_currentPage < m_tikzPdfDoc->pageCount() - 1)
+#else
+    if (m_currentPage < m_tikzPdfDoc->numPages() - 1)
+#endif
 		++m_currentPage;
 	m_previousPageAction->setEnabled(m_currentPage > 0);
-	m_nextPageAction->setEnabled(m_currentPage < m_tikzPdfDoc->numPages() - 1);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    m_nextPageAction->setEnabled(m_currentPage < m_tikzPdfDoc->pageCount() - 1);
+#else
+    m_nextPageAction->setEnabled(m_currentPage < m_tikzPdfDoc->numPages() - 1);
+#endif
 	showPdfPage();
 }
 
@@ -246,11 +266,19 @@ void TikzPreview::showPreview(const QIma
 
 void TikzPreview::showPdfPage()
 {
-	if (!m_tikzPdfDoc || m_tikzPdfDoc->numPages() < 1)
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    if (!m_tikzPdfDoc || m_tikzPdfDoc->pageCount() < 1)
+#else
+    if (!m_tikzPdfDoc || m_tikzPdfDoc->numPages() < 1)
+#endif
+    {
 		return;
+    }
 
 	if (!m_processRunning)
+    {
 		Q_EMIT generatePreview(m_tikzPdfDoc, m_zoomFactor, m_currentPage); // render the current pdf page to a QImage in TikzPreviewRenderer (in a different thread)
+    }
 }
 
 void TikzPreview::emptyPreview()
@@ -268,7 +296,11 @@ void TikzPreview::emptyPreview()
 	m_nextPageAction->setVisible(false);
 }
 
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+void TikzPreview::pixmapUpdated(QPdfDocument *tikzPdfDoc, const QList<qreal> &tikzCoordinates)
+#else
 void TikzPreview::pixmapUpdated(Poppler::Document *tikzPdfDoc, const QList<qreal> &tikzCoordinates)
+#endif
 {
 	m_tikzPdfDoc = tikzPdfDoc;
 	m_tikzCoordinates = tikzCoordinates;
@@ -279,11 +311,15 @@ void TikzPreview::pixmapUpdated(Poppler:
 		return;
 	}
 
-	m_tikzPdfDoc->setRenderBackend(Poppler::Document::SplashBackend);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const int numOfPages = m_tikzPdfDoc->pageCount();
+#else
+    m_tikzPdfDoc->setRenderBackend(Poppler::Document::SplashBackend);
 //	m_tikzPdfDoc->setRenderBackend(Poppler::Document::ArthurBackend);
-	m_tikzPdfDoc->setRenderHint(Poppler::Document::Antialiasing, true);
-	m_tikzPdfDoc->setRenderHint(Poppler::Document::TextAntialiasing, true);
-	const int numOfPages = m_tikzPdfDoc->numPages();
+    m_tikzPdfDoc->setRenderHint(Poppler::Document::Antialiasing, true);
+    m_tikzPdfDoc->setRenderHint(Poppler::Document::TextAntialiasing, true);
+    const int numOfPages = m_tikzPdfDoc->numPages();
+#endif
 
 	const bool visible = (numOfPages > 1);
 	if (m_pageSeparator)
@@ -305,13 +341,17 @@ void TikzPreview::pixmapUpdated(Poppler:
 
 QImage TikzPreview::renderToImage(double xres, double yres, int pageNumber)
 {
-	Poppler::Page *page = m_tikzPdfDoc->page(pageNumber);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    const QImage image = m_tikzPdfDoc->render(pageNumber, QSize(xres, yres));
+#else
+    Poppler::Page *page = m_tikzPdfDoc->page(pageNumber);
 //	const QSizeF pageSize = page->pageSizeF();
 //	const QImage image = pageSize.height() >= pageSize.width()
 //		? page->renderToImage(xres, yres)
 //		: page->renderToImage(xres, yres, -1, -1, -1, -1, Poppler::Page::Rotate270); // slow
-	const QImage image = page->renderToImage(xres, yres); // slow
-	delete page;
+    const QImage image = page->renderToImage(xres, yres); // slow
+    delete page;
+#endif
 	return image;
 }
 
@@ -327,7 +367,11 @@ int TikzPreview::currentPage() const
 
 int TikzPreview::numberOfPages() const
 {
-	return m_tikzPdfDoc->numPages();
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    return m_tikzPdfDoc->pageCount();
+#else
+    return m_tikzPdfDoc->numPages();
+#endif
 }
 
 /***************************************************************************/
@@ -393,7 +437,11 @@ void TikzPreview::wheelEvent(QWheelEvent
 {
 	if (event->modifiers() == Qt::ControlModifier)
 	{
-		if (event->delta() > 0)
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+        if (event->angleDelta().y() > 0)
+#else
+        if (event->delta() > 0)
+#endif
 			zoomIn();
 		else
 			zoomOut();
--- ktikz-0.13.2+ds1.orig/common/tikzpreview.h
+++ ktikz-0.13.2+ds1/common/tikzpreview.h
@@ -29,10 +29,14 @@
 
 class QToolBar;
 
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+class QPdfDocument;
+#else
 namespace Poppler
 {
 class Document;
 }
+#endif
 
 class Action;
 class ZoomAction;
@@ -62,12 +66,20 @@ public:
 
 public Q_SLOTS:
 	void showPreview(const QImage &tikzImage, qreal zoomFactor = 1.0);
-	void pixmapUpdated(Poppler::Document *tikzPdfDoc, const QList<qreal> &tikzCoordinates = QList<qreal>());
-	void showErrorMessage(const QString &message);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    void pixmapUpdated(QPdfDocument *tikzPdfDoc, const QList<qreal> &tikzCoordinates = QList<qreal>());
+#else
+    void pixmapUpdated(Poppler::Document *tikzPdfDoc, const QList<qreal> &tikzCoordinates = QList<qreal>());
+#endif
+    void showErrorMessage(const QString &message);
 
 Q_SIGNALS:
 	void showMouseCoordinates(qreal x, qreal y, int precisionX = 5, int precisionY = 5);
-	void generatePreview(Poppler::Document *tikzPdfDoc, qreal zoomFactor, int currentPage);
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    void generatePreview(QPdfDocument *tikzPdfDoc, qreal zoomFactor, int currentPage);
+#else
+    void generatePreview(Poppler::Document *tikzPdfDoc, qreal zoomFactor, int currentPage);
+#endif
 
 protected:
 	void contextMenuEvent(QContextMenuEvent *event);
@@ -104,7 +116,11 @@ private:
 
 	TikzPreviewMessageWidget *m_infoWidget;
 
-	Poppler::Document *m_tikzPdfDoc;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    QPdfDocument *m_tikzPdfDoc;
+#else
+    Poppler::Document *m_tikzPdfDoc;
+#endif
 	int m_currentPage;
 	qreal m_zoomFactor;
 	qreal m_oldZoomFactor;
--- ktikz-0.13.2+ds1.orig/common/tikzpreviewcontroller.cpp
+++ ktikz-0.13.2+ds1/common/tikzpreviewcontroller.cpp
@@ -74,8 +74,13 @@ TikzPreviewController::TikzPreviewContro
 	createActions();
 
 	qRegisterMetaType<QList<qreal> >("QList<qreal>");
-	connect(m_tikzPreviewGenerator, SIGNAL(pixmapUpdated(Poppler::Document*,QList<qreal>)),
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    connect(m_tikzPreviewGenerator, SIGNAL(pixmapUpdated(QPdfDocument*,QList<qreal>)),
+            m_tikzPreview, SLOT(pixmapUpdated(QPdfDocument*,QList<qreal>)));
+#else
+    connect(m_tikzPreviewGenerator, SIGNAL(pixmapUpdated(Poppler::Document*,QList<qreal>)),
 	        m_tikzPreview, SLOT(pixmapUpdated(Poppler::Document*,QList<qreal>)));
+#endif
 	connect(m_tikzPreviewGenerator, SIGNAL(showErrorMessage(QString)),
 	        m_tikzPreview, SLOT(showErrorMessage(QString)));
 	connect(m_tikzPreviewGenerator, SIGNAL(setExportActionsEnabled(bool)),
--- ktikz-0.13.2+ds1.orig/common/tikzpreviewgenerator.cpp
+++ ktikz-0.13.2+ds1/common/tikzpreviewgenerator.cpp
@@ -35,6 +35,8 @@
 #include <QtWidgets/QPlainTextEdit>
 #if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
 #include <QtPdf/QtPdf>
+#include <QtCore5Compat/QRegExp>
+#include <iostream>
 #else
 #include <poppler-qt5.h>
 #endif
@@ -184,7 +186,7 @@ static QString getParsedLogText(QTextStr
 {
 	QString logText;
 
-	QRegExp errorPattern(QLatin1String("(\\S*):(\\d+): (.*$)"));
+    QRegExp errorPattern(QLatin1String("(\\S*):(\\d+): (.*$)"));
 	QList<QLatin1String> errorMessageList;
 	errorMessageList << QLatin1String("Undefined control sequence")
 	                 << QLatin1String("LaTeX Warning:") << QLatin1String("LaTeX Error:")
@@ -203,7 +205,7 @@ static QString getParsedLogText(QTextStr
 			logText += QLatin1String("[LaTeX] Line ") + lineNum + QLatin1String(": ") + errorMsg;
 
 			// while we don't get a line starting with "l.<number> ...", we have to add the line to the first error message
-			QRegExp rx(QLatin1String("^l\\.(\\d+)(.*)"));
+            QRegExp  rx(QLatin1String("^l\\.(\\d+)(.*)"));
 			logLine = logStream->readLine();
 			while (rx.indexIn(logLine) < 0 && !logStream->atEnd())
 			{
@@ -350,8 +352,13 @@ void TikzPreviewGenerator::createPreview
 			// Update widget
 			if (m_tikzPdfDoc)
 				delete m_tikzPdfDoc;
-			m_tikzPdfDoc = Poppler::Document::load(tikzPdfFileInfo.absoluteFilePath());
-			if (m_tikzPdfDoc)
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+            m_tikzPdfDoc = new QPdfDocument();
+            if (m_tikzPdfDoc->load(tikzPdfFileInfo.absoluteFilePath()) == QPdfDocument::NoError)
+#else
+            m_tikzPdfDoc = Poppler::Document::load(tikzPdfFileInfo.absoluteFilePath());
+            if (m_tikzPdfDoc)
+#endif
 			{
 				m_shortLogText = QLatin1String("[LaTeX] ") + tr("Process finished successfully.", "info process");
 				Q_EMIT pixmapUpdated(m_tikzPdfDoc, tikzCoordinates(m_tikzFileBaseName));
@@ -512,7 +519,7 @@ static QString createTempTikzFile(const
 	QTextStream tikzStream(&tikzFile);
 	codecProfile->configureStreamEncoding(tikzStream);
 
-	tikzStream << tikzCode << endl;
+    tikzStream << tikzCode << QLatin1String("\n");
 	tikzStream.flush();
 
 	tikzFile.close();
--- ktikz-0.13.2+ds1.orig/common/tikzpreviewgenerator.h
+++ ktikz-0.13.2+ds1/common/tikzpreviewgenerator.h
@@ -33,11 +33,14 @@ class QProcess;
 class QPlainEdit;
 class QTextStream;
 
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+class QPdfDocument;
+#else
 namespace Poppler
 {
 class Document;
 }
-
+#endif
 class TikzPreviewController;
 
 /**
@@ -75,7 +78,11 @@ public Q_SLOTS:
 	void abortProcess();
 
 Q_SIGNALS:
-	void pixmapUpdated(Poppler::Document *tikzPdfDoc, const QList<qreal> &tikzCoordinates = QList<qreal>());
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    void pixmapUpdated(QPdfDocument *tikzPdfDoc, const QList<qreal> &tikzCoordinates = QList<qreal>());
+#else
+    void pixmapUpdated(Poppler::Document *tikzPdfDoc, const QList<qreal> &tikzCoordinates = QList<qreal>());
+#endif
 	void setExportActionsEnabled(bool enabled);
 	void showErrorMessage(const QString &message);
 	void updateLog(const QString &logText, bool runFailed);
@@ -97,7 +104,11 @@ protected:
 	bool generatePdfFile(const QString &tikzFileBaseName, const QString &latexCommand, bool useShellEscaping);
 
 	TikzPreviewController *m_parent;
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+    QPdfDocument *m_tikzPdfDoc;
+#else
 	Poppler::Document *m_tikzPdfDoc;
+#endif
 	QString m_tikzCode;
 
 	QThread m_thread;
--- ktikz-0.13.2+ds1.orig/common/tikzpreviewrenderer.cpp
+++ ktikz-0.13.2+ds1/common/tikzpreviewrenderer.cpp
@@ -42,11 +42,20 @@ TikzPreviewRenderer::~TikzPreviewRendere
 	}
 }
 
-void TikzPreviewRenderer::generatePreview(Poppler::Document *tikzPdfDoc, qreal zoomFactor, int currentPage)
+#if QT_VERSION >= QT_VERSION_CHECK(6, 3, 0)
+void TikzPreviewRenderer::generatePreview(QPdfDocument *tikzPdfDoc, qreal zoomFactor, int currentPage)
 {
-	Poppler::Page *pdfPage = tikzPdfDoc->page(currentPage);
-	const QImage tikzImage = pdfPage->renderToImage(zoomFactor * 72, zoomFactor * 72);
-	delete pdfPage;
+    const QImage tikzImage = tikzPdfDoc->render(currentPage, QSize(zoomFactor * 72, zoomFactor * 72));
 
 	Q_EMIT showPreview(tikzImage, zoomFactor);
 }
+#else
+void TikzPreviewRenderer::generatePreview(Poppler::Document *tikzPdfDoc, qreal zoomFactor, int currentPage)
+{
+    Poppler::Page *pdfPage = tikzPdfDoc->page(currentPage);
+    const QImage tikzImage = pdfPage->renderToImage(zoomFactor * 72, zoomFactor * 72);
+    delete pdfPage;
+
+    Q_EMIT showPreview(tikzImage, zoomFactor);
+}
+#endif
--- ktikz-0.13.2+ds1.orig/qmake/qtikzconfig.pri
+++ ktikz-0.13.2+ds1/qmake/qtikzconfig.pri
@@ -40,10 +40,10 @@
 #MAN_INSTALL_DIR = $${PREFIX}/share/man
 
 # compile in debug mode:
-#CONFIG += debug
+CONFIG += debug
 # compile in release mode:
-CONFIG -= debug
-CONFIG += release
+#CONFIG -= debug
+#CONFIG += release
 
 # Qt commands (uncomment if needed)
 # qmake command:
--- ktikz-0.13.2+ds1.orig/qmake/qtikzmacros.pri
+++ ktikz-0.13.2+ds1/qmake/qtikzmacros.pri
@@ -4,15 +4,15 @@ unix:!macx {
 #	QMAKE_CXXFLAGS += `pkg-config --cflags poppler-qt4`
 #	QMAKE_LFLAGS += `pkg-config --libs poppler-qt4` # using this, qmake adds 3 times "--libs" to the LFLAGS, which is not recognized by g++ 4.6
 	PKG_CONFIG = $$pkgConfigExecutable()
-	greaterThan(QT_MAJOR_VERSION, 4) {
-		POPPLERINCLUDES = $$system($$PKG_CONFIG --cflags poppler-qt5)
-		POPPLERLIBS = $$system($$PKG_CONFIG --libs poppler-qt5)
-	} else {
-		POPPLERINCLUDES = $$system($$PKG_CONFIG --cflags poppler-qt4)
-		POPPLERLIBS = $$system($$PKG_CONFIG --libs poppler-qt4)
-	}
-	QMAKE_CXXFLAGS += $$POPPLERINCLUDES
-	QMAKE_LFLAGS += $$POPPLERLIBS
+#	greaterThan(QT_MAJOR_VERSION, 4) {
+#		POPPLERINCLUDES = $$system($$PKG_CONFIG --cflags poppler-qt5)
+#		POPPLERLIBS = $$system($$PKG_CONFIG --libs poppler-qt5)
+#	} else {
+#		POPPLERINCLUDES = $$system($$PKG_CONFIG --cflags poppler-qt4)
+#		POPPLERLIBS = $$system($$PKG_CONFIG --libs poppler-qt4)
+#	}
+#	QMAKE_CXXFLAGS += $$POPPLERINCLUDES
+#	QMAKE_LFLAGS += $$POPPLERLIBS
 }
 
 # Functions
--- /dev/null
+++ ktikz-0.13.2+ds1/qtikz.pro.user
@@ -0,0 +1,270 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE QtCreatorProject>
+<!-- Written by QtCreator 7.0.1, 2022-05-06T21:09:51. -->
+<qtcreator>
+ <data>
+  <variable>EnvironmentId</variable>
+  <value type="QByteArray">{e92ae61b-ee59-4440-808d-f6274b00be67}</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.ActiveTarget</variable>
+  <value type="qlonglong">0</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.EditorSettings</variable>
+  <valuemap type="QVariantMap">
+   <value type="bool" key="EditorConfiguration.AutoIndent">true</value>
+   <value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
+   <value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
+    <value type="QString" key="language">Cpp</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">CppGlobal</value>
+    </valuemap>
+   </valuemap>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
+    <value type="QString" key="language">QmlJS</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
+    </valuemap>
+   </valuemap>
+   <value type="qlonglong" key="EditorConfiguration.CodeStyle.Count">2</value>
+   <value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
+   <value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
+   <value type="int" key="EditorConfiguration.IndentSize">4</value>
+   <value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
+   <value type="int" key="EditorConfiguration.MarginColumn">80</value>
+   <value type="bool" key="EditorConfiguration.MouseHiding">true</value>
+   <value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
+   <value type="int" key="EditorConfiguration.PaddingMode">1</value>
+   <value type="bool" key="EditorConfiguration.PreferSingleLineComments">false</value>
+   <value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
+   <value type="bool" key="EditorConfiguration.ShowMargin">false</value>
+   <value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
+   <value type="bool" key="EditorConfiguration.SmartSelectionChanging">true</value>
+   <value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
+   <value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
+   <value type="int" key="EditorConfiguration.TabSize">8</value>
+   <value type="bool" key="EditorConfiguration.UseGlobal">true</value>
+   <value type="bool" key="EditorConfiguration.UseIndenter">false</value>
+   <value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
+   <value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
+   <value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
+   <value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
+   <value type="QString" key="EditorConfiguration.ignoreFileTypes">*.md, *.MD, Makefile</value>
+   <value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
+   <value type="bool" key="EditorConfiguration.skipTrailingWhitespace">true</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.PluginSettings</variable>
+  <valuemap type="QVariantMap">
+   <valuemap type="QVariantMap" key="AutoTest.ActiveFrameworks">
+    <value type="bool" key="AutoTest.Framework.Boost">true</value>
+    <value type="bool" key="AutoTest.Framework.CTest">false</value>
+    <value type="bool" key="AutoTest.Framework.Catch">true</value>
+    <value type="bool" key="AutoTest.Framework.GTest">true</value>
+    <value type="bool" key="AutoTest.Framework.QtQuickTest">true</value>
+    <value type="bool" key="AutoTest.Framework.QtTest">true</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="AutoTest.CheckStates"/>
+   <value type="int" key="AutoTest.RunAfterBuild">0</value>
+   <value type="bool" key="AutoTest.UseGlobal">true</value>
+   <valuelist type="QVariantList" key="ClangCodeModel.CustomCommandLineKey"/>
+   <value type="bool" key="ClangCodeModel.UseGlobalConfig">true</value>
+   <value type="QString" key="ClangCodeModel.WarningConfigId">Builtin.BuildSystem</value>
+   <valuemap type="QVariantMap" key="ClangTools">
+    <value type="bool" key="ClangTools.AnalyzeOpenFiles">true</value>
+    <value type="bool" key="ClangTools.BuildBeforeAnalysis">true</value>
+    <value type="QString" key="ClangTools.DiagnosticConfig">Builtin.DefaultTidyAndClazy</value>
+    <value type="int" key="ClangTools.ParallelJobs">4</value>
+    <valuelist type="QVariantList" key="ClangTools.SelectedDirs"/>
+    <valuelist type="QVariantList" key="ClangTools.SelectedFiles"/>
+    <valuelist type="QVariantList" key="ClangTools.SuppressedDiagnostics"/>
+    <value type="bool" key="ClangTools.UseGlobalSettings">true</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="CppEditor.QuickFix">
+    <value type="bool" key="UseGlobalSettings">true</value>
+   </valuemap>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.0</variable>
+  <valuemap type="QVariantMap">
+   <value type="QString" key="DeviceType">Desktop</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 6.3.0 GCC 64bit</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 6.3.0 GCC 64bit</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.qt6.630.gcc_64_kit</value>
+   <value type="qlonglong" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
+   <value type="qlonglong" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
+   <value type="qlonglong" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
+    <value type="int" key="EnableQmlDebugging">0</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Debug</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Debug</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+     </valuemap>
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+     </valuemap>
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.CustomParsers"/>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ParseStandardOutput">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges">
+     <value type="QString">PATH=/home/anovitsk/Qt/6.3.0/gcc_64/bin:/home/anovitsk/Qt/Tools/QtDesignStudio/qt5_design_studio_reduced_version/bin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib:/mnt/c/Users/anovitsk/AppData/Roaming/MobaXterm/slash/bin:/mnt/c/windows/:/mnt/c/windows/system32/:/mnt/c/windows/system32:/mnt/c/windows:/mnt/c/windows/System32/Wbem:/mnt/c/windows/System32/WindowsPowerShell/v1.0/:/mnt/c/Users/anovitsk/AppData/Local/Microsoft/WindowsApps:/mnt/c/windows/sysnative/:/snap/bin</value>
+    </valuelist>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Debug</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Release</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Release</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+     </valuemap>
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+     </valuemap>
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.CustomParsers"/>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ParseStandardOutput">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="int" key="QtQuickCompiler">0</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
+    <value type="int" key="EnableQmlDebugging">0</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Profile</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Profile</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+     </valuemap>
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+     </valuemap>
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.CustomParsers"/>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ParseStandardOutput">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Profile</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="int" key="QtQuickCompiler">0</value>
+    <value type="int" key="SeparateDebugInfo">0</value>
+   </valuemap>
+   <value type="qlonglong" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <value type="qlonglong" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.DeployConfiguration.CustomData"/>
+    <value type="bool" key="ProjectExplorer.DeployConfiguration.CustomDataEnabled">false</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
+   </valuemap>
+   <value type="qlonglong" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
+    <value type="bool" key="Analyzer.Perf.Settings.UseGlobalSettings">true</value>
+    <value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
+    <value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
+    <valuelist type="QVariantList" key="CustomOutputParsers"/>
+    <value type="int" key="PE.EnvironmentAspect.Base">2</value>
+    <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:/home/anovitsk/Projects/KTikz/qtikz.pro</value>
+    <value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey">/home/anovitsk/Projects/KTikz/qtikz.pro</value>
+    <value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
+    <value type="bool" key="RunConfiguration.UseLibrarySearchPath">true</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
+    <value type="QString" key="RunConfiguration.WorkingDirectory.default">/home/anovitsk/Projects/build-qtikz-Desktop_Qt_6_3_0_GCC_64bit-Debug</value>
+   </valuemap>
+   <value type="qlonglong" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.TargetCount</variable>
+  <value type="qlonglong">1</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
+  <value type="int">22</value>
+ </data>
+ <data>
+  <variable>Version</variable>
+  <value type="int">22</value>
+ </data>
+</qtcreator>
