Skip to content

Commit

Permalink
scide: Fix missing icon
Browse files Browse the repository at this point in the history
  • Loading branch information
Nathan Ho committed Jan 24, 2019
1 parent e567b99 commit 42b6b72
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 12 deletions.
5 changes: 3 additions & 2 deletions editors/sc-ide/core/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,9 @@ int main( int argc, char *argv[] )
// Go...
MainWindow *win = new MainWindow(main);

app.setWindowIcon(QIcon("qrc:///icons/sc-ide-svg"));

// Unfortunately, the SVG icon shows up as a tiny dot on some Linux window
// managers (see #3905, #2646). Best we can do here is a PNG.
// app.setWindowIcon(QIcon(":icons/sc-ide-svg"));
// NOTE: load session after GUI is created, so that GUI can respond
Settings::Manager *settings = main->settings();
SessionManager *sessions = main->sessionManager();
Expand Down
22 changes: 12 additions & 10 deletions editors/sc-ide/widgets/main_window.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,16 +227,18 @@ MainWindow::MainWindow(Main * main) :
updateRecentDocsMenu();

QIcon icon;
icon.addFile(":/icons/sc-ide-svg");
icon.addFile(":/icons/sc-ide-16");
icon.addFile(":/icons/sc-ide-24");
icon.addFile(":/icons/sc-ide-32");
icon.addFile(":/icons/sc-ide-48");
icon.addFile(":/icons/sc-ide-64");
icon.addFile(":/icons/sc-ide-128");
icon.addFile(":/icons/sc-ide-256");
icon.addFile(":/icons/sc-ide-512");
icon.addFile(":/icons/sc-ide-1024");
// Unfortunately, the SVG icon shows up as a tiny dot on some Linux window
// managers (see #3905, #2646). Best we can do here is PNGs.
// icon.addFile(":icons/sc-ide-svg");
icon.addFile(":icons/sc-ide-16");
icon.addFile(":icons/sc-ide-24");
icon.addFile(":icons/sc-ide-32");
icon.addFile(":icons/sc-ide-48");
icon.addFile(":icons/sc-ide-64");
icon.addFile(":icons/sc-ide-128");
icon.addFile(":icons/sc-ide-256");
icon.addFile(":icons/sc-ide-512");
icon.addFile(":icons/sc-ide-1024");
QApplication::setWindowIcon(icon);

updateWindowTitle();
Expand Down

0 comments on commit 42b6b72

Please sign in to comment.