File indexing completed on 2024-04-28 05:49:02
0001 /* 0002 * SPDX-FileCopyrightText: 2017 Friedrich W. H. Kossebau <kossebau@kde.org> 0003 * 0004 * SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #include "ktexteditorpreviewplugin.h" 0008 0009 #include "ktexteditorpreviewview.h" 0010 #include <ktexteditorpreview_debug.h> 0011 0012 // KF 0013 #include <KPluginFactory> 0014 #include <KTextEditor/MainWindow> 0015 0016 K_PLUGIN_FACTORY_WITH_JSON(KTextEditorPreviewPluginFactory, "ktexteditorpreview.json", registerPlugin<KTextEditorPreviewPlugin>();) 0017 0018 KTextEditorPreviewPlugin::KTextEditorPreviewPlugin(QObject *parent, const QVariantList & /*args*/) 0019 : KTextEditor::Plugin(parent) 0020 { 0021 } 0022 0023 KTextEditorPreviewPlugin::~KTextEditorPreviewPlugin() = default; 0024 0025 QObject *KTextEditorPreviewPlugin::createView(KTextEditor::MainWindow *mainwindow) 0026 { 0027 return new KTextEditorPreviewView(this, mainwindow); 0028 } 0029 0030 // needed for K_PLUGIN_FACTORY_WITH_JSON 0031 #include <ktexteditorpreviewplugin.moc> 0032 0033 #include "moc_ktexteditorpreviewplugin.cpp"