[education/rkward/kf5] rkward: Set kate main window on R Console
Thomas Friedrichsmeier
null at kde.org
Wed Apr 10 16:12:08 BST 2024
Git commit 6d404ae19e5556308c984692bbdb96681f2bf625 by Thomas Friedrichsmeier.
Committed on 02/04/2024 at 16:06.
Pushed by tfry into branch 'kf5'.
Set kate main window on R Console
M +4 -1 rkward/rkconsole.cpp
https://invent.kde.org/education/rkward/-/commit/6d404ae19e5556308c984692bbdb96681f2bf625
diff --git a/rkward/rkconsole.cpp b/rkward/rkconsole.cpp
index 761a02ee6..7d67b79d3 100644
--- a/rkward/rkconsole.cpp
+++ b/rkward/rkconsole.cpp
@@ -42,6 +42,7 @@ SPDX-License-Identifier: GPL-2.0-or-later
#include "windows/rkhelpsearchwindow.h"
#include "windows/rkcodecompletion.h"
#include "windows/rktexthints.h"
+#include "windows/katepluginintegration.h"
#include "rbackend/rkrinterface.h"
#include "settings/rksettings.h"
#include "settings/rksettingsmoduleconsole.h"
@@ -89,7 +90,9 @@ RKConsole::RKConsole (QWidget *parent, bool tool_window, const char *name) : RKM
}
doc = editor->createDocument (this);
- view = doc->createView (this);
+ // even though the R Console is not really a document window, it is for it to be constructed with a proper main window.
+ // E.g. argument hints don't get the correct window parent, otherwise
+ view = doc->createView (this, RKWardMainWindow::getMain()->katePluginIntegration()->mainWindow ()->mainWindow());
layout->addWidget (view);
view->setStatusBarEnabled (false);
setFocusProxy (view);
More information about the rkward-tracker
mailing list