From 54216c4c28b81d33bd5c8b6e3b5a6083b53093fd Mon Sep 17 00:00:00 2001 From: ConfuSomu Date: Sun, 25 Dec 2022 01:58:03 -0500 Subject: Initial commit This project can also serve as a base for other Qt projects, as necessary. --- src/main.cpp | 11 ++++ src/mainwindow.cpp | 23 +++++++ src/mainwindow.h | 25 ++++++++ src/mainwindow.ui | 173 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 232 insertions(+) create mode 100644 src/main.cpp create mode 100644 src/mainwindow.cpp create mode 100644 src/mainwindow.h create mode 100644 src/mainwindow.ui (limited to 'src') diff --git a/src/main.cpp b/src/main.cpp new file mode 100644 index 0000000..fd3e533 --- /dev/null +++ b/src/main.cpp @@ -0,0 +1,11 @@ +#include "mainwindow.h" + +#include + +int main(int argc, char *argv[]) +{ + QApplication a(argc, argv); + MainWindow w; + w.show(); + return a.exec(); +} diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp new file mode 100644 index 0000000..156df67 --- /dev/null +++ b/src/mainwindow.cpp @@ -0,0 +1,23 @@ +#include "mainwindow.h" +#include "./ui_mainwindow.h" + +#include + +MainWindow::MainWindow(QWidget *parent) + : QMainWindow(parent) + , ui(new Ui::MainWindow) +{ + ui->setupUi(this); + QMetaObject::connectSlotsByName(this); +} + +MainWindow::~MainWindow() +{ + delete ui; +} + +void MainWindow::on_actionOpen_triggered(bool checked) { + QMessageBox msgBox; + msgBox.setText("It works!"); + msgBox.exec(); +} diff --git a/src/mainwindow.h b/src/mainwindow.h new file mode 100644 index 0000000..c2ab2b3 --- /dev/null +++ b/src/mainwindow.h @@ -0,0 +1,25 @@ +#ifndef MAINWINDOW_H +#define MAINWINDOW_H + +#include +#include + +QT_BEGIN_NAMESPACE +namespace Ui { class MainWindow; } +QT_END_NAMESPACE + +class MainWindow : public QMainWindow +{ + Q_OBJECT + +public: + MainWindow(QWidget *parent = nullptr); + ~MainWindow(); + +private slots: + void on_actionOpen_triggered(bool checked); + +private: + Ui::MainWindow *ui; +}; +#endif // MAINWINDOW_H diff --git a/src/mainwindow.ui b/src/mainwindow.ui new file mode 100644 index 0000000..3e949cf --- /dev/null +++ b/src/mainwindow.ui @@ -0,0 +1,173 @@ + + + MainWindow + + + + 0 + 0 + 800 + 600 + + + + Actor Viewer + + + + + + + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;"> +<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-style:italic;">Select Status to display from list.</span></p></body></html> + + + + + + + + + 0 + 0 + 800 + 30 + + + + + File + + + + + + + Help + + + + + + View + + + + + + + + + + + + + + + + + false + + + Open... + + + Open... + + + Open... + + + Open a Mastodon data archive + + + Ctrl+O + + + + + Quit + + + Ctrl+Q + + + QAction::QuitRole + + + + + About + + + QAction::AboutRole + + + + + true + + + true + + + All toots + + + + + true + + + Public toots + + + + + true + + + Unlisted toots + + + + + true + + + Private toots + + + + + true + + + Direct messages + + + + + true + + + Only with attachment + + + Only list toots that have an attachment + + + + + listWidget + textBrowser + + + + -- cgit v1.2.3-54-g00ecf