Initial repo creation.
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
[submodule "interface"]
|
||||
path = interface
|
||||
url = https://git.teslos.co.uk/Triplehx3/TTK-Interface.git
|
||||
@@ -0,0 +1,17 @@
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2026 Teslos
|
||||
|
||||
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 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should receive a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
@@ -0,0 +1,24 @@
|
||||
# Teslos Tool Kit Base Plugin
|
||||
|
||||
A simple Qt6 / C++ pligun applet for TTK for demonstration purposes.
|
||||
|
||||
**Please note that you must have TTK installed for this to be of any use!**
|
||||
|
||||
## Build
|
||||
|
||||
```bash
|
||||
git clone https://git.teslos.co.uk/Triplehx3/TTK-BasePlugin.git
|
||||
cd TTK-BasePlugin
|
||||
git submodule update --init --recursive
|
||||
mkdir build
|
||||
cd build
|
||||
qmake6 ..
|
||||
make
|
||||
```
|
||||
|
||||
Or simply open the TTK-BasePlugin.pro file in the cloned directory inside Qt Creator.
|
||||
|
||||
copy libTTK-BasePlugin.so to /usr/lib/ttk/plugins
|
||||
|
||||
## License
|
||||
This project is licensed under the GNU General Public License v3.0 - see the [LICENSE](LICENSE) file for details.
|
||||
@@ -0,0 +1,23 @@
|
||||
#include "TTK-BasePlugin.h"
|
||||
|
||||
QString BasePlugin::pname()
|
||||
{
|
||||
return "Base Plugin";
|
||||
}
|
||||
|
||||
QString BasePlugin::pdesc()
|
||||
{
|
||||
return "Simple base plugin.";
|
||||
}
|
||||
|
||||
QWidget* BasePlugin::pcontent()
|
||||
{
|
||||
QWidget *test = new QWidget();
|
||||
test->setWindowTitle(tr("Base Plugin"));
|
||||
test->resize(400, 300);
|
||||
QVBoxLayout *mainLayout = new QVBoxLayout;
|
||||
test->setLayout(mainLayout);
|
||||
QIcon icon = QIcon(":/images/smile.png");
|
||||
test->setWindowIcon(icon);
|
||||
return test;
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
#ifndef BASEPLUGIN_H
|
||||
#define BASEPLUGIN_H
|
||||
|
||||
#include <interface/interface.h>
|
||||
|
||||
#include <QObject>
|
||||
#include <QString>
|
||||
#include <QWidget>
|
||||
#include <QVBoxLayout>
|
||||
|
||||
class BasePlugin : public QObject, public Interface
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PLUGIN_METADATA(IID "org.ttk.interface/1.0" FILE "TTK-BasePlugin.json")
|
||||
Q_INTERFACES(Interface)
|
||||
|
||||
public:
|
||||
QString pname() override;
|
||||
QString pdesc() override;
|
||||
QWidget *pcontent() override;
|
||||
|
||||
};
|
||||
#endif
|
||||
@@ -0,0 +1 @@
|
||||
{}
|
||||
@@ -0,0 +1,8 @@
|
||||
TEMPLATE = lib
|
||||
CONFIG += plugin
|
||||
QT += widgets
|
||||
HEADERS = interface/interface.h TTK-BasePlugin.h
|
||||
SOURCES = TTK-BasePlugin.cpp
|
||||
TARGET = $$qtLibraryTarget(TTK-BasePlugin)
|
||||
QMAKE_CXXFLAGS += -Wno-sfinae-incomplete
|
||||
|
||||
Submodule
+1
Submodule interface added at a60b998305
Reference in New Issue
Block a user