#include <QApplication>
#include <QFile>
#include <QFontDatabase>
#include <QFont>
#include "src/MainWindow.h"
#include <QCoreApplication>

int main(int argc, char *argv[])
{
    QCoreApplication::setOrganizationName("Flowy Labs, Inc");
    QCoreApplication::setOrganizationDomain("flowylabs.ai");
    QCoreApplication::setApplicationName("llink");

    QApplication a(argc, argv);
    a.setStyle("fusion");

    // // Load Plus Jakarta Sans fonts
    // int regularFontId = QFontDatabase::addApplicationFont(":/assets/Plus_Jakarta_Sans/PlusJakartaSans-VariableFont_wght.ttf");
    // int italicFontId = QFontDatabase::addApplicationFont(":/assets/Plus_Jakarta_Sans/PlusJakartaSans-Italic-VariableFont_wght.ttf");
    //
    // if (regularFontId != -1 && italicFontId != -1) {
    //     // Set as application-wide default font
    //     QFont appFont("Plus Jakarta Sans", 13);
    //     a.setFont(appFont);
    // }

    // Load reMarkable e-ink stylesheet
    // QFile styleFile(":/styles/remarkable.qss");
    // if (styleFile.open(QFile::ReadOnly | QFile::Text)) {
    //     a.setStyleSheet(styleFile.readAll());
    //     styleFile.close();
    // }

    MainWindow w;
    w.show();
    return a.exec();
}
