1
0

Ignore OS styles and remove window decorations

This commit is contained in:
ami-sc 2024-01-14 20:12:38 -06:00
parent 11e862b06c
commit 3c88173ca9

View File

@ -1,14 +1,24 @@
#include <QApplication> #include <QApplication>
#include <QMainWindow>
#include "MainWindow.hpp"
int main (int argc, char* argv[]) int main (int argc, char* argv[])
{ {
QApplication Ensemble(argc, argv); QApplication Ensemble(argc, argv);
/* Ignore color schemes and styles of the operating system. */
QApplication::setStyle("fusion");
QApplication::setDesktopSettingsAware(false);
QCoreApplication::setApplicationName("Ensemble"); QCoreApplication::setApplicationName("Ensemble");
QCoreApplication::setApplicationVersion("0.1"); QCoreApplication::setApplicationVersion("0.1");
QMainWindow main_window {}; /* Build the main window of the application. */
MainWindow main_window;
/* Disable window frame and title bar. */
main_window.setWindowFlags(Qt::Window | Qt::FramelessWindowHint);
main_window.show(); main_window.show();
return Ensemble.exec(); return Ensemble.exec();