Move app icon definition to main.cpp

Tue, 28 Jun 2022 12:47:46 +0300

author
Teemu Piippo <teemu.s.piippo@gmail.com>
date
Tue, 28 Jun 2022 12:47:46 +0300
changeset 284
9266239cf72b
parent 283
96b7eb68e9e6
child 285
99af8bf63d10

Move app icon definition to main.cpp

src/main.cpp file | annotate | diff | comparison | revisions
src/mainwindow.ui file | annotate | diff | comparison | revisions
--- a/src/main.cpp	Tue Jun 28 12:29:38 2022 +0300
+++ b/src/main.cpp	Tue Jun 28 12:47:46 2022 +0300
@@ -402,6 +402,7 @@
 {
 	doQtRegistrations();
 	QApplication app{argc, argv};
+	QApplication::setWindowIcon(QIcon{":/icons/appicon.png"});
 	QMainWindow mainWindow;
 	Ui_MainWindow ui;
 	DocumentManager documents;
--- a/src/mainwindow.ui	Tue Jun 28 12:29:38 2022 +0300
+++ b/src/mainwindow.ui	Tue Jun 28 12:47:46 2022 +0300
@@ -10,10 +10,6 @@
     <height>600</height>
    </rect>
   </property>
-  <property name="windowIcon">
-   <iconset resource="../resources.qrc">
-    <normaloff>:/icons/appicon.png</normaloff>:/icons/appicon.png</iconset>
-  </property>
   <property name="dockNestingEnabled">
    <bool>false</bool>
   </property>
@@ -43,7 +39,7 @@
      <x>0</x>
      <y>0</y>
      <width>729</width>
-     <height>41</height>
+     <height>35</height>
     </rect>
    </property>
    <widget class="QMenu" name="menuFile">

mercurial