@@ -109,9 +109,13 @@ MainWindow::MainWindow(QWidget* parent)
109109 , m_nameFetchSearchId(0 )
110110 , m_hasCachedData(false )
111111{
112+ // Retrieve username first so UI reflects it correctly (Avatar initial)
113+ QSettings settings (" LuaPatcher" , " SteamLuaPatcher" );
114+ m_username = settings.value (" username" , " User" ).toString ();
115+
112116 setWindowTitle (" Steam Lua Patcher" );
113117 setMinimumSize (900 , 600 );
114- resize (1350 , 820 );
118+ resize (1480 , 900 );
115119 setAcceptDrops (true );
116120
117121 // ── Enable Transparency for Desktop Blur ──
@@ -127,10 +131,6 @@ MainWindow::MainWindow(QWidget* parent)
127131 // Apply Desktop Acrylic/Mica Blur
128132 enableAcrylicBlur ();
129133
130- // Retrieve username from settings (already checked in main.cpp)
131- QSettings settings (" LuaPatcher" , " SteamLuaPatcher" );
132- m_username = settings.value (" username" , " User" ).toString ();
133-
134134 m_debounceTimer = new QTimer (this );
135135 m_debounceTimer->setSingleShot (true );
136136 connect (m_debounceTimer, &QTimer::timeout, this , &MainWindow::doSearch);
@@ -561,7 +561,7 @@ void MainWindow::initUI() {
561561 for (QChar c : displayName) colorIdx += c.unicode ();
562562 QColor avatarColor = avatarColors[colorIdx % 8 ];
563563
564- int avatarSize = 36 ;
564+ int avatarSize = 40 ;
565565 QPixmap avatarPix (avatarSize, avatarSize);
566566 avatarPix.fill (Qt::transparent);
567567 QPainter avatarPainter (&avatarPix);
@@ -570,7 +570,7 @@ void MainWindow::initUI() {
570570 avatarPainter.setPen (Qt::NoPen);
571571 avatarPainter.drawEllipse (0 , 0 , avatarSize, avatarSize);
572572 avatarPainter.setPen (Qt::white);
573- QFont avatarFont (" Segoe UI" , 15 , QFont::Bold);
573+ QFont avatarFont (" Segoe UI" , 18 , QFont::Bold);
574574 avatarPainter.setFont (avatarFont);
575575 avatarPainter.drawText (QRect (0 , 0 , avatarSize, avatarSize), Qt::AlignCenter, QString (firstLetter));
576576 avatarPainter.end ();
@@ -613,14 +613,14 @@ void MainWindow::initUI() {
613613 m_mainScrollContainer = new QWidget ();
614614 m_mainScrollContainer->setStyleSheet (" background: transparent;" );
615615 m_mainScrollLayout = new QVBoxLayout (m_mainScrollContainer);
616- // Added horizontal padding (24px) so the banner and grid fit gracefully within the window bounds
617- m_mainScrollLayout->setContentsMargins (10 , 0 , 10 , 20 );
618- m_mainScrollLayout->setSpacing (16 );
616+ // Increased horizontal padding (15px) and spacing (10px) to perfectly fit the 175px game cards
617+ m_mainScrollLayout->setContentsMargins (15 , 0 , 15 , 20 );
618+ m_mainScrollLayout->setSpacing (10 );
619619
620620 // 1. Hero Stack — holds up to 4 trending games, shows exactly one at a time
621621 m_leadingTitlesLabel = new QLabel (" Leading Titles" );
622622 m_leadingTitlesLabel->setMaximumWidth (1200 );
623- m_leadingTitlesLabel->setStyleSheet (" font-size: 20px; font-weight: bold; padding-left: 4px ; color: white;" );
623+ m_leadingTitlesLabel->setStyleSheet (" font-size: 20px; font-weight: bold; padding-left: 0px ; color: white;" );
624624
625625 m_heroStack = new QStackedWidget ();
626626 m_heroStack->setFixedHeight (240 );
@@ -655,13 +655,13 @@ void MainWindow::initUI() {
655655
656656 // 3. All Games Grid
657657 m_gridTitleLabel = new QLabel (" All Available Games" );
658- m_gridTitleLabel->setStyleSheet (" font-size: 20px; font-weight: bold; padding-left: 4px ; color: white;" );
658+ m_gridTitleLabel->setStyleSheet (" font-size: 20px; font-weight: bold; padding-left: 0px ; color: white;" );
659659 m_mainScrollLayout->addWidget (m_gridTitleLabel);
660660
661661 m_gridContainer = new QWidget ();
662662 m_gridLayout = new QGridLayout (m_gridContainer);
663- m_gridLayout->setContentsMargins (4 , 4 , 4 , 4 );
664- m_gridLayout->setSpacing (14 );
663+ m_gridLayout->setContentsMargins (0 , 8 , 0 , 0 );
664+ m_gridLayout->setSpacing (12 ); // Optimized for 190px cards
665665 m_gridLayout->setAlignment (Qt::AlignLeft | Qt::AlignTop);
666666 m_mainScrollLayout->addWidget (m_gridContainer);
667667
0 commit comments