chore: move to qt/ directory

This commit is contained in:
Eshan Roy (Eshanized)
2024-04-30 23:00:15 +05:30
parent be4ab50c7a
commit c5e736257a
4 changed files with 0 additions and 0 deletions

11
qt/main.cpp Normal file
View File

@@ -0,0 +1,11 @@
#include "snigdhaosassistant.h"
#include <QApplication>
int main(int argc, char* argv[])
{
QApplication a(argc, argv);
SetupAssistant w(nullptr, a.arguments().length() > 1 ? a.arguments()[1] : "");
w.show();
return a.exec();
}

393
qt/snigdhaosassistant.cpp Normal file
View File

@@ -0,0 +1,393 @@
/*
* Original Author : Garuda Linux & Team.
* Thanks for developing this application.
* love from Bangladesh
*/
#include "snigdhaosassistant.h"
#include "./ui_snigdhaosassistant.h"
#include <QCheckBox>
#include <QDebug>
#include <QFileInfo>
#include <QProcess>
#include <QScrollArea>
#include <QTemporaryFile>
#include <QTimer>
#include <QtNetwork/QNetworkReply>
#include <unistd.h>
const char* INTERNET_CHECK_URL = "https://snigdhaos.org";
SnigdhaOSAssistant::SnigdhaOSAssistant(QWidget *parent, QString state)
: QMainWindow(parent)
, ui(new Ui::SnigdhaOSAssistant)
{
this->setWindowIcon(QIcon("/usr/share/pixmaps/snigdhaos-assistant.svg"));
ui->setupUi(this);
this->setWindowFlags(this->windowFlags() & ~Qt::WindowCloseButtonHint);
executable_modify_date = QFileInfo(QCoreApplication::applicationFilePath()).lastModified();
updateState(state);
}
SnigdhaOSAssistant::~SnigdhaOSAssistant()
{
delete ui;
}
void SnigdhaOSAssistant::doInternetUpRequest(){
QNetworkAccessManager* network_manager = new QNetworkAccessManager();
auto network_reply = network_manager->head(QNetworkRequest(QString(INTERNET_CHECK_URL)));
QTimer* timer = new QTimer(this);
timer->setSingleShot(true);
timer->start(5000);
// Did we time out? Try again!
connect(timer, &QTimer::timeout, this, [this, timer, network_reply, network_manager]() {
timer->deleteLater();
network_reply->abort();
network_reply->deleteLater();
network_manager->deleteLater();
doInternetUpRequest();
});
// Request is done!
connect(network_reply, &QNetworkReply::finished, this, [this, timer, network_reply, network_manager]() {
timer->stop();
timer->deleteLater();
network_reply->deleteLater();
network_manager->deleteLater();
if (network_reply->error() == network_reply->NoError) {
// Wooo!
updateState(State::UPDATE);
}
// Boo!
else
doInternetUpRequest();
});
}
void SnigdhaOSAssistant::doUpdate(){
if (qEnvironmentVariableIsSet("SETUP_ASSISTANT_SELFUPDATE")) {
updateState(State::SELECT);
return;
}
auto process = new QProcess(this);
QTemporaryFile* file = new QTemporaryFile(this);
file->open();
file->setAutoRemove(true);
process->start("/usr/bin/exec-terminal", QStringList() << QString("sudo pacman -Syyu 2>&1 && rm \"" + file->fileName() + "\"; read -p 'Press enter to exit'"));
connect(process, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), this, [this, process, file](int exitcode, QProcess::ExitStatus status) {
process->deleteLater();
file->deleteLater();
if (exitcode == 0 && !file->exists()) {
relaunchSelf("POST_UPDATE");
} else {
relaunchSelf("UPDATE_RETRY");
}
});
}
void SnigdhaOSAssistant::doApply(){
QStringList packages;
QStringList setup_commands;
QStringList prepare_commands;
auto checkboxList = ui->selectWidget_tabs->findChildren<QCheckBox*>();
for (auto checkbox : checkboxList) {
if (checkbox->isChecked()) {
packages += checkbox->property("packages").toStringList();
setup_commands += checkbox->property("setup_commands").toStringList();
prepare_commands += checkbox->property("prepare_commands").toStringList();
}
}
if (packages.empty()) {
updateState(State::SUCCESS);
return;
}
if (packages.contains("libreoffice-fresh"))
packages.removeAll("libreoffice-still");
if (packages.contains("podman"))
setup_commands += "systemctl enable --now podman.socket";
if (packages.contains("docker"))
setup_commands += "systemctl enable --now docker.socket";
if (packages.contains("virt-manager-meta") && packages.contains("gnome-boxes"))
setup_commands += "systemctl enable --now libvirtd";
packages.removeDuplicates();
QTemporaryFile* prepareFile = new QTemporaryFile(this);
prepareFile->setAutoRemove(true);
prepareFile->open();
QTextStream prepareStream(prepareFile);
prepareStream << prepare_commands.join('\n');
prepareFile->close();
QTemporaryFile* packagesFile = new QTemporaryFile(this);
packagesFile->setAutoRemove(true);
packagesFile->open();
QTextStream packagesStream(packagesFile);
packagesStream << packages.join(' ');
packagesFile->close();
QTemporaryFile* setupFile = new QTemporaryFile(this);
setupFile->setAutoRemove(true);
setupFile->open();
QTextStream setupStream(setupFile);
setupStream << setup_commands.join('\n');
setupFile->close();
auto process = new QProcess(this);
process->start("/usr/bin/exec-terminal", QStringList() << QString("/usr/lib/snigdhaos-assistant/apply.sh \"") + prepareFile->fileName() + "\" \"" + packagesFile->fileName() + "\" \"" + setupFile->fileName() + "\"");
connect(process, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), this, [this, process, prepareFile, packagesFile, setupFile](int exitcode, QProcess::ExitStatus status) {
process->deleteLater();
prepareFile->deleteLater();
packagesFile->deleteLater();
setupFile->deleteLater();
if (exitcode == 0 && !packagesFile->exists()) {
updateState(State::SUCCESS);
} else {
updateState(State::APPLY_RETRY);
}
});
}
void SnigdhaOSAssistant::doNvidiaCheck(){
auto process = new QProcess(this);
process->start("mhwd", QStringList() << "-li"
<< "--pci");
connect(process, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), this, [this, process](int exitcode, QProcess::ExitStatus status) {
process->deleteLater();
if (exitcode == 0 && !QString(process->readAllStandardOutput()).contains("nvidia")) {
auto process2 = new QProcess(this);
process2->start("mhwd", QStringList() << "-l"
<< "--pci");
connect(process2, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), this, [this, process2](int exitcode, QProcess::ExitStatus status) {
process2->deleteLater();
if (exitcode == 0 && QString(process2->readAllStandardOutput()).contains("nvidia"))
updateState(State::NVIDIA);
else
updateState(State::SELECT);
});
} else {
updateState(State::SELECT);
}
});
}
void SnigdhaOSAssistant::doNvidiaApply(){
auto process = new QProcess(this);
process->start("/usr/bin/exec-terminal", QStringList() << "sudo mhwd -a pci nonfree 0300; echo; read -p 'Press enter to exit'");
connect(process, QOverload<int, QProcess::ExitStatus>::of(&QProcess::finished), this, [this, process](int exitcode, QProcess::ExitStatus status) {
process->deleteLater();
updateState(State::SELECT);
});
}
void SnigdhaOSAssistant::populateSelectWidget(){
if (ui->selectWidget_tabs->count() > 1)
return;
auto desktop = qEnvironmentVariable("XDG_SESSION_DESKTOP");
ui->checkBox_GNOME->setVisible(desktop == "gnome");
ui->checkBox_KDE->setVisible(desktop == "kde");
if (desktop == "kde") {
ui->checkBox_Samba->setProperty("packages", QStringList { "printer-support", "scanner-support", "samba-support", "kdenetwork-filesharing", "skanpage" "smb4k", "print-manager", "skanlite" });
} else if (desktop == "gnome") {
ui->checkBox_Samba->setProperty("packages", QStringList { "printer-support", "scanner-support", "samba-support", "gvfs-smb", "simple-scan" });
} else {
ui->checkBox_Samba->setProperty("packages", QStringList { "printer-support", "scanner-support", "samba-support", "gvfs-smb", "simple-scan", "system-config-printer" });
}
bool isDesktop = false;
auto chassis = QFile("/sys/class/dmi/id/chassis_type");
if (chassis.open(QFile::ReadOnly)) {
QStringList list = { "3", "4", "6", "7", "23", "24" };
QTextStream in(&chassis);
isDesktop = list.contains(in.readLine());
}
ui->checkBox_Performance->setVisible(isDesktop);
populateSelectWidget("/usr/lib/snigdhaos-assistant/input-method.txt", "Input");
populateSelectWidget("/usr/lib/snigdhaos-assistant/pkgmngrs.txt", "Software centers");
populateSelectWidget("/usr/lib/snigdhaos-assistant/kernels.txt", "Kernels");
populateSelectWidget("/usr/lib/snigdhaos-assistant/office.txt", "Office");
populateSelectWidget("/usr/lib/snigdhaos-assistant/browsers.txt", "Browsers");
populateSelectWidget("/usr/lib/snigdhaos-assistant/mail.txt", "Email");
populateSelectWidget("/usr/lib/snigdhaos-assistant/communication.txt", "Communication");
populateSelectWidget("/usr/lib/snigdhaos-assistant/internet.txt", "Internet");
populateSelectWidget("/usr/lib/snigdhaos-assistant/audio.txt", "Audio");
populateSelectWidget("/usr/lib/snigdhaos-assistant/video.txt", "Video");
populateSelectWidget("/usr/lib/snigdhaos-assistant/graphics.txt", "Graphics");
populateSelectWidget("/usr/lib/snigdhaos-assistant/multimedia.txt", "Multimedia");
populateSelectWidget("/usr/lib/snigdhaos-assistant/development.txt", "Development");
populateSelectWidget("/usr/lib/snigdhaos-assistant/virtualization.txt", "Virtualization");
populateSelectWidget("/usr/lib/snigdhaos-assistant/other.txt", "Other");
}
void SnigdhaOSAssistant::populateSelectWidget(QString filename, QString label){
QFile file(filename);
if (file.open(QIODevice::ReadOnly)) {
QScrollArea* scroll = new QScrollArea(ui->selectWidget_tabs);
QWidget* tab = new QWidget(scroll);
QVBoxLayout* layout = new QVBoxLayout(tab);
QTextStream in(&file);
while (!in.atEnd()) {
QString def = in.readLine();
QString packages = in.readLine();
QString display = in.readLine();
auto checkbox = new QCheckBox(tab);
checkbox->setChecked(def == "true");
checkbox->setText(display);
checkbox->setProperty("packages", packages.split(" "));
layout->addWidget(checkbox);
}
scroll->setWidget(tab);
ui->selectWidget_tabs->addTab(scroll, label);
file.close();
}
}
void SnigdhaOSAssistant::updateState(State state){
if (currentState != state) {
currentState = state;
this->show();
this->activateWindow();
this->raise();
switch (state) {
case State::WELCOME:
ui->mainStackedWidget->setCurrentWidget(ui->textWidget);
ui->textStackedWidget->setCurrentWidget(ui->textWidget_welcome);
ui->textWidget_buttonBox->setStandardButtons(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
break;
case State::INTERNET:
ui->mainStackedWidget->setCurrentWidget(ui->waitingWidget);
ui->waitingWidget_text->setText("Waiting for an internet connection...");
doInternetUpRequest();
break;
case State::UPDATE:
ui->mainStackedWidget->setCurrentWidget(ui->waitingWidget);
ui->waitingWidget_text->setText("Waiting for update to finish...");
doUpdate();
break;
case State::UPDATE_RETRY:
ui->mainStackedWidget->setCurrentWidget(ui->textWidget);
ui->textStackedWidget->setCurrentWidget(ui->textWidget_updateRetry);
ui->textWidget_buttonBox->setStandardButtons(QDialogButtonBox::Yes | QDialogButtonBox::No);
break;
case State::NVIDIA_CHECK:
ui->mainStackedWidget->setCurrentWidget(ui->waitingWidget);
ui->waitingWidget_text->setText("Checking for NVIDIA drivers...");
doNvidiaCheck();
break;
case State::NVIDIA:
ui->mainStackedWidget->setCurrentWidget(ui->textWidget);
ui->textStackedWidget->setCurrentWidget(ui->textWidget_nvidia);
ui->textWidget_buttonBox->setStandardButtons(QDialogButtonBox::Yes | QDialogButtonBox::No);
break;
case State::NVIDIA_APPLY:
ui->mainStackedWidget->setCurrentWidget(ui->waitingWidget);
ui->waitingWidget_text->setText("Installing NVIDIA drivers...");
doNvidiaApply();
break;
case State::QUIT:
ui->mainStackedWidget->setCurrentWidget(ui->textWidget);
ui->textStackedWidget->setCurrentWidget(ui->textWidget_quit);
ui->textWidget_buttonBox->setStandardButtons(QDialogButtonBox::Ok | QDialogButtonBox::Reset);
break;
case State::SELECT:
ui->mainStackedWidget->setCurrentWidget(ui->selectWidget);
populateSelectWidget();
break;
case State::APPLY:
ui->mainStackedWidget->setCurrentWidget(ui->waitingWidget);
ui->waitingWidget_text->setText("Applying...");
doApply();
break;
case State::APPLY_RETRY:
ui->mainStackedWidget->setCurrentWidget(ui->textWidget);
ui->textStackedWidget->setCurrentWidget(ui->textWidget_applyRetry);
ui->textWidget_buttonBox->setStandardButtons(QDialogButtonBox::Yes | QDialogButtonBox::No | QDialogButtonBox::Reset);
break;
case State::SUCCESS:
ui->mainStackedWidget->setCurrentWidget(ui->textWidget);
ui->textStackedWidget->setCurrentWidget(ui->textWidget_success);
ui->textWidget_buttonBox->setStandardButtons(QDialogButtonBox::Ok);
break;
}
}
}
void SnigdhaOSAssistant::updateState(){
if (state == "POST_UPDATE")
updateState(State::NVIDIA_CHECK);
else if (state == "UPDATE_RETRY")
updateState(State::UPDATE_RETRY);
else
updateState(State::WELCOME);
}
void SnigdhaOSAssistant::relaunchSelf(){
auto binary = QFileInfo(QCoreApplication::applicationFilePath());
if (executable_modify_date != binary.lastModified()) {
execlp(binary.absoluteFilePath().toUtf8().constData(), binary.fileName().toUtf8().constData(), param.toUtf8().constData(), NULL);
exit(0);
} else
updateState(param);
}
void SnigdhaOSAssistant::on_textWidget_buttonBox_clicked(){
switch (currentState) {
case State::WELCOME:
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Ok) {
updateState(State::INTERNET);
}
break;
case State::UPDATE_RETRY:
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Yes) {
updateState(State::INTERNET);
}
break;
case State::NVIDIA:
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Yes)
updateState(State::NVIDIA_APPLY);
else
updateState(State::SELECT);
return;
case State::APPLY_RETRY:
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Yes) {
updateState(State::APPLY);
} else if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Reset) {
updateState(State::SELECT);
}
break;
case State::SUCCESS:
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Ok) {
QApplication::quit();
}
break;
case State::QUIT:
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::No || ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Ok) {
QApplication::quit();
} else
updateState(State::WELCOME);
break;
default:;
}
if (ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::No || ui->textWidget_buttonBox->standardButton(button) == QDialogButtonBox::Cancel) {
updateState(State::QUIT);
}
}
void SnigdhaOSAssistant::on_selectWidget_buttonBox_clicked(QAbstractButton* button){
if (ui->selectWidget_buttonBox->standardButton(button) == QDialogButtonBox::Ok) {
updateState(State::APPLY);
} else
updateState(State::QUIT);
}

63
qt/snigdhaosassistant.h Normal file
View File

@@ -0,0 +1,63 @@
/*
* Original Author : Garuda Linux & Team.
* Thanks for developing this application.
* love from Bangladesh
*/
#ifndef SNIGDHAOSASSISTANT_H
#define SNIGDHAOSASSISTANT_H
#include <QMainWindow>
#include <QAbstractButton>
#include <QtNetwork/QNetworkAccessManager>
QT_BEGIN_NAMESPACE
namespace Ui {
class SnigdhaOSAssistant;
}
QT_END_NAMESPACE
class SnigdhaOSAssistant : public QMainWindow
{
Q_OBJECT
public:
enum class State {
QUIT,
WELCOME,
INTERNET,
UPDATE,
UPDATE_RETRY,
NVIDIA_CHECK,
NVIDIA,
NVIDIA_APPLY,
SELECT,
APPLY,
APPLY_RETRY,
SUCCESS
};
SnigdhaOSAssistant(QWidget* parent = nullptr, QString state = "WELCOME");
~SnigdhaOSAssistant();
private slots:
void on_textWidget_buttonBox_clicked(QAbstractButton* button);
void on_selectWidget_buttonBox_clicked(QAbstractButton* button);
private:
Ui::SnigdhaOSAssistant *ui;
QDateTime executable_modify_date;
State currentState;
void doInternetUpRequest();
void doUpdate();
void doApply();
void doNvidiaCheck();
void doNvidiaApply();
void populateSelectWidget();
void populateSelectWidget(QString filename, QString label);
void updateState(State state);
void updateState(QString state);
void relaunchSelf(QString param);
};
#endif // SNIGDHAOSASSISTANT_H

520
qt/snigdhaosassistant.ui Normal file
View File

@@ -0,0 +1,520 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>SnigdhaOSAssistant</class>
<widget class="QMainWindow" name="SnigdhaOSAssistant">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>800</width>
<height>600</height>
</rect>
</property>
<property name="windowTitle">
<string>SnigdhaOSAssistant</string>
</property>
<widget class="QWidget" name="centralwidget">
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QStackedWidget" name="mainStackedWidget">
<property name="currentIndex">
<number>0</number>
</property>
<widget class="QWidget" name="textWidget">
<layout class="QGridLayout" name="gridLayout_2">
<item row="3" column="0">
<widget class="QDialogButtonBox" name="textWidget_buttonBox">
<property name="enabled">
<bool>true</bool>
</property>
<property name="standardButtons">
<set>QDialogButtonBox::StandardButton::Cancel|QDialogButtonBox::StandardButton::Ok</set>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QStackedWidget" name="textStackedWidget">
<property name="currentIndex">
<number>4</number>
</property>
<widget class="QWidget" name="textWidget_welcome">
<layout class="QGridLayout" name="gridLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:24pt;&quot;&gt;Welcome to Snigdha OS!&lt;/span&gt;&lt;br/&gt;This interactive assistant will help you set up your system to your wishes.&lt;/p&gt;&lt;p&gt;Before the setup assistant can continue, initial system updates have to be applied and the Snigdha OS Assistant updated.&lt;br/&gt;Make sure you have a working internet connection before you continue.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::TextFormat::RichText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="textWidget_updateRetry">
<layout class="QGridLayout" name="gridLayout_5">
<item row="0" column="0">
<widget class="QLabel" name="label_2">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:20pt;&quot;&gt;Update failed!&lt;/span&gt;&lt;br/&gt;System update failed. Try again?&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://forum.snigdhaos.org&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Visit the Snigdha OS Forum&lt;/span&gt;&lt;/a&gt; if further issues occour.&lt;br/&gt;Finishing this update via the Snigdha OS Assistant is highly recommended in order to apply release-specific fixes.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::TextFormat::RichText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="textWidget_nvidia">
<layout class="QGridLayout" name="gridLayout_11">
<item row="0" column="0">
<widget class="QLabel" name="label_6">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:20pt;&quot;&gt;NVIDIA drivers&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Additional nonfree NVIDIA graphics drivers are available. Do you want to install them?&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::TextFormat::RichText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="textWidget_applyRetry">
<layout class="QGridLayout" name="gridLayout_8">
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:20pt;&quot;&gt;Failed to Apply😒!&lt;/span&gt;&lt;br/&gt;Applying system changes failed. Try again😄?&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://forum.snigdhaos.org&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Visit the Snigdha OS Forum&lt;/span&gt;&lt;/a&gt; if further issues occour.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::TextFormat::RichText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="textWidget_success">
<layout class="QGridLayout" name="gridLayout_9">
<item row="0" column="0">
<widget class="QLabel" name="label_5">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:20pt;&quot;&gt;Success!&lt;/span&gt;&lt;br/&gt;Your system is set up and ready to go!&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://forum.snigdhais.org&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Visit the Snigdha OS Forum&lt;/span&gt;&lt;/a&gt; if issues occour.&lt;br/&gt;&lt;a href=&quot;https://snigdhaos.org/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Snigdha OS Documentation&lt;br/&gt;&lt;/span&gt;&lt;/a&gt;&lt;a href=&quot;https://wiki.archlinux.org/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Arch Linux Wiki&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::TextFormat::RichText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="textWidget_quit">
<layout class="QGridLayout" name="gridLayout_6">
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Maximum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:20pt;&quot;&gt;Before you go&lt;/span&gt;&lt;/p&gt;&lt;p&gt;You can restart the setup assistant at any time.&lt;br/&gt;Finishing the Snigdha OS Assistant is recommended in order to apply release-specific fixes.&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://forum.snigdhaos.org&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Visit the Snigdha OS Forum&lt;/span&gt;&lt;/a&gt; if issues occour.&lt;br/&gt;&lt;a href=&quot;https://snigdhaos.org/documentation/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Snigdha OS Documentation&lt;br/&gt;&lt;/span&gt;&lt;/a&gt;&lt;a href=&quot;https://wiki.archlinux.org/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#754ffe;&quot;&gt;Arch Linux Wiki&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::TextFormat::RichText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="waitingWidget">
<layout class="QGridLayout" name="gridLayout_4">
<item row="3" column="0">
<spacer name="verticalSpacer_2">
<property name="orientation">
<enum>Qt::Orientation::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="0">
<widget class="QProgressBar" name="progressBar">
<property name="maximum">
<number>0</number>
</property>
<property name="value">
<number>0</number>
</property>
</widget>
</item>
<item row="0" column="0">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Orientation::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item row="2" column="0">
<widget class="QLabel" name="waitingWidget_text">
<property name="text">
<string>TextLabel</string>
</property>
<property name="alignment">
<set>Qt::AlignmentFlag::AlignCenter</set>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="selectWidget">
<layout class="QGridLayout" name="gridLayout_7">
<item row="0" column="0">
<widget class="QTabWidget" name="selectWidget_tabs">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Ignored">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="currentIndex">
<number>0</number>
</property>
<property name="elideMode">
<enum>Qt::TextElideMode::ElideNone</enum>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
<string>OS preferences</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_10">
<item row="15" column="0">
<spacer name="verticalSpacer_3">
<property name="orientation">
<enum>Qt::Orientation::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>344</height>
</size>
</property>
</spacer>
</item>
<item row="14" column="0">
<widget class="QCheckBox" name="checkBox_Blackarch">
<property name="text">
<string>Do you need Pentesting software? (installs BlackArch repo + settings)</string>
</property>
<property name="packages" stdset="0">
<stringlist notr="true">
<string>garuda-blackarch</string>
<string>blackarch-keyring</string>
<string>blackarch-menus</string>
<string>blackarch-mirrorlist</string>
</stringlist>
</property>
<property name="prepare_commands" stdset="0">
<stringlist notr="true">
<string>sh &lt;(wget -qO- https://blackarch.org/strap.sh)</string>
</stringlist>
</property>
<property name="setup_commands" stdset="0">
<stringlist notr="true">
<string>sed -i 's/#server/server/g' /etc/pacman.d/blackarch-mirrorlist</string>
</stringlist>
</property>
</widget>
</item>
<item row="6" column="0">
<widget class="QCheckBox" name="checkBox_Wallpaper">
<property name="text">
<string>Do you want to install additional Snigdha OS wallpapers?</string>
</property>
<property name="packages" stdset="0">
<stringlist notr="true">
<string>snigdhaos-additional-wallpapers</string>
</stringlist>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QCheckBox" name="checkBox_GNOME">
<property name="text">
<string>Do you want to install additional GNOME applications?</string>
</property>
<property name="packages" stdset="0">
<stringlist notr="true">
<string>nautilus-image-converter</string>
<string>nautilus-share</string>
<string>nautilus-sendto</string>
<string>eog-plugins</string>
<string>grilo-plugins</string>
<string>gnome-logs</string>
<string>gnome-sound-recorder</string>
<string>gnome-user-share</string>
<string>lollypop</string>
<string>celluloid</string>
</stringlist>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QCheckBox" name="checkBox_KDE">
<property name="text">
<string>Do you want to install additional KDE components and applications?</string>
</property>
<property name="packages" stdset="0">
<stringlist notr="true">
<string>appmenu-gtk-module</string>
<string>ark</string>
<string>bluedevil</string>
<string>breeze</string>
<string>breeze-gtk</string>
<string>colord-kde</string>
<string>dolphin-plugins</string>
<string>drkonqi</string>
<string>filelight</string>
<string>ffmpegthumbs</string>
<string>gwenview</string>
<string>icoutils</string>
<string>kaccounts-providers</string>
<string>kactivitymanagerd</string>
<string>kamera</string>
<string>kamoso</string>
<string>kate</string>
<string>kcalc</string>
<string>kcron</string>
<string>kde-cli-tools</string>
<string>kde-gtk-config</string>
<string>kde-service-menu-reimage</string>
<string>kde-servicemenus-encfs</string>
<string>kde-servicemenus-komparemenu</string>
<string>kde-servicemenus-pdf</string>
<string>kde-servicemenus-pdf-encrypt-decrypt</string>
<string>kde-servicemenus-officeconverter</string>
<string>kde-servicemenus-sendtodesktop</string>
<string>kde-servicemenus-setaswallpaper</string>
<string>kdeconnect</string>
<string>kdecoration</string>
<string>kdegraphics-thumbnailers</string>
<string>kdeplasma-addons</string>
<string>kdf</string>
<string>kdialog</string>
<string>keditbookmarks</string>
<string>kfind</string>
<string>kgamma5</string>
<string>khelpcenter</string>
<string>khotkeys</string>
<string>kimageformats</string>
<string>kinfocenter</string>
<string>kio-extras</string>
<string>kio-fuse</string>
<string>kio-gdrive</string>
<string>kleopatra</string>
<string>kmenuedit</string>
<string>kompare</string>
<string>konsole</string>
<string>krdc</string>
<string>krename</string>
<string>krfb</string>
<string>kscreen</string>
<string>ksshaskpass</string>
<string>ksystemlog</string>
<string>kwalletmanager</string>
<string>kwrited</string>
<string>milou</string>
<string>okular</string>
<string>partitionmanager</string>
<string>plasma-browser-integration</string>
<string>plasma-desktop</string>
<string>plasma-disks</string>
<string>plasma-firewall</string>
<string>plasma-integration</string>
<string>plasma-nm</string>
<string>plasma-pa</string>
<string>plasma-systemmonitor</string>
<string>plasma-thunderbolt</string>
<string>plasma-vault</string>
<string>plasma-workspace</string>
<string>plasma-workspace-wallpapers</string>
<string>polkit-kde-agent</string>
<string>powerdevil</string>
<string>qt5-imageformats</string>
<string>quota-tools</string>
<string>resvg</string>
<string>rootactions-servicemenu</string>
<string>ruby</string>
<string>spectacle</string>
<string>systemsettings</string>
<string>yakuake</string>
</stringlist>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QCheckBox" name="checkBox_Performance">
<property name="text">
<string>Do you want to apply additional performance tweaks? (at the cost of power usage/heat)</string>
</property>
<property name="packages" stdset="0">
<stringlist notr="true">
<string>performance-tweaks</string>
</stringlist>
</property>
</widget>
</item>
<item row="16" column="0">
<spacer name="verticalSpacer_3">
<property name="orientation">
<enum>Qt::Orientation::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>344</height>
</size>
</property>
</spacer>
</item>
<item row="4" column="0">
<widget class="QCheckBox" name="checkBox_Samba">
<property name="text">
<string>Do you need Printer, Scanner and Samba Support?</string>
</property>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
<item row="1" column="0">
<widget class="QDialogButtonBox" name="selectWidget_buttonBox">
<property name="standardButtons">
<set>QDialogButtonBox::StandardButton::Cancel|QDialogButtonBox::StandardButton::Ok</set>
</property>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
</widget>
<resources/>
<connections/>
</ui>