[rkward/frameworks] /: Hooray: KDELibs4Support-free, now. (Modulo the TODOs to be addressed, and bugs to be fixed)

Thomas Friedrichsmeier thomas.friedrichsmeier at ruhr-uni-bochum.de
Sat Feb 13 20:58:31 UTC 2016


Git commit 2347eb866c233d5b8ce63a56eb6beb8d91192981 by Thomas Friedrichsmeier.
Committed on 13/02/2016 at 20:57.
Pushed by tfry into branch 'frameworks'.

Hooray: KDELibs4Support-free, now. (Modulo the TODOs to be addressed, and bugs to be fixed)

M  +2    -2    CMakeLists.txt
M  +1    -1    rkward/CMakeLists.txt
M  +1    -0    rkward/agents/rkloadagent.cpp
M  +2    -2    rkward/dataeditor/twintable.cpp
M  +1    -1    rkward/dialogs/rkerrordialog.cpp
M  +2    -1    rkward/dialogs/rkloadlibsdialog.cpp
M  +9    -9    rkward/main.cpp
M  +1    -0    rkward/misc/CMakeLists.txt
M  +2    -2    rkward/misc/rkaccordiontable.cpp
A  +34   -0    rkward/misc/rkdialogbuttonbox.cpp     [License: GPL (v2+)]
A  +29   -0    rkward/misc/rkdialogbuttonbox.h     [License: GPL (v2+)]
M  +1    -1    rkward/misc/rkmessagecatalog.cpp
M  +5    -3    rkward/plugin/rkoptionset.cpp
M  +1    -0    rkward/plugin/rkoptionset.h
M  +1    -1    rkward/plugin/rkpreviewbox.cpp
M  +2    -2    rkward/plugin/rkvarslot.cpp
M  +1    -1    rkward/rbackend/rinterface.cpp
M  +5    -5    rkward/rbackend/rkrbackendprotocol_backend.cpp
M  +2    -1    rkward/rbackend/rksessionvars.cpp
M  +32   -13   rkward/rkconsole.cpp
M  +23   -18   rkward/rkward.cpp
M  +10   -3    rkward/rkward_startup_wrapper.cpp
M  +4    -3    rkward/settings/rksettingsmoduleobjectbrowser.cpp
M  +2    -1    rkward/settings/rksettingsmoduleplugins.cpp
M  +4    -3    rkward/settings/rksettingsmoduler.cpp
M  +2    -2    rkward/windows/rcontrolwindow.cpp
M  +3    -3    rkward/windows/rkcallstackviewer.cpp
M  +3    -2    rkward/windows/rkcommandeditorwindow.cpp
M  +2    -1    rkward/windows/rkhelpsearchwindow.cpp
M  +2    -1    rkward/windows/rkwindowcatcher.cpp
M  +0    -2    rkward/windows/rkworkplace.cpp
M  +3    -3    rkward/windows/robjectbrowser.cpp

http://commits.kde.org/rkward/2347eb866c233d5b8ce63a56eb6beb8d91192981

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 998e015..a9e0410 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -16,8 +16,8 @@ INCLUDE(KDECompilerSettings)
 INCLUDE(ECMInstallIcons)
 INCLUDE(FeatureSummary)
 
-FIND_PACKAGE(Qt5 5.2 CONFIG REQUIRED COMPONENTS Widgets Core Xml Network WebKit Script)
-FIND_PACKAGE(KF5 5.0 REQUIRED COMPONENTS CoreAddons DocTools I18n XmlGui TextEditor WidgetsAddons KDELibs4Support WebKit Parts Config)
+FIND_PACKAGE(Qt5 5.2 CONFIG REQUIRED COMPONENTS Widgets Core Xml Network WebKit Script PrintSupport)
+FIND_PACKAGE(KF5 5.0 REQUIRED COMPONENTS CoreAddons DocTools I18n XmlGui TextEditor WidgetsAddons WebKit Parts Config Notifications WindowSystem)
 
 IF(FORCE_PRETTY_MAKEFILE)
 	SET(CMAKE_VERBOSE_MAKEFILE OFF)
diff --git a/rkward/CMakeLists.txt b/rkward/CMakeLists.txt
index e981fce..a3b8408 100644
--- a/rkward/CMakeLists.txt
+++ b/rkward/CMakeLists.txt
@@ -59,7 +59,7 @@ IF(Q_WS_MAC)
 		@ONLY)
 ENDIF(Q_WS_MAC)
 
-TARGET_LINK_LIBRARIES(rkward.frontend  windows ${RKWARD_ADDLIBS} agents dialogs plugin settings dataeditor core scriptbackends rbackend misc KF5::WindowSystem Qt5::Widgets KF5::XmlGui ${GETTEXT_LIBRARIES} KF5::KDELibs4Support)
+TARGET_LINK_LIBRARIES(rkward.frontend  windows ${RKWARD_ADDLIBS} agents dialogs plugin settings dataeditor core scriptbackends rbackend misc KF5::WindowSystem Qt5::Widgets KF5::XmlGui ${GETTEXT_LIBRARIES})
 
 # wrapper executable
 GET_DIRECTORY_PROPERTY(R_EXECUTABLE DIRECTORY rbackend DEFINITION R_EXECUTABLE)
diff --git a/rkward/agents/rkloadagent.cpp b/rkward/agents/rkloadagent.cpp
index e560613..0cafe55 100644
--- a/rkward/agents/rkloadagent.cpp
+++ b/rkward/agents/rkloadagent.cpp
@@ -55,6 +55,7 @@ RKLoadAgent::RKLoadAgent (const QUrl &url, bool merge) {
 			getjob->ui ()->showErrorMessage();
 			return;
 		}
+		filename = tmpfile->fileName ();
 	} else {
 		filename = url.toLocalFile ();
 	}
diff --git a/rkward/dataeditor/twintable.cpp b/rkward/dataeditor/twintable.cpp
index b64849b..48d4298 100644
--- a/rkward/dataeditor/twintable.cpp
+++ b/rkward/dataeditor/twintable.cpp
@@ -53,12 +53,12 @@ TwinTable::TwinTable (QWidget *parent) : RKEditor (parent), RObjectListener (ROb
 
 	metaview = new TwinTableMember (splitter);
 	splitter->setStretchFactor (splitter->indexOf (metaview), 0);
-	metaview->verticalHeader ()->setResizeMode (QHeaderView::Fixed);
+	metaview->verticalHeader ()->setSectionResizeMode (QHeaderView::Fixed);
 	metaview->setHorizontalScrollBarPolicy (Qt::ScrollBarAlwaysOff);
 	
 	dataview = new TwinTableMember (splitter);
 	splitter->setStretchFactor (splitter->indexOf (dataview), 1);
-	dataview->verticalHeader ()->setResizeMode (QHeaderView::Fixed);
+	dataview->verticalHeader ()->setSectionResizeMode (QHeaderView::Fixed);
 	dataview->horizontalHeader ()->hide ();
 	dataview->setAlternatingRowColors (true);
 
diff --git a/rkward/dialogs/rkerrordialog.cpp b/rkward/dialogs/rkerrordialog.cpp
index 285143d..a44ac61 100644
--- a/rkward/dialogs/rkerrordialog.cpp
+++ b/rkward/dialogs/rkerrordialog.cpp
@@ -86,7 +86,7 @@ public:
 		out << "<input name=\"product\" type=\"hidden\" value=\"rkward\"/>\n";
 		out << "<input name=\"component\" type=\"hidden\" value=\"general\"/>\n";
 		out << "<input name=\"version\" type=\"hidden\" value=\"" RKWARD_VERSION "\"/>\n";
-		out << "<input name=\"comment\" type=\"hidden\" value=\"" << Qt::escape (report_template) << "\"/>\n";
+		out << "<input name=\"comment\" type=\"hidden\" value=\"" << report_template.toHtmlEscaped () << "\"/>\n";
 		out << "<input type=\"submit\" value=\"" << i18n ("Proceed") << "\"/>\n";
 		out << "</form></body></html>";
 		proxy.close ();
diff --git a/rkward/dialogs/rkloadlibsdialog.cpp b/rkward/dialogs/rkloadlibsdialog.cpp
index f17b1c8..bfe571f 100644
--- a/rkward/dialogs/rkloadlibsdialog.cpp
+++ b/rkward/dialogs/rkloadlibsdialog.cpp
@@ -991,9 +991,10 @@ void RKRPackageInstallationStatus::statusCommandFinished (RCommand *command) {
 void RKRPackageInstallationStatus::clearStatus () {
 	RK_TRACE (DIALOGS);
 
+	beginResetModel ();
 	available_status.fill (NoAction, available_packages.count ());
 	installed_status.fill (NoAction, installed_packages.count ());
-	reset ();
+	endResetModel ();
 }
 
 QVariant RKRPackageInstallationStatus::headerData (int section, Qt::Orientation orientation, int role) const {
diff --git a/rkward/main.cpp b/rkward/main.cpp
index 75d37cb..a091b9b 100644
--- a/rkward/main.cpp
+++ b/rkward/main.cpp
@@ -53,8 +53,6 @@
 
 #include <kaboutdata.h>
 #include <klocale.h>
-#include <kstandarddirs.h>
-#include <kglobal.h>
 #include <KUrlAuthorized>
 
 #include <qstring.h>
@@ -88,12 +86,13 @@ int RK_Debug_Flags = DEBUG_ALL;
 int RK_Debug_CommandStep = 0;
 QMutex RK_Debug_Mutex;
 
-void RKDebugMessageOutput (QtMsgType type, const char *msg) {
+void RKDebugMessageOutput (QtMsgType type, const QMessageLogContext &, const QString &msg) {
 	RK_Debug_Mutex.lock ();
 	if (type == QtFatalMsg) {
-		fprintf (stderr, "%s\n", msg);
+		fprintf (stderr, "%s\n", qPrintable (msg));
 	}
-	RKSettingsModuleDebug::debug_file->write (msg);
+	// KF5 TODO: Make use of message log context
+	RKSettingsModuleDebug::debug_file->write (qPrintable (msg));
 	RKSettingsModuleDebug::debug_file->write ("\n");
 	RKSettingsModuleDebug::debug_file->flush ();
 	RK_Debug_Mutex.unlock ();
@@ -110,7 +109,7 @@ void RKDebug (int flags, int level, const char *fmt, ...) {
 	va_start (ap, fmt);
 	vsnprintf (buffer, bufsize-1, fmt, ap);
 	va_end (ap);
-	RKDebugMessageOutput (QtDebugMsg, buffer);
+	RKDebugMessageOutput (QtDebugMsg, QMessageLogContext (), buffer);
 	if (QApplication::instance ()->thread () == QThread::currentThread ()) {
 		// not safe to call from any other than the GUI thread
 		RKDebugMessageWindow::newMessage (flags, level, QString (buffer));
@@ -198,7 +197,7 @@ int main (int argc, char *argv[]) {
 	RKSettingsModuleDebug::debug_file->setAutoRemove (false);
 	if (RKSettingsModuleDebug::debug_file->open ()) {
 		RK_DEBUG (APP, DL_INFO, "Full debug output is at %s", qPrintable (RKSettingsModuleDebug::debug_file->fileName ()));
-		qInstallMsgHandler (RKDebugMessageOutput);
+		qInstallMessageHandler (RKDebugMessageOutput);
 	}
 
 	if (app.isSessionRestored ()) {
@@ -207,15 +206,16 @@ int main (int argc, char *argv[]) {
 		new RKWardMainWindow ();
 	}
 
+/* KF5 TODO: Still needed?
 	// Usually, KDE always adds the current directory to the list of prefixes.
 	// However, since RKWard 0.5.6, the main binary is in KDE's libexec dir, which defies this mechanism. Therefore, RKWARD_ENSURE_PREFIX is set from the wrapper script.
 	QByteArray add_path = qgetenv ("RKWARD_ENSURE_PREFIX");
-	if (!add_path.isEmpty ()) KGlobal::dirs ()->addPrefix (QString::fromLocal8Bit (add_path));
+	if (!add_path.isEmpty ()) KGlobal::dirs ()->addPrefix (QString::fromLocal8Bit (add_path)); */
 
 	// do it!
 	int status = app.exec ();
 
-	qInstallMsgHandler (0);
+	qInstallMessageHandler (0);
 	RKSettingsModuleDebug::debug_file->close ();
 
 	return status;
diff --git a/rkward/misc/CMakeLists.txt b/rkward/misc/CMakeLists.txt
index 6ac43a2..2009536 100644
--- a/rkward/misc/CMakeLists.txt
+++ b/rkward/misc/CMakeLists.txt
@@ -26,6 +26,7 @@ SET(misc_STAT_SRCS
    rkdynamicsearchline.cpp
    rkaccordiontable.cpp
    rkxmlguipreviewarea.cpp
+   rkdialogbuttonbox.cpp
    )
 
 ADD_LIBRARY(misc STATIC ${misc_STAT_SRCS})
diff --git a/rkward/misc/rkaccordiontable.cpp b/rkward/misc/rkaccordiontable.cpp
index 8cd2f14..5bae437 100644
--- a/rkward/misc/rkaccordiontable.cpp
+++ b/rkward/misc/rkaccordiontable.cpp
@@ -461,8 +461,8 @@ void RKAccordionTable::updateWidget () {
 				if (i == 0) {
 					header ()->setStretchLastSection (false);  // we stretch the second to last, instead
 					header ()->resizeSection (button_index.column (), rowHeight (row));
-					header ()->setResizeMode (button_index.column (), QHeaderView::Fixed);
-					header ()->setResizeMode (button_index.column () - 1, QHeaderView::Stretch);
+					header ()->setSectionResizeMode (button_index.column (), QHeaderView::Fixed);
+					header ()->setSectionResizeMode (button_index.column () - 1, QHeaderView::Stretch);
 				}
 			}
 		}
diff --git a/rkward/misc/rkdialogbuttonbox.cpp b/rkward/misc/rkdialogbuttonbox.cpp
new file mode 100644
index 0000000..7ffabd9
--- /dev/null
+++ b/rkward/misc/rkdialogbuttonbox.cpp
@@ -0,0 +1,34 @@
+/***************************************************************************
+                          rkdialogbuttonbox  -  description
+                             -------------------
+    begin                : Sat Feb 13 2016
+    copyright            : (C) 2016 by Thomas Friedrichsmeier
+    email                : thomas.friedrichsmeier at kdemail.net
+ ***************************************************************************/
+
+/***************************************************************************
+ *                                                                         *
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) any later version.                                   *
+ *                                                                         *
+ ***************************************************************************/
+
+#include "rkdialogbuttonbox.h"
+
+#include <QPushButton>
+#include <QDialog>
+
+#include "../debug.h"
+
+RKDialogButtonBox::RKDialogButtonBox (QDialogButtonBox::StandardButtons buttons, QDialog *parent) : QDialogButtonBox (buttons, parent) {
+	RK_TRACE (MISC);
+	if (buttons & QDialogButtonBox::Ok) {
+		connect (button (QDialogButtonBox::Ok), &QPushButton::clicked, parent, &QDialog::accept);
+		button (QDialogButtonBox::Ok)->setShortcut (Qt::CTRL | Qt::Key_Return);
+	}
+	if (buttons & QDialogButtonBox::Cancel) {
+		connect (button (QDialogButtonBox::Cancel), &QPushButton::clicked, parent, &QDialog::reject);
+	}
+}
diff --git a/rkward/misc/rkdialogbuttonbox.h b/rkward/misc/rkdialogbuttonbox.h
new file mode 100644
index 0000000..ea77310
--- /dev/null
+++ b/rkward/misc/rkdialogbuttonbox.h
@@ -0,0 +1,29 @@
+/***************************************************************************
+                          rkdialogbuttonbox  -  description
+                             -------------------
+    begin                : Sat Feb 13 2016
+    copyright            : (C) 2016 by Thomas Friedrichsmeier
+    email                : thomas.friedrichsmeier at kdemail.net
+ ***************************************************************************/
+
+/***************************************************************************
+ *                                                                         *
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) any later version.                                   *
+ *                                                                         *
+ ***************************************************************************/
+#ifndef RKDIALOGBUTTONBOX_H
+#define RKDIALOGBUTTONBOX_H
+
+#include <QDialogButtonBox>
+
+/** Simple helper class to help keep sanity: Just like QDialogButtonBox, but it "Ok" and / or "Cancel" buttons are requested in the constructor, these are connected to the
+ *  dialog's accept() and reject()-slots, automatically. Also, adds the Ctrl+Enter shortcut to the ok button, as suggested by KDE */
+class RKDialogButtonBox : public QDialogButtonBox {
+public:
+	RKDialogButtonBox (QDialogButtonBox::StandardButtons buttons, QDialog *parent);
+};
+
+#endif
diff --git a/rkward/misc/rkmessagecatalog.cpp b/rkward/misc/rkmessagecatalog.cpp
index 2cb269e..664113d 100644
--- a/rkward/misc/rkmessagecatalog.cpp
+++ b/rkward/misc/rkmessagecatalog.cpp
@@ -115,7 +115,7 @@ RKMessageCatalog* RKMessageCatalog::nullCatalog () {
 void RKMessageCatalog::switchLanguage (const QString &new_language_code) {
 	RK_TRACE (MISC);
 
-	qputenv ("LANGUAGE", new_language_code.toAscii ().data ());
+	qputenv ("LANGUAGE", new_language_code.toLatin1 ().data ());
 	// KF5 TODO: correct?
 	QLocale::setDefault (QLocale (new_language_code));
 	// magic to make gettext discard cache
diff --git a/rkward/plugin/rkoptionset.cpp b/rkward/plugin/rkoptionset.cpp
index eed5be9..4a6d84b 100644
--- a/rkward/plugin/rkoptionset.cpp
+++ b/rkward/plugin/rkoptionset.cpp
@@ -780,7 +780,6 @@ RKOptionSetDisplayModel::RKOptionSetDisplayModel (RKOptionSet* parent) : QAbstra
 	connect (&reset_timer, &QTimer::timeout, this, &RKOptionSetDisplayModel::doResetNow);
 	reset_timer.setInterval (0);
 	reset_timer.setSingleShot (true);
-	setSupportedDragActions (Qt::MoveAction);
 }
 
 RKOptionSetDisplayModel::~RKOptionSetDisplayModel () {
@@ -866,7 +865,7 @@ QStringList RKOptionSetDisplayModel::mimeTypes () const {
 QMimeData* RKOptionSetDisplayModel::mimeData (const QModelIndexList& indexes) const {
 	RK_ASSERT (indexes.length () >= 1);
 	QMimeData *ret = new QMimeData ();
-	ret->setData (optionsetdisplaymodel_mt, QByteArray (QString::number (indexes.first ().row ()).toAscii ()));
+	ret->setData (optionsetdisplaymodel_mt, QByteArray (QString::number (indexes.first ().row ()).toLatin1 ()));
 	return (ret);
 }
 
@@ -875,7 +874,7 @@ bool RKOptionSetDisplayModel::dropMimeData (const QMimeData* data, Qt::DropActio
 	if (action == Qt::IgnoreAction) return true;
 	if (action == Qt::MoveAction) {
 		if (parent.isValid ()) return false;
-		int srow = QString::fromAscii (data->data (optionsetdisplaymodel_mt)).toInt ();
+		int srow = QString::fromLatin1 (data->data (optionsetdisplaymodel_mt)).toInt ();
 		set->moveRow (srow, row);
 	}
 	return false;
@@ -889,3 +888,6 @@ Qt::DropActions RKOptionSetDisplayModel::supportedDropActions () const {
     return Qt::MoveAction;
 }
 
+Qt::DropActions RKOptionSetDisplayModel::supportedDragActions() const {
+	return Qt::MoveAction;
+}
diff --git a/rkward/plugin/rkoptionset.h b/rkward/plugin/rkoptionset.h
index 8793be7..3941045 100644
--- a/rkward/plugin/rkoptionset.h
+++ b/rkward/plugin/rkoptionset.h
@@ -153,6 +153,7 @@ friend class RKOptionSet;
 	bool dropMimeData (const QMimeData* data, Qt::DropAction action, int row, int column, const QModelIndex& parent) override;
 	Qt::ItemFlags flags (const QModelIndex& index) const override;
 	Qt::DropActions supportedDropActions () const override;
+	Qt::DropActions supportedDragActions () const override;
 private slots:
 	void doResetNow ();
 };
diff --git a/rkward/plugin/rkpreviewbox.cpp b/rkward/plugin/rkpreviewbox.cpp
index 256cf94..eb40364 100644
--- a/rkward/plugin/rkpreviewbox.cpp
+++ b/rkward/plugin/rkpreviewbox.cpp
@@ -249,7 +249,7 @@ void RKPreviewBox::rCommandDone (RCommand *command) {
 	if (new_preview_pending) tryPreview ();
 
 	QString warnings = command->warnings () + command->error ();
-	if (!warnings.isEmpty ()) warnings = QString ("<b>%1</b>\n<pre>%2</pre>").arg (i18n ("Warnings or Errors:")).arg (Qt::escape (warnings));
+	if (!warnings.isEmpty ()) warnings = QString ("<b>%1</b>\n<pre>%2</pre>").arg (i18n ("Warnings or Errors:")).arg (warnings.toHtmlEscaped ());
 	setStatusMessage (warnings);
 
 	updateStatusLabel ();
diff --git a/rkward/plugin/rkvarslot.cpp b/rkward/plugin/rkvarslot.cpp
index 25f42c6..35f4c2e 100644
--- a/rkward/plugin/rkvarslot.cpp
+++ b/rkward/plugin/rkvarslot.cpp
@@ -25,9 +25,9 @@
 #include <QEvent>
 #include <QGridLayout>
 #include <QVBoxLayout>
+#include <QIcon>
 
 #include <klocale.h>
-#include <kicon.h>
 
 #include "rkvarselector.h"
 #include "../core/robject.h"
@@ -167,7 +167,7 @@ void RKVarSlot::availablePropertyChanged (RKComponentPropertyBase *) {
 			QString probs = static_cast<RKComponentPropertyRObjects*> (available)->objectProblems (i);
 			if (!probs.isEmpty ()) {
 				new_item->setToolTip (0, i18n ("<p>Using this object, here, may lead to failures or unexpected results, for the following reason(s):</p>") + probs);
-				new_item->setIcon (0, KIcon ("task-attention"));
+				new_item->setIcon (0, QIcon::fromTheme ("task-attention"));
 			}
 		}
 	}
diff --git a/rkward/rbackend/rinterface.cpp b/rkward/rbackend/rinterface.cpp
index 2761c9d..5964aae 100644
--- a/rkward/rbackend/rinterface.cpp
+++ b/rkward/rbackend/rinterface.cpp
@@ -449,7 +449,7 @@ void RInterface::flushOutput (bool forced) {
 
 					previous_output_type = output->type;
 				}
-				recorded_output.append (Qt::escape (output->output));
+				recorded_output.append (output->output.toHtmlEscaped ());
 			}
 		}
 
diff --git a/rkward/rbackend/rkrbackendprotocol_backend.cpp b/rkward/rbackend/rkrbackendprotocol_backend.cpp
index 1dbc773..0a59264 100644
--- a/rkward/rbackend/rkrbackendprotocol_backend.cpp
+++ b/rkward/rbackend/rkrbackendprotocol_backend.cpp
@@ -40,12 +40,12 @@
 	QMutex RK_Debug_Mutex;
 	QTemporaryFile* RK_Debug_File;
 
-	void RKDebugMessageOutput (QtMsgType type, const char *msg) {
+	void RKDebugMessageOutput (QtMsgType type, const QMessageLogContext &, const QString &msg) {
 		RK_Debug_Mutex.lock ();
 		if (type == QtFatalMsg) {
-			fprintf (stderr, "%s\n", msg);
+			fprintf (stderr, "%s\n", qPrintable (msg));
 		}
-		RK_Debug_File->write (msg);
+		RK_Debug_File->write (qPrintable (msg));
 		RK_Debug_File->write ("\n");
 		RK_Debug_File->flush ();
 		RK_Debug_Mutex.unlock ();
@@ -63,7 +63,7 @@
 		va_start (ap, fmt);
 		vsnprintf (buffer, bufsize-1, fmt, ap);
 		va_end (ap);
-		RKDebugMessageOutput (QtDebugMsg, buffer);
+		RKDebugMessageOutput (QtDebugMsg, QMessageLogContext (), buffer);
 	}
 
 	int main(int argc, char *argv[]) {
@@ -74,7 +74,7 @@
 
 		RK_Debug_File = new QTemporaryFile (QDir::tempPath () + "/rkward.rbackend");
 		RK_Debug_File->setAutoRemove (false);
-		if (RK_Debug_File->open ()) qInstallMsgHandler (RKDebugMessageOutput);
+		if (RK_Debug_File->open ()) qInstallMessageHandler (RKDebugMessageOutput);
 
 		QString servername, rkd_server_name;
 		QString data_dir, locale_dir;
diff --git a/rkward/rbackend/rksessionvars.cpp b/rkward/rbackend/rksessionvars.cpp
index d001081..41da39c 100644
--- a/rkward/rbackend/rksessionvars.cpp
+++ b/rkward/rbackend/rksessionvars.cpp
@@ -121,7 +121,8 @@ int RKSessionVars::compareRVersion (const QString& version) {
 QStringList RKSessionVars::frontendSessionInfo () {
 	QStringList lines;
 	lines.append ("RKWard version: " RKWARD_VERSION);
-	lines.append ("KDE version (runtime): " + QString (KDE::versionString ()));
+	// KF5 TODO: find replacement for line below
+	//lines.append ("KDE version (runtime): " + QString (KDE::versionString ()));
 	lines.append ("KDE version (compile time): " KDE_VERSION_STRING);
 	lines.append (QString ("Qt version (runtime): ") + qVersion ());
 #if defined Q_OS_WIN
diff --git a/rkward/rkconsole.cpp b/rkward/rkconsole.cpp
index 71e8137..9a6fcd3 100644
--- a/rkward/rkconsole.cpp
+++ b/rkward/rkconsole.cpp
@@ -33,11 +33,12 @@
 #include <QTemporaryFile>
 #include <QMimeData>
 #include <QAction>
+#include <QFileDialog>
+#include <QApplication>
 
 #include <klocale.h>
 #include <kactioncollection.h>
 #include <kconfig.h>
-#include <kapplication.h>
 #include <kmessagebox.h>
 #include <kshellcompletion.h>
 #include <ktexteditor/editor.h>
@@ -45,9 +46,9 @@
 #include <ktexteditor/markinterface.h>
 #include <ktexteditor_version.h>
 #include <kxmlguifactory.h>
-#include <kfiledialog.h>
-#include <kio/netaccess.h>
-#include <QFileDialog>
+#include <kio/filecopyjob.h>
+#include <KJobWidgets>
+#include <KJobUiDelegate>
 
 #include "rkglobals.h"
 #include "rkward.h"
@@ -496,7 +497,7 @@ void RKConsole::doTabCompletion () {
 	}
 
 	// no completion was possible
-	KApplication::kApplication ()->beep ();
+	qApp->beep ();
 }
 
 bool RKConsole::eventFilter (QObject *o, QEvent *e) {
@@ -636,7 +637,7 @@ void RKConsole::commandsListUp (bool context_sensitive) {
 
 	bool found = commands_history.up (context_sensitive, currentEditingLine ());
 	if (found) setCurrentEditingLine (commands_history.current ());
-	else KApplication::kApplication ()->beep ();
+	else qApp->beep ();
 }
 
 void RKConsole::commandsListDown (bool context_sensitive) {
@@ -644,7 +645,7 @@ void RKConsole::commandsListDown (bool context_sensitive) {
 
 	bool found = commands_history.down (context_sensitive, currentEditingLine ());
 	if (found) setCurrentEditingLine (commands_history.current ());
-	else KApplication::kApplication ()->beep ();
+	else qApp->beep ();
 }
 
 void RKConsole::rCommandDone (RCommand *command) {
@@ -819,15 +820,28 @@ void RKConsole::userLoadHistory (const QUrl &_url) {
 		RKSettingsModuleGeneral::updateLastUsedUrl ("rscripts", url.adjusted (QUrl::RemoveFilename));
 	}
 
-	QString tempfile;
-	KIO::NetAccess::download (url, tempfile, this);
+	QTemporaryFile *tmpfile = 0;
+	QString filename;
+	if (!url.isLocalFile ()) {
+		tmpfile = new QTemporaryFile (this);
+		KIO::Job* getjob = KIO::file_copy (url, QUrl::fromLocalFile (tmpfile->fileName()));
+		KJobWidgets::setWindow (getjob, RKWardMainWindow::getMain ());
+		if (!getjob->exec ()) {
+			getjob->ui ()->showErrorMessage();
+			delete (tmpfile);
+			return;
+		}
+		filename = tmpfile->fileName ();
+	} else {
+		filename = url.toLocalFile ();
+	}
 
-	QFile file (tempfile);
+	QFile file (filename);
 	if (!file.open (QIODevice::Text | QIODevice::ReadOnly)) return;
 	setCommandHistory (QString (file.readAll ()).split ('\n', QString::SkipEmptyParts), false);
 	file.close ();
 
-	KIO::NetAccess::removeTempFile (tempfile);
+	delete (tmpfile);
 }
 
 void RKConsole::userSaveHistory (const QUrl &_url) {
@@ -835,7 +849,7 @@ void RKConsole::userSaveHistory (const QUrl &_url) {
 
 	QUrl url = _url;
 	if (url.isEmpty ()) {
-		url = KFileDialog::getSaveUrl (QUrl (), i18n ("*.Rhistory|R history files (*.Rhistory)\n*|All files (*)"), this, i18n ("Select filename to save command history"), KFileDialog::ConfirmOverwrite);
+		url = QFileDialog::getSaveFileUrl (this, i18n ("Select filename to save command history"), QUrl (), i18n ("R history files [*.Rhistory] (*.Rhistory);;All files [*] (*)"));
 		if (url.isEmpty ()) return;
 	}
 
@@ -844,7 +858,12 @@ void RKConsole::userSaveHistory (const QUrl &_url) {
 	tempfile.write (QString (commandHistory ().join ("\n") + '\n').toLocal8Bit ().data ());
 	tempfile.close ();
 
-	KIO::NetAccess::upload (tempfile.fileName (), url, this);
+	KIO::Job* getjob = KIO::file_copy (QUrl::fromLocalFile (tempfile.fileName()), url);
+	KJobWidgets::setWindow (getjob, RKWardMainWindow::getMain ());
+	if (!getjob->exec ()) {
+		getjob->ui ()->showErrorMessage();
+		return;
+	}
 }
 
 QString RKConsole::cleanSelection (const QString &origin) {
diff --git a/rkward/rkward.cpp b/rkward/rkward.cpp
index cc20273..f401b79 100644
--- a/rkward/rkward.cpp
+++ b/rkward/rkward.cpp
@@ -21,30 +21,27 @@
 #include <QCloseEvent>
 #include <QPointer>
 #include <QApplication>
+#include <QMenuBar>
+#include <QStatusBar>
+#include <QInputDialog>
 
 // include files for KDE
 #include <kmessagebox.h>
 #include <kencodingfiledialog.h>
-#include <kmenubar.h>
-#include <kstatusbar.h>
 #include <klocale.h>
 #include <kconfig.h>
-#include <kglobal.h>
-#include <kstandarddirs.h>
 #include <kstandardaction.h>
-#include <kinputdialog.h>
 #include <kmultitabbar.h>
 #include <ksqueezedtextlabel.h>
 #include <kparts/partmanager.h>
 #include <kxmlguifactory.h>
 #include <kactioncollection.h>
 #include <krecentfilesaction.h>
-#include <khbox.h>
 #include <ktoolbar.h>
 #include <kactionmenu.h>
 #include <QIcon>
 #include <KSharedConfig>
-#include <kdialog.h>
+#include <KConfigGroup>
 
 // application specific includes
 #include "rkward.h"
@@ -62,6 +59,7 @@
 #include "misc/rkcommonfunctions.h"
 #include "misc/rkxmlguisyncer.h"
 #include "misc/rkdbusapi.h"
+#include "misc/rkdialogbuttonbox.h"
 #include "rkglobals.h"
 #include "dialogs/startupdialog.h"
 #include "dialogs/rkloadlibsdialog.h"
@@ -262,7 +260,7 @@ void RKWardMainWindow::doPostInit () {
 		}
 
 		if (RKSettingsModuleGeneral::workplaceSaveMode () == RKSettingsModuleGeneral::SaveWorkplaceWithSession) {
-			RKWorkplace::mainWorkplace ()->restoreWorkplace (RKSettingsModuleGeneral::getSavedWorkplace (KGlobal::config ().data ()).split ('\n'));
+			RKWorkplace::mainWorkplace ()->restoreWorkplace (RKSettingsModuleGeneral::getSavedWorkplace (KSharedConfig::openConfig ().data ()).split ('\n'));
 		}
 		if (RKSettingsModuleGeneral::showHelpOnStartup ()) toplevel_actions->showRKWardHelp ();
 	}
@@ -389,14 +387,18 @@ void RKWardMainWindow::slotCancelAllCommands () {
 void RKWardMainWindow::configureCarbonCopy () {
 	RK_TRACE (APP);
 
-	KDialog *dialog = new KDialog ();
-	dialog->setCaption (i18n ("Carbon Copy Settings"));
+	QDialog *dialog = new QDialog ();
+	dialog->setWindowTitle (i18n ("Carbon Copy Settings"));
+	QVBoxLayout *layout = new QVBoxLayout (dialog);
 	RKCarbonCopySettings *settings = new RKCarbonCopySettings (dialog);
-	dialog->setMainWidget (settings);
-	dialog->setButtons (KDialog::Ok | KDialog::Apply | KDialog::Cancel);
+	layout->addWidget (settings);
+
+	RKDialogButtonBox *box = new RKDialogButtonBox (QDialogButtonBox::Ok | QDialogButtonBox::Apply | QDialogButtonBox::Cancel, dialog);
 	dialog->setAttribute (Qt::WA_DeleteOnClose);
-	connect (dialog, &KDialog::okClicked, settings, &RKCarbonCopySettings::applyChanges);
-	connect (dialog, &KDialog::applyClicked, settings, &RKCarbonCopySettings::applyChanges);
+	connect (dialog, &QDialog::accepted, settings, &RKCarbonCopySettings::applyChanges);
+	connect (box->button (QDialogButtonBox::Apply), &QPushButton::clicked, settings, &RKCarbonCopySettings::applyChanges);
+	layout->addWidget (box);
+
 	dialog->show ();
 }
 
@@ -671,15 +673,18 @@ void RKWardMainWindow::initStatusBar () {
 	statusBar ()->addWidget (statusbar_cwd, 10);
 	updateCWD ();
 
-	KHBox *box = new KHBox (statusBar ());
-	box->setSpacing (0);
+	QWidget *box = new QWidget (statusBar ());
+	QHBoxLayout *boxl = new QHBoxLayout (box);
+	boxl->setSpacing (0);
 	statusbar_r_status = new QLabel (" <b>R</b> ", box);
 	statusbar_r_status->setFixedHeight (statusBar ()->fontMetrics ().height () + 2);
+	boxl->addWidget (statusbar_r_status);
 
 	QToolButton* dummy = new QToolButton (box);
 	dummy->setDefaultAction (interrupt_all_commands);
 	dummy->setFixedHeight (statusbar_r_status->height ());
 	dummy->setAutoRaise (true);
+	boxl->addWidget (dummy);
 
 	statusBar ()->addPermanentWidget (box, 0);
 	setRStatus (Starting);
@@ -744,7 +749,7 @@ bool RKWardMainWindow::doQueryQuit () {
 	slotSetStatusBarText (i18n ("Exiting..."));
 	saveOptions ();
 	if (RKSettingsModuleGeneral::workplaceSaveMode () == RKSettingsModuleGeneral::SaveWorkplaceWithSession) {
-		RKSettingsModuleGeneral::setSavedWorkplace (RKWorkplace::mainWorkplace ()->makeWorkplaceDescription ().join ("\n"), KGlobal::config ().data ());
+		RKSettingsModuleGeneral::setSavedWorkplace (RKWorkplace::mainWorkplace ()->makeWorkplaceDescription ().join ("\n"), KSharedConfig::openConfig ().data ());
 	}
 
 //	if (!RObjectList::getGlobalEnv ()->isEmpty ()) {
@@ -779,7 +784,7 @@ void RKWardMainWindow::slotNewDataFrame () {
 	RK_TRACE (APP);
 	bool ok;
 
-	QString name = KInputDialog::getText (i18n ("New dataset"), i18n ("Enter name for the new dataset"), "my.data", &ok, this);
+	QString name = QInputDialog::getText (this, i18n ("New dataset"), i18n ("Enter name for the new dataset"), QLineEdit::Normal, "my.data", &ok);
 
 	if (ok) RKWorkplace::mainWorkplace ()->editNewDataFrame (name);
 }
diff --git a/rkward/rkward_startup_wrapper.cpp b/rkward/rkward_startup_wrapper.cpp
index 0ae6cf5..2ef9e8d 100644
--- a/rkward/rkward_startup_wrapper.cpp
+++ b/rkward/rkward_startup_wrapper.cpp
@@ -180,12 +180,12 @@ int main (int argc, char *argv[]) {
 	QString kf5_config_exe = findExeAtPath ("kf5-config", QDir::currentPath ());
 	if (kf5_config_exe.isNull ()) kf5_config_exe = findExeAtPath ("kf5-config", app.applicationDirPath ());
 	if (kf5_config_exe.isNull ()) kf5_config_exe = findExeAtPath ("kf5-config", QDir (app.applicationDirPath ()).filePath ("KDE/bin"));
-	if (kf5_config_exe.isNull ()) {
 #ifdef Q_OS_WIN
 	QStringList syspath = QString (qgetenv ("PATH")).split (';');
 #else
 	QStringList syspath = QString (qgetenv ("PATH")).split (':');
 #endif
+	if (kf5_config_exe.isNull ()) {
 		for (int i = 0; i < syspath.size (); ++i) {
 			kf5_config_exe = findExeAtPath ("kf5-config", syspath[i]);
 			if (!kf5_config_exe.isNull ()) break;
@@ -202,12 +202,19 @@ int main (int argc, char *argv[]) {
 	QString kde_dir_safe_path = quoteCommand (kde_dir.path ());
 #ifdef Q_OS_WIN
 	QString kdeinit5_exe = findExeAtPath ("kdeinit5", kde_dir.path ());
+#endif
+	if (syspath.indexOf (kde_dir.path ()) < 0) {
+		if (debug_level > 3) qDebug ("Adding %s to the system path", qPrintable (kde_dir_safe_path));
+#ifdef Q_OS_WIN
 	qputenv ("PATH", QString (kde_dir_safe_path + ';' + qgetenv ("PATH")).toLocal8Bit ());
-	if (debug_level > 3) qDebug ("Adding %s to the system path", qPrintable (kde_dir_safe_path));
+#else
+	qputenv ("PATH", QString (kde_dir_safe_path + ':' + qgetenv ("PATH")).toLocal8Bit ());
 #endif
+	}
+/* KF5 TODO: Still needed? 
 	// important if RKWard is not in KDEPREFIX/bin but e.g. KDEPREFIX/lib/libexec
 	qputenv ("RKWARD_ENSURE_PREFIX", kde_dir_safe_path.toLocal8Bit ());
-	if (debug_level > 3) qDebug ("Setting environment variable RKWARD_ENSURE_PREFIX=%s", qPrintable (kde_dir_safe_path));
+	if (debug_level > 3) qDebug ("Setting environment variable RKWARD_ENSURE_PREFIX=%s", qPrintable (kde_dir_safe_path)); */
 
 	QString rkward_frontend_exe = findRKWardAtPath (app.applicationDirPath ());	// this is for running directly from a build tree
 #ifdef Q_OS_MAC
diff --git a/rkward/settings/rksettingsmoduleobjectbrowser.cpp b/rkward/settings/rksettingsmoduleobjectbrowser.cpp
index 045a946..e37d718 100644
--- a/rkward/settings/rksettingsmoduleobjectbrowser.cpp
+++ b/rkward/settings/rksettingsmoduleobjectbrowser.cpp
@@ -20,12 +20,12 @@
 #include <klocale.h>
 #include <kconfig.h>
 #include <kconfiggroup.h>
-#include <kinputdialog.h>
 
 #include <qlayout.h>
 #include <qcheckbox.h>
 #include <qlabel.h>
 #include <QVBoxLayout>
+#include <QInputDialog>
 
 #include "../rkglobals.h"
 #include "../misc/multistringselector.h"
@@ -78,8 +78,9 @@ bool RKSettingsModuleObjectBrowser::isPackageBlacklisted (const QString &package
 
 void RKSettingsModuleObjectBrowser::addBlackList (QStringList *string_list) {
 	RK_TRACE (SETTINGS);
-	QString new_string = KInputDialog::getText (i18n ("Add exclusion"), i18n ("Add the name of the package that no structure should be fetched for"), QString (), 0, this);
-	(*string_list).append (new_string);
+	bool ok;
+	QString new_string = QInputDialog::getText (this, i18n ("Add exclusion"), i18n ("Add the name of the package that no structure should be fetched for"), QLineEdit::Normal, QString (), &ok);
+	if (ok) (*string_list).append (new_string);
 }
 
 void RKSettingsModuleObjectBrowser::applyChanges () {
diff --git a/rkward/settings/rksettingsmoduleplugins.cpp b/rkward/settings/rksettingsmoduleplugins.cpp
index a29d48a..b3cdcb3 100644
--- a/rkward/settings/rksettingsmoduleplugins.cpp
+++ b/rkward/settings/rksettingsmoduleplugins.cpp
@@ -384,8 +384,9 @@ RKSettingsModulePluginsModel::~RKSettingsModulePluginsModel() {
 
 void RKSettingsModulePluginsModel::init (const RKSettingsModulePlugins::PluginMapList& known_plugin_maps) {
 	RK_TRACE (SETTINGS);
+	beginResetModel ();
 	plugin_maps = known_plugin_maps;
-	emit (reset ());
+	endResetModel ();
 }
 
 int RKSettingsModulePluginsModel::rowCount (const QModelIndex& parent) const {
diff --git a/rkward/settings/rksettingsmoduler.cpp b/rkward/settings/rksettingsmoduler.cpp
index 34d24c8..5e03eba 100644
--- a/rkward/settings/rksettingsmoduler.cpp
+++ b/rkward/settings/rksettingsmoduler.cpp
@@ -17,7 +17,6 @@
 #include "rksettingsmoduler.h"
 
 #include <klocale.h>
-#include <kinputdialog.h>
 #include <KConfigGroup>
 
 #include <qlabel.h>
@@ -30,6 +29,7 @@
 #include <QTextEdit>
 #include <QFileDialog>
 #include <QSpinBox>
+#include <QInputDialog>
 
 #include "rksettingsmodulegeneral.h"
 #include "../core/robject.h"
@@ -456,8 +456,9 @@ void RKSettingsModuleRPackages::addLibLoc (QStringList *string_list) {
 
 void RKSettingsModuleRPackages::addRepository (QStringList *string_list) {
 	RK_TRACE (SETTINGS);
-	QString new_string = KInputDialog::getText (i18n ("Add repository"), i18n ("Add URL of new repository"), QString (), 0, this);
-	(*string_list).append (new_string);
+	bool ok;
+	QString new_string = QInputDialog::getText (this, i18n ("Add repository"), i18n ("Add URL of new repository"), QLineEdit::Normal, QString (), &ok);
+	if (ok) (*string_list).append (new_string);
 }
 
 QString RKSettingsModuleRPackages::caption () {
diff --git a/rkward/windows/rcontrolwindow.cpp b/rkward/windows/rcontrolwindow.cpp
index 88674d1..0304d00 100644
--- a/rkward/windows/rcontrolwindow.cpp
+++ b/rkward/windows/rcontrolwindow.cpp
@@ -65,7 +65,7 @@ RControlWindow::RControlWindow (QWidget *parent, bool tool_window, const char *n
 	commands_view = new QTreeView (this);
 
 	commands_view->setSortingEnabled (false);
-	commands_view->header ()->setMovable (false);
+	commands_view->header ()->setSectionsMovable (false);
 	commands_view->header ()->setStretchLastSection (false);
 
 	commands_view->setSelectionMode (QAbstractItemView::ExtendedSelection);
@@ -89,7 +89,7 @@ void RControlWindow::showEvent (QShowEvent *e) {
 	if (!commands_view->model ()) {
 		RCommandStackModel::getModel ()->addListener ();
 		commands_view->setModel (RCommandStackModel::getModel ());
-		commands_view->header ()->setResizeMode (0, QHeaderView::Stretch);	// can't do this in the ctor, as column 0 does not yet exist
+		commands_view->header ()->setSectionResizeMode (0, QHeaderView::Stretch);	// can't do this in the ctor, as column 0 does not yet exist
 		commands_view->expandAll ();
 	}
 
diff --git a/rkward/windows/rkcallstackviewer.cpp b/rkward/windows/rkcallstackviewer.cpp
index 5e27f85..56bdb6c 100644
--- a/rkward/windows/rkcallstackviewer.cpp
+++ b/rkward/windows/rkcallstackviewer.cpp
@@ -144,9 +144,9 @@ void RKCallstackViewerWidget::frameChanged (int frame_number) {
 	if (RKDebugHandler::instance ()->state () == RKDebugHandler::NotInDebugger) return;
 
 	frame_info->setText (i18n ("<b>Current call:</b> %1<br><b>Environment:</b> %2<br><b>Local objects:</b> %3",
-									Qt::escape (RKDebugHandler::instance ()->calls ().value (frame_number)),
-									Qt::escape (RKDebugHandler::instance ()->environments ().value (frame_number)),
-									Qt::escape (RKDebugHandler::instance ()->locals ().value (frame_number).split ('\n').join (", "))));
+									RKDebugHandler::instance ()->calls ().value (frame_number).toHtmlEscaped (),
+									RKDebugHandler::instance ()->environments ().value (frame_number).toHtmlEscaped (),
+									RKDebugHandler::instance ()->locals ().value (frame_number).split ('\n').join (", ").toHtmlEscaped ()));
 	frame_source->setText (RKDebugHandler::instance ()->functions ().value (frame_number) + '\n');
 	int line = RKDebugHandler::instance ()->relativeSourceLines ().value (frame_number, 0);
 	if (line > 0) frame_source->highlightLine (line - 1);
diff --git a/rkward/windows/rkcommandeditorwindow.cpp b/rkward/windows/rkcommandeditorwindow.cpp
index 3db61a3..ae4c2ec 100644
--- a/rkward/windows/rkcommandeditorwindow.cpp
+++ b/rkward/windows/rkcommandeditorwindow.cpp
@@ -1003,6 +1003,7 @@ void RKCodeCompletionModel::updateCompletionList (const QString& symbol) {
 	RK_TRACE (COMMANDEDITOR);
 
 	if (current_symbol == symbol) return;	// already up to date
+	beginResetModel ();
 
 	RObject::RObjectSearchMap map;
 	RObjectList::getObjectList ()->findObjectsMatching (symbol, &map);
@@ -1023,7 +1024,7 @@ void RKCodeCompletionModel::updateCompletionList (const QString& symbol) {
 	setRowCount (count);
 	current_symbol = symbol;
 
-	reset ();
+	endResetModel ();
 }
 
 void RKCodeCompletionModel::completionInvoked (KTextEditor::View*, const KTextEditor::Range&, InvocationType) {
@@ -1182,7 +1183,7 @@ QString RKCommandHighlighter::commandToHTML (const QString r_command, Highlighti
 					ret.append (opening.arg ("output_normal"));
 					previous_chunk = Output;
 				}
-				ret.append (Qt::escape (line) + '\n');	// don't copy output "highlighting". It is set using CSS, instead
+				ret.append (line.toHtmlEscaped () + '\n');	// don't copy output "highlighting". It is set using CSS, instead
 				continue;
 			}
 		}
diff --git a/rkward/windows/rkhelpsearchwindow.cpp b/rkward/windows/rkhelpsearchwindow.cpp
index c365ea4..4487dde 100644
--- a/rkward/windows/rkhelpsearchwindow.cpp
+++ b/rkward/windows/rkhelpsearchwindow.cpp
@@ -276,6 +276,7 @@ void RKHelpSearchResultsModel::setResults (const QStringList &results) {
 	RK_TRACE (APP);
 
 	RK_ASSERT ((results.size () % 4) == 0);
+	beginResetModel ();
 
 	result_count = results.size () / 4;
 	topics = results.mid (0, result_count);
@@ -283,7 +284,7 @@ void RKHelpSearchResultsModel::setResults (const QStringList &results) {
 	packages = results.mid (result_count*2, result_count);
 	types = results.mid (result_count*3, result_count);
 
-	reset ();
+	endResetModel ();
 }
 
 int RKHelpSearchResultsModel::rowCount (const QModelIndex& parent) const {
diff --git a/rkward/windows/rkwindowcatcher.cpp b/rkward/windows/rkwindowcatcher.cpp
index fd1c9d0..0afd545 100644
--- a/rkward/windows/rkwindowcatcher.cpp
+++ b/rkward/windows/rkwindowcatcher.cpp
@@ -148,7 +148,8 @@ void RKWindowCatcher::killDevice (int device_number) {
 	if (window) {
 		window->setKilledInR ();
 		window->close (true);
-		QApplication::syncX ();
+		// KF5 TODO: Still needed?
+		//QApplication::syncX ();
 	}
 }
 
diff --git a/rkward/windows/rkworkplace.cpp b/rkward/windows/rkworkplace.cpp
index 37785c5..6b55f4c 100644
--- a/rkward/windows/rkworkplace.cpp
+++ b/rkward/windows/rkworkplace.cpp
@@ -78,7 +78,6 @@ RKWorkplace::RKWorkplace (QWidget *parent) : QWidget (parent) {
 
 	tool_window_bars[RKToolWindowList::Top] = new RKToolWindowBar (KMultiTabBar::Top, this);
 	vert_splitter = new QSplitter (Qt::Vertical, this);
-	vert_splitter->setOpaqueResize (KGlobalSettings::opaqueResize ());
 	tool_window_bars[RKToolWindowList::Top]->setSplitter (vert_splitter);
 
 	QWidget *harea = new QWidget (vert_splitter);
@@ -88,7 +87,6 @@ RKWorkplace::RKWorkplace (QWidget *parent) : QWidget (parent) {
 
 	tool_window_bars[RKToolWindowList::Left] = new RKToolWindowBar (KMultiTabBar::Left, harea);
 	horiz_splitter = new QSplitter (Qt::Horizontal, harea);
-	horiz_splitter->setOpaqueResize (KGlobalSettings::opaqueResize ());
 	tool_window_bars[RKToolWindowList::Left]->setSplitter (horiz_splitter);
 
 	wview = new RKWorkplaceView (horiz_splitter);
diff --git a/rkward/windows/robjectbrowser.cpp b/rkward/windows/robjectbrowser.cpp
index 2667531..c05e90c 100644
--- a/rkward/windows/robjectbrowser.cpp
+++ b/rkward/windows/robjectbrowser.cpp
@@ -21,9 +21,9 @@
 #include <QFocusEvent>
 #include <QVBoxLayout>
 #include <QMenu>
+#include <QInputDialog>
 
 #include <klocale.h>
-#include <kinputdialog.h>
 #include <kmessagebox.h>
 
 #include "../rkward.h"
@@ -184,7 +184,7 @@ void RObjectBrowserInternal::popupCopy () {
 	bool ok;
 	RObject *object = list_view->menuObject ();
 	QString suggested_name = RObjectList::getGlobalEnv ()->validizeName (object->getShortName ());
-	QString name = KInputDialog::getText (i18n ("Copy object"), i18n ("Enter the name to copy to"), suggested_name, &ok, this);
+	QString name = QInputDialog::getText (this, i18n ("Copy object"), i18n ("Enter the name to copy to"), QLineEdit::Normal, suggested_name, &ok);
 
 	if (ok) {
 		QString valid = RObjectList::getGlobalEnv ()->validizeName (name);
@@ -230,7 +230,7 @@ void RObjectBrowserInternal::popupUnload () {
 void RObjectBrowserInternal::popupRename () {
 	RK_TRACE (APP);
 	bool ok;
-	QString name = KInputDialog::getText (i18n ("Rename object"), i18n ("Enter the new name"), list_view->menuObject ()->getShortName (), &ok, this);
+	QString name = QInputDialog::getText (this, i18n ("Rename object"), i18n ("Enter the new name"), QLineEdit::Normal, list_view->menuObject ()->getShortName (), &ok);
 	
 	if (ok) {
 		QString valid = static_cast<RContainerObject*> (list_view->menuObject ()->parentObject ())->validizeName (name);



More information about the rkward-tracker mailing list