Added a shiny new AboutDlg
authorManuel Nickschas <sputnick@quassel-irc.org>
Fri, 8 Feb 2008 21:26:44 +0000 (21:26 +0000)
committerManuel Nickschas <sputnick@quassel-irc.org>
Fri, 8 Feb 2008 21:26:44 +0000 (21:26 +0000)
Quassel.kdevelop.filelist
src/qtui/aboutdlg.cpp [new file with mode: 0644]
src/qtui/aboutdlg.h [new file with mode: 0644]
src/qtui/mainwin.cpp
src/qtui/mainwin.h
src/qtui/qtui.pri
src/qtui/ui/aboutdlg.ui
src/qtui/ui/mainwin.ui
version.inc

index b6626fa..b3cad7b 100644 (file)
@@ -138,6 +138,8 @@ src/qtopia/ui/editcoreacctdlg.ui
 src/qtopia/ui/mainwidget.ui
 src/qtopia/ui/nicklistwidget.ui
 src/qtui
+src/qtui/aboutdlg.cpp
+src/qtui/aboutdlg.h
 src/qtui/bufferwidget.cpp
 src/qtui/bufferwidget.h
 src/qtui/chatitem.cpp
diff --git a/src/qtui/aboutdlg.cpp b/src/qtui/aboutdlg.cpp
new file mode 100644 (file)
index 0000000..32a23c3
--- /dev/null
@@ -0,0 +1,92 @@
+/***************************************************************************
+ *   Copyright (C) 2005-08 by the Quassel IRC Team                         *
+ *   devel@quassel-irc.org                                                 *
+ *                                                                         *
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) version 3.                                           *
+ *                                                                         *
+ *   This program is distributed in the hope that it will be useful,       *
+ *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
+ *   GNU General Public License for more details.                          *
+ *                                                                         *
+ *   You should have received a copy of the GNU General Public License     *
+ *   along with this program; if not, write to the                         *
+ *   Free Software Foundation, Inc.,                                       *
+ *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
+ ***************************************************************************/
+
+#include "aboutdlg.h"
+#include "global.h"
+
+AboutDlg::AboutDlg(QWidget *parent) : QDialog(parent) {
+  ui.setupUi(this);
+
+  ui.versionLabel->setText(QString("<b>Version %1, Build >= %2 (%3)</b>").arg(Global::quasselVersion).arg(Global::quasselBuild).arg(Global::quasselDate));
+  ui.aboutTextBrowser->setHtml(about());
+  ui.authorTextBrowser->setHtml(authors());
+  ui.contributorTextBrowser->setHtml(contributors());
+  ui.thanksToTextBrowser->setHtml(thanksTo());
+
+}
+
+QString AboutDlg::about() const {
+  QString res;
+  res = tr("<b>A modern, distributed IRC Client</b><br><br>"
+           "&copy;2005-2008 by the Quassel Project<br>"
+           "<a href=\"http://quassel-irc.org\">http://quassel-irc.org</a><br>"
+           "<a href=\"irc://irc.freenode.net/quassel\">#quassel</a> on <a href=\"http://www.freenode.net\">Freenode</a><br><br>"
+           "Quassel IRC is dual-licensed under <a href=\"http://www.gnu.org/licenses/gpl-2.0.txt\">GPLv2</a> and "
+                "<a href=\"http://www.gnu.org/licenses/gpl-3.0.txt\">GPLv3</a>.<br>"
+           "Most icons are &copy; by the <a href=\"http://www.oxygen-icons.org\">Oxygen Team</a> and used under the "
+                "<a href=\"http://www.gnu.org/licenses/lgpl.html\">LGPL</a>.<br><br>"
+           "Please use <a href=\"http://bugs.quassel-irc.org\">http://bugs.quassel-irc.org</a> to report bugs."
+          );
+
+  return res;
+}
+
+QString AboutDlg::authors() const {
+  QString res;
+  res = tr("Quassel IRC is mainly developed by:") +
+        "<dl>"
+        "<dt>Manuel \"Sputnick\" Nickschas</dt><dd><a href=\"mailto:sput@quassel-irc.org\">sput@quassel-irc.org</a><br>"
+             "Project Founder, Lead Developer</dd><br>"
+        "<dt>Marcus \"EgS\" Eggenberger</dt><dd><a href=\"mailto:egs@quassel-irc.org\">egs@quassel-irc.org</a><br>"
+             "Project Motivator, Lead Developer, Mac Maintainer</dd><br>"
+        "<dt>Alexander \"phon\" von Renteln</dt><dd><a href=\"mailto:alex@phon.name\">alex@phon.name</a><br>"
+             "Developer, Windows Maintainer</dd>"
+        "</dl>";
+
+  return res;
+}
+
+QString AboutDlg::contributors() const {
+  QString res;
+  res = tr("We would like to thank the following contributors (in alphabetical order) and everybody we forgot to mention here:") + "<br>"
+           "<dl>"
+           "<dt>Marco \"kaffeedoktor\" Genise</dt><dd><a href=\"mailto:kaffeedoktor@quassel-irc.org\">kaffeedoktor@quassel-irc.org</a><br>"
+                  "Ideas, Hacking, Motivation</dd><br>"
+           "<dt>Jonas \"Dante\" Heese</dt><dd>Project Founder, ebuilder</dd><br>"
+           "<dt>Daniel \"son\" Steinmetz</dt><dd>Early Beta Tester and Bughunter (on Vista&trade;!)</dd><br>"
+           "<dt>Adam \"adamt\" Tulinius</dt><dd>Early Beta Tester and Bughunter, Danish Translation</dd><br>"
+           "<dt>Pavel \"int\" Volkovitskiy</dt><dd>Early Beta Tester and Bughunter</dd><br>"
+           "</dl>";
+
+  return res;
+}
+
+QString AboutDlg::thanksTo() const {
+  QString res;
+  res = tr("Special thanks goes to:<br>"
+           "<dl>"
+           "<dt><a href=\"http://www.oxygen-icons.org\">The Oxygen Team</a></dt>"
+              "<dd>for creating most of the shiny icons you see throughout Quassel</dd><br>"
+           "<dt><a href=\"http://www.trolltech.com\">Trolltech</a></dt>"
+              "<dd>for creating Qt and Qtopia, and for sponsoring development of Quasseltopia with Greenphones and more</dd>"
+          );
+
+  return res;
+}
diff --git a/src/qtui/aboutdlg.h b/src/qtui/aboutdlg.h
new file mode 100644 (file)
index 0000000..d014153
--- /dev/null
@@ -0,0 +1,45 @@
+/***************************************************************************
+ *   Copyright (C) 2005-08 by the Quassel IRC Team                         *
+ *   devel@quassel-irc.org                                                 *
+ *                                                                         *
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) version 3.                                           *
+ *                                                                         *
+ *   This program is distributed in the hope that it will be useful,       *
+ *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
+ *   GNU General Public License for more details.                          *
+ *                                                                         *
+ *   You should have received a copy of the GNU General Public License     *
+ *   along with this program; if not, write to the                         *
+ *   Free Software Foundation, Inc.,                                       *
+ *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
+ ***************************************************************************/
+
+#ifndef ABOUTDLG_H_
+#define ABOUTDLG_H_
+
+#include <QDialog>
+
+#include "ui_aboutdlg.h"
+
+class AboutDlg : public QDialog {
+  Q_OBJECT
+
+  public:
+    AboutDlg(QWidget *parent = 0);
+
+  private:
+    Ui::AboutDlg ui;
+
+    QString about() const;
+    QString authors() const;
+    QString contributors() const;
+    QString thanksTo() const;
+
+};
+
+
+#endif
index e9bb551..e977c6f 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "mainwin.h"
 
+#include "aboutdlg.h"
 #include "chatwidget.h"
 #include "bufferview.h"
 #include "chatline-old.h"
@@ -104,7 +105,8 @@ void MainWin::init() {
   ui.bufferWidget->setSelectionModel(Client::bufferModel()->standardSelectionModel());
 
 #ifdef SPUTDEV
-  showSettingsDlg();
+  //showSettingsDlg();
+  //showAboutDlg();
 #endif
 
 }
@@ -123,6 +125,7 @@ void MainWin::setupMenus() {
   //connect(ui.actionNetworkList, SIGNAL(triggered()), this, SLOT(showServerList()));
   connect(ui.actionSettingsDlg, SIGNAL(triggered()), this, SLOT(showSettingsDlg()));
   connect(ui.actionDebug_Console, SIGNAL(triggered()), this, SLOT(showDebugConsole()));
+  connect(ui.actionAboutQuassel, SIGNAL(triggered()), this, SLOT(showAboutDlg()));
   connect(ui.actionAboutQt, SIGNAL(triggered()), QApplication::instance(), SLOT(aboutQt()));
 
   actionEditNetworks = new QAction(QIcon(":/22x22/actions/configure"), tr("Edit &Networks..."), this);
@@ -335,6 +338,11 @@ void MainWin::showDebugConsole() {
   debugConsole->show();
 }
 
+void MainWin::showAboutDlg() {
+  AboutDlg dlg(this);
+  dlg.exec();
+}
+
 void MainWin::closeEvent(QCloseEvent *event) {
   QtUiSettings s;
   if(s.value("UseSystemTrayIcon").toBool() && s.value("MinimizeOnClose").toBool()) {
index a78832d..0e915cf 100644 (file)
@@ -63,6 +63,7 @@ class MainWin : public QMainWindow {
   private slots:
     void showSettingsDlg();
     void showNetworkDlg();
+    void showAboutDlg();
     void showDebugConsole();
 
     void showCoreConnectionDlg(bool autoConnect = false);
index d7f0f83..f4304ed 100644 (file)
@@ -1,15 +1,15 @@
 DEPMOD = uisupport common client
 QT_MOD = core gui network
 
-SRCS += bufferwidget.cpp chatline-old.cpp chatwidget.cpp coreconfigwizard.cpp coreconnectdlg.cpp configwizard.cpp debugconsole.cpp inputwidget.cpp \
+SRCS += aboutdlg.cpp bufferwidget.cpp chatline-old.cpp chatwidget.cpp coreconfigwizard.cpp coreconnectdlg.cpp configwizard.cpp debugconsole.cpp inputwidget.cpp \
         mainwin.cpp nicklistwidget.cpp qtui.cpp qtuisettings.cpp qtuistyle.cpp settingsdlg.cpp settingspagedlg.cpp \
         topicwidget.cpp verticaldock.cpp
 
-HDRS += bufferwidget.h chatline-old.h chatwidget.h coreconfigwizard.h configwizard.h debugconsole.h inputwidget.h \
+HDRS += aboutdlg.h bufferwidget.h chatline-old.h chatwidget.h coreconfigwizard.h configwizard.h debugconsole.h inputwidget.h \
         coreconnectdlg.h mainwin.h nicklistwidget.h qtui.h qtuisettings.h qtuistyle.h settingsdlg.h settingspagedlg.h \
         topicwidget.h verticaldock.h
 
-FORMNAMES = mainwin.ui coreaccounteditdlg.ui coreconnectdlg.ui bufferviewwidget.ui bufferwidget.ui nicklistwidget.ui settingsdlg.ui \
+FORMNAMES = aboutdlg.ui mainwin.ui coreaccounteditdlg.ui coreconnectdlg.ui bufferviewwidget.ui bufferwidget.ui nicklistwidget.ui settingsdlg.ui \
             settingspagedlg.ui topicwidget.ui debugconsole.ui inputwidget.ui \
             coreconfigwizardintropage.ui coreconfigwizardadminuserpage.ui coreconfigwizardstorageselectionpage.ui coreconfigwizardsyncpage.ui
 
index 7448a6c..17d6668 100644 (file)
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>618</width>
-    <height>415</height>
+    <width>488</width>
+    <height>450</height>
    </rect>
   </property>
   <property name="windowTitle" >
    <string>About Quassel</string>
   </property>
-  <widget class="QLabel" name="label" >
-   <property name="geometry" >
-    <rect>
-     <x>10</x>
-     <y>10</y>
-     <width>351</width>
-     <height>20</height>
-    </rect>
-   </property>
-   <property name="text" >
-    <string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
+  <layout class="QVBoxLayout" >
+   <item>
+    <widget class="QFrame" name="frame" >
+     <property name="styleSheet" >
+      <string>background:white;</string>
+     </property>
+     <property name="frameShape" >
+      <enum>QFrame::StyledPanel</enum>
+     </property>
+     <property name="frameShadow" >
+      <enum>QFrame::Sunken</enum>
+     </property>
+     <layout class="QVBoxLayout" >
+      <item>
+       <layout class="QHBoxLayout" >
+        <item>
+         <widget class="QLabel" name="label_2" >
+          <property name="text" >
+           <string/>
+          </property>
+          <property name="pixmap" >
+           <pixmap resource="../../icons/icons.qrc" >:/icons/quassel-icon.png</pixmap>
+          </property>
+          <property name="scaledContents" >
+           <bool>false</bool>
+          </property>
+         </widget>
+        </item>
+        <item>
+         <layout class="QVBoxLayout" >
+          <property name="leftMargin" >
+           <number>10</number>
+          </property>
+          <item>
+           <widget class="QLabel" name="label" >
+            <property name="font" >
+             <font/>
+            </property>
+            <property name="text" >
+             <string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
+p, li { white-space: pre-wrap; }
+&lt;/style>&lt;/head>&lt;body style=" font-family:'DejaVu Sans'; font-size:15pt; font-weight:600; font-style:normal;">
+&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Quassel IRC&lt;/p>&lt;/body>&lt;/html></string>
+            </property>
+            <property name="textFormat" >
+             <enum>Qt::AutoText</enum>
+            </property>
+           </widget>
+          </item>
+          <item>
+           <widget class="QLabel" name="versionLabel" >
+            <property name="font" >
+             <font/>
+            </property>
+            <property name="text" >
+             <string>&lt;html>&lt;head>&lt;meta name="qrichtext" content="1" />&lt;style type="text/css">
 p, li { white-space: pre-wrap; }
-&lt;/style>&lt;/head>&lt;body style=" font-family:'Bitstream Vera Sans'; font-size:11pt; font-weight:400; font-style:normal; text-decoration:none;">
-&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">&lt;span style=" font-weight:600;">Quassel IRC &lt;/span>(pre-release)&lt;/p>&lt;/body>&lt;/html></string>
-   </property>
-  </widget>
-  <widget class="QDialogButtonBox" name="buttonBox" >
-   <property name="geometry" >
-    <rect>
-     <x>200</x>
-     <y>360</y>
-     <width>341</width>
-     <height>32</height>
-    </rect>
-   </property>
-   <property name="orientation" >
-    <enum>Qt::Horizontal</enum>
-   </property>
-   <property name="standardButtons" >
-    <set>QDialogButtonBox::Close</set>
-   </property>
-  </widget>
-  <widget class="QTabWidget" name="tabWidget" >
-   <property name="geometry" >
-    <rect>
-     <x>20</x>
-     <y>40</y>
-     <width>581</width>
-     <height>301</height>
-    </rect>
-   </property>
-   <property name="currentIndex" >
-    <number>0</number>
-   </property>
-   <widget class="QWidget" name="aboutTab" >
-    <attribute name="title" >
-     <string>About</string>
-    </attribute>
-   </widget>
-   <widget class="QWidget" name="authorsTab" >
-    <attribute name="title" >
-     <string>Authors</string>
-    </attribute>
-   </widget>
-   <widget class="QWidget" name="licenceTab" >
-    <attribute name="title" >
-     <string>Licence Agreement</string>
-    </attribute>
-    <widget class="QTextBrowser" name="textBrowser" >
-     <property name="geometry" >
-      <rect>
-       <x>10</x>
-       <y>10</y>
-       <width>561</width>
-       <height>251</height>
-      </rect>
+&lt;/style>&lt;/head>&lt;body style=" font-family:'DejaVu Sans'; font-size:10pt; font-weight:600; font-style:normal;">
+&lt;p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Version 0.2.0-pre, Build &amp;gt;= 474 (2008-02-08)&lt;/p>&lt;/body>&lt;/html></string>
+            </property>
+           </widget>
+          </item>
+         </layout>
+        </item>
+        <item>
+         <spacer>
+          <property name="orientation" >
+           <enum>Qt::Horizontal</enum>
+          </property>
+          <property name="sizeHint" >
+           <size>
+            <width>40</width>
+            <height>20</height>
+           </size>
+          </property>
+         </spacer>
+        </item>
+       </layout>
+      </item>
+     </layout>
+    </widget>
+   </item>
+   <item>
+    <widget class="QTabWidget" name="tabWidget" >
+     <property name="currentIndex" >
+      <number>0</number>
+     </property>
+     <widget class="QWidget" name="aboutTab" >
+      <attribute name="title" >
+       <string>&amp;About</string>
+      </attribute>
+      <layout class="QVBoxLayout" >
+       <item>
+        <widget class="QTextBrowser" name="aboutTextBrowser" >
+         <property name="styleSheet" >
+          <string>QTextBrowser { background:transparent;}</string>
+         </property>
+         <property name="frameShape" >
+          <enum>QFrame::NoFrame</enum>
+         </property>
+         <property name="openExternalLinks" >
+          <bool>true</bool>
+         </property>
+        </widget>
+       </item>
+      </layout>
+     </widget>
+     <widget class="QWidget" name="authorsTab" >
+      <attribute name="title" >
+       <string>A&amp;uthors</string>
+      </attribute>
+      <layout class="QVBoxLayout" >
+       <item>
+        <widget class="QTextBrowser" name="authorTextBrowser" >
+         <property name="styleSheet" >
+          <string>QTextBrowser { background:transparent;}</string>
+         </property>
+         <property name="frameShape" >
+          <enum>QFrame::NoFrame</enum>
+         </property>
+         <property name="openExternalLinks" >
+          <bool>true</bool>
+         </property>
+        </widget>
+       </item>
+      </layout>
+     </widget>
+     <widget class="QWidget" name="tab_2" >
+      <attribute name="title" >
+       <string>&amp;Contributors</string>
+      </attribute>
+      <layout class="QVBoxLayout" >
+       <item>
+        <widget class="QTextBrowser" name="contributorTextBrowser" >
+         <property name="styleSheet" >
+          <string>QTextBrowser { background:transparent;}</string>
+         </property>
+         <property name="frameShape" >
+          <enum>QFrame::NoFrame</enum>
+         </property>
+         <property name="openExternalLinks" >
+          <bool>true</bool>
+         </property>
+        </widget>
+       </item>
+      </layout>
+     </widget>
+     <widget class="QWidget" name="tab" >
+      <attribute name="title" >
+       <string>&amp;Thanks To</string>
+      </attribute>
+      <layout class="QVBoxLayout" >
+       <item>
+        <widget class="QTextBrowser" name="thanksToTextBrowser" >
+         <property name="styleSheet" >
+          <string>QTextBrowser { background:transparent;}</string>
+         </property>
+         <property name="frameShape" >
+          <enum>QFrame::NoFrame</enum>
+         </property>
+         <property name="openExternalLinks" >
+          <bool>true</bool>
+         </property>
+        </widget>
+       </item>
+      </layout>
+     </widget>
+    </widget>
+   </item>
+   <item>
+    <widget class="QDialogButtonBox" name="buttonBox" >
+     <property name="orientation" >
+      <enum>Qt::Horizontal</enum>
+     </property>
+     <property name="standardButtons" >
+      <set>QDialogButtonBox::Close</set>
      </property>
     </widget>
-   </widget>
-  </widget>
+   </item>
+  </layout>
  </widget>
- <resources/>
+ <resources>
+  <include location="../../icons/icons.qrc" />
+ </resources>
  <connections>
   <connection>
    <sender>buttonBox</sender>
index 2152eb8..8c55c8a 100644 (file)
   </action>
   <action name="actionAboutQuassel" >
    <property name="enabled" >
-    <bool>false</bool>
+    <bool>true</bool>
    </property>
    <property name="icon" >
     <iconset resource="../../icons/icons.qrc" >:/icons/quassel-icon.png</iconset>
index d15b87d..129a7b3 100644 (file)
@@ -5,7 +5,7 @@
 
   quasselVersion = "0.2.0-pre";
   quasselDate = "2008-02-08";
-  quasselBuild = 486;
+  quasselBuild = 489;
 
   //! Minimum client build number the core needs
   clientBuildNeeded = 480;