Hello community,

here is the log from the commit of package kanagram for openSUSE:Factory 
checked in at 2013-12-02 12:32:19
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/kanagram (Old)
 and      /work/SRC/openSUSE:Factory/.kanagram.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "kanagram"

Changes:
--------
--- /work/SRC/openSUSE:Factory/kanagram/kanagram.changes        2013-10-03 
15:50:21.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.kanagram.new/kanagram.changes   2013-12-02 
12:32:19.000000000 +0100
@@ -1,0 +2,21 @@
+Sat Nov 16 17:54:18 UTC 2013 - [email protected]
+
+- Update to 4.11.90
+   * KDE 4.12 Beta 2 release
+   * See http://www.kde.org/announcements/announce-4.12-beta2.php
+
+-------------------------------------------------------------------
+Sat Nov  9 22:55:30 UTC 2013 - [email protected]
+
+- Update to 4.11.80
+   * KDE 4.12 Beta 1 release
+   * See http://www.kde.org/announcements/announce-4.12-beta1.php
+
+-------------------------------------------------------------------
+Sat Nov  2 15:09:25 UTC 2013 - [email protected]
+
+- Update to 4.11.3
+   * KDE 4.11.3 bugfix release
+   * See http://www.kde.org/announcements/announce-4.11.3.php
+
+-------------------------------------------------------------------

Old:
----
  kanagram-4.11.2.tar.xz

New:
----
  kanagram-4.11.90.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ kanagram.spec ++++++
--- /var/tmp/diff_new_pack.o9x1P3/_old  2013-12-02 12:32:20.000000000 +0100
+++ /var/tmp/diff_new_pack.o9x1P3/_new  2013-12-02 12:32:20.000000000 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           kanagram
-Version:        4.11.2
+Version:        4.11.90
 Release:        0
 Summary:        Anagram Game
 License:        GPL-2.0+

++++++ kanagram-4.11.2.tar.xz -> kanagram-4.11.90.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kanagram-4.11.2/src/desktop/CMakeLists.txt 
new/kanagram-4.11.90/src/desktop/CMakeLists.txt
--- old/kanagram-4.11.2/src/desktop/CMakeLists.txt      2013-06-28 
19:18:01.000000000 +0200
+++ new/kanagram-4.11.90/src/desktop/CMakeLists.txt     2013-10-22 
00:10:28.000000000 +0200
@@ -5,6 +5,7 @@
     ${CMAKE_CURRENT_BINARY_DIR}
     ${LIBKDEEDU_INCLUDE_DIR}
     ${KANAGRAM_ENGINE_INCLUDE_DIRS}
+    ${KDE4_INCLUDES}
 )
 
 set(kanagramdesktop_SRCS
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kanagram-4.11.2/src/desktop/kanagram.cpp 
new/kanagram-4.11.90/src/desktop/kanagram.cpp
--- old/kanagram-4.11.2/src/desktop/kanagram.cpp        2013-06-28 
19:18:01.000000000 +0200
+++ new/kanagram-4.11.90/src/desktop/kanagram.cpp       2013-10-22 
00:10:28.000000000 +0200
@@ -50,6 +50,7 @@
 
 static const char* m_textRevealWord = I18N_NOOP("reveal word");
 static const char* m_textHint = I18N_NOOP("hint");
+static const char* m_textPicHint = I18N_NOOP("picture hint");
 static const char* m_nextText = I18N_NOOP("Next Anagram");
 
 double kWindowWidth = 1000.0;
@@ -75,10 +76,10 @@
 
 Kanagram::Kanagram()
 : KMainWindow(), m_game(NULL), m_overNext(false), m_overConfig(false),
-    m_overHelp(false), m_overQuit(false), m_overReveal(false), 
m_overHint(false),
+    m_overHelp(false), m_overQuit(false), m_overReveal(false), 
m_overHint(false),m_overPicHint(false),
     m_overUp(false), m_overAboutKDE(false), m_overAboutApp(false),
     m_overHandbook(false), m_overSwitcher(false), m_overLogo(false),
-    m_overHintBox(false), m_showHint(false), m_player(NULL), 
m_wordRevealed(false),
+    m_overHintBox(false), m_showHint(false), m_showPicHint(false), 
m_player(NULL), m_wordRevealed(false),
     m_actionCollection(NULL)
 {
     setAttribute(Qt::WA_StaticContents);
@@ -91,6 +92,10 @@
     loadSettings();
 
     m_game = new KanagramGame();
+    if (!m_game->picHint().isEmpty())
+    {
+        m_pictureHint.load(m_game->picHint().pathOrUrl());
+    }
 
     setMouseTracking(true);
     m_chalkColor = QColor(155, 155, 155);
@@ -329,7 +334,13 @@
     {
         drawTextNew(p, reveal, Qt::AlignBottom | Qt::AlignRight, 6, 0, 
m_blackboardRect, m_overReveal, m_cornerFontSize);
     }
+    
     drawTextNew(p, i18n(m_textHint), Qt::AlignBottom | Qt::AlignLeft, 6, 0, 
m_blackboardRect, m_overHint, m_cornerFontSize);
+    
+    if(!m_game->picHint().isEmpty())
+    {
+        drawTextNew(p, i18n(m_textPicHint), Qt::AlignTop | Qt::AlignLeft, 6, 
8, m_blackboardRect, m_overPicHint, m_cornerFontSize);//////////for picture hint
+    }
 
     // update these rects because we have access to the painter and thus the 
fontsize here
     QFont font = KGlobalSettings::generalFont();
@@ -338,6 +349,7 @@
     QFontMetrics fm(font);
     QRect r = innerRect(m_blackboardRect, 6, 0);
     m_hintRect = fm.boundingRect(r, Qt::AlignBottom|Qt::AlignLeft, 
i18n(m_textHint));
+    m_picHintRect = fm.boundingRect(r, Qt::AlignTop|Qt::AlignLeft, 
i18n(m_textPicHint));
     m_hintBoxRect = QRect(int(684.813 * m_xRatio), int(319.896 * m_yRatio), 
int(xEyesScale * width()), int(yEyesScale * height()));
     r = innerRect(m_blackboardRect, 6, 0);
     m_revealRect = fm.boundingRect(r, Qt::AlignBottom|Qt::AlignRight, reveal);
@@ -395,7 +407,12 @@
                 Qt::TextWordWrap | Qt::AlignCenter, hint);
     }
 
-    if (m_overHelp && !m_showHint)
+    if (m_showPicHint)
+    {
+        p.drawImage(m_picHintRect.topLeft(),m_pictureHint);
+    }
+
+    if (m_overHelp && !m_showHint && !m_showPicHint)
     {
         if (m_overAboutApp)
         {
@@ -574,7 +591,13 @@
 {
     m_wordRevealed = false;
     hideHint();
+    hidePicHint();
     m_game->nextAnagram();
+    if (!m_game->picHint().isEmpty())
+    {
+        m_pictureHint.load(m_game->picHint().pathOrUrl());
+    }
+
     if (m_useSounds)
     {
         play("chalk.ogg");
@@ -647,8 +670,33 @@
     update();
 }
 
+void Kanagram::slotTogglePicHint()
+{
+   if (m_showPicHint)
+    {
+        m_showPicHint = false;
+    }
+    else
+    {
+        if (m_hintHideTime)
+        {
+            m_hintTimer->start(m_hintHideTime * 1000);
+        }
+        m_showPicHint = true;
+       // randomHintImage();
+    }
+    update();
+  
+  
+}
+
 void Kanagram::mousePressEvent(QMouseEvent *e)
 {
+    if (m_showPicHint)
+    {
+        hidePicHint();
+    }
+
     if (m_nextRect.contains(e->pos()))
     {
         slotNextAnagram();
@@ -674,7 +722,7 @@
         m_helpMenu->aboutApplication();
     }
 
-    if (!m_showHint && m_overHelp)
+    if (!m_showHint && m_overHelp && !m_showPicHint)
     {
         if (m_handbookRect.contains(e->pos()))
         {
@@ -713,6 +761,11 @@
     {
         slotToggleHint();
     }
+    
+    if (m_picHintRect.contains(e->pos()))
+    {
+        slotTogglePicHint();
+    }
 
     if (m_upRect.contains(e->pos()) && !m_inputBox->text().isEmpty())
     {
@@ -746,6 +799,10 @@
     CheckRect(m_helpRect, p, m_overHelp, haveToUpdate);
     CheckRect(m_quitRect, p, m_overQuit, haveToUpdate);
     CheckRect(m_hintRect, p, m_overHint, haveToUpdate);
+    if (!m_game->picHint().isEmpty())
+    {
+        CheckRect(m_picHintRect, p, m_overPicHint, haveToUpdate);
+    }
     CheckRect(m_hintBoxRect, p, m_overHintBox, haveToUpdate);
     CheckRect(m_revealRect, p, m_overReveal, haveToUpdate);
     CheckRect(m_upRect, p, m_overUp, haveToUpdate);
@@ -762,14 +819,14 @@
         haveToUpdate = true;
     }
 
-    if (!m_showHint)
+    if (!m_showHint ||!m_showPicHint)
     {
         CheckRect(m_handbookRect, p, m_overHandbook, haveToUpdate);
         CheckRect(m_aboutKDERect, p, m_overAboutKDE, haveToUpdate);
     }
 
     if (m_overAboutKDE || m_overHandbook || m_overSwitcher || m_overNext || 
m_overQuit
-            || m_overConfig || (m_overReveal && !m_wordRevealed) || m_overHint 
|| (m_overUp && !m_inputBox->text().isEmpty())
+            || m_overConfig || (m_overReveal && !m_wordRevealed) || m_overHint 
 || m_overPicHint || (m_overUp && !m_inputBox->text().isEmpty())
             || m_overAboutApp || m_overHintBox || m_overLogo)
     {
         this->setCursor(Qt::PointingHandCursor);
@@ -902,13 +959,22 @@
 
 void Kanagram::hideHint()
 {
-    if (m_showHint == true)
+    if (m_showHint == true )
     {
         m_showHint = false;
     }
     update();
 }
 
+void Kanagram::hidePicHint()
+{
+  if (m_showPicHint == true || !m_game->picHint().isEmpty())
+  {
+      m_showPicHint = false;
+  }
+  update();
+}
+
 void Kanagram::resetInputBox()
 {
     m_inputBox->setPalette(QPalette());
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kanagram-4.11.2/src/desktop/kanagram.desktop 
new/kanagram-4.11.90/src/desktop/kanagram.desktop
--- old/kanagram-4.11.2/src/desktop/kanagram.desktop    2013-08-28 
19:02:13.000000000 +0200
+++ new/kanagram-4.11.90/src/desktop/kanagram.desktop   2013-10-22 
00:10:28.000000000 +0200
@@ -119,7 +119,7 @@
 Comment[sl]=Igra vrstnega reda črk za KDE
 Comment[sv]=Bokstavsordningsspel för KDE
 Comment[tr]=KDE Harf Sırası Oyunu
-Comment[ug]=KDE ھەرپ تەرتىپى ئويۇنى
+Comment[ug]=KDE ھەرپ تىزىش ئويۇنى
 Comment[uk]=Гра з впорядкування літер
 Comment[vi]=Trò chơi Sắp xếp Chữ cái KDE
 Comment[x-test]=xxKDE Letter Order Gamexx
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kanagram-4.11.2/src/desktop/kanagram.h 
new/kanagram-4.11.90/src/desktop/kanagram.h
--- old/kanagram-4.11.2/src/desktop/kanagram.h  2013-06-28 19:18:01.000000000 
+0200
+++ new/kanagram-4.11.90/src/desktop/kanagram.h 2013-10-22 00:10:28.000000000 
+0200
@@ -29,6 +29,7 @@
 
 #include <KMainWindow>
 #include <KRandomSequence>
+#include <qimage.h>
 
 namespace Phonon
 {
@@ -77,6 +78,9 @@
         /** hide the hint box and text. */
         void hideHint();
 
+        /** hide the picture hint*/
+        void hidePicHint();
+
         /** reset the input box in preparation for the next word entry */
         void resetInputBox();
 
@@ -113,6 +117,9 @@
         /** show/hide the hint */
         void slotToggleHint();
 
+        /**show/hide the picture hint */
+        void slotTogglePicHint();///for picture hints
+
         /** slot to save non kcfg_ settings */
         void slotSaveSettings();
 
@@ -239,6 +246,7 @@
         QRect m_quitRect;
         QRect m_revealRect;
         QRect m_hintRect;
+        QRect m_picHintRect;
         QRect m_upRect;
         QRect m_aboutKDERect;
         QRect m_aboutAppRect; 
@@ -255,7 +263,8 @@
         bool m_overHelp; 
         bool m_overQuit; 
         bool m_overReveal; 
-        bool m_overHint; 
+        bool m_overHint;
+        bool m_overPicHint;
         bool m_overUp; 
         bool m_overAboutKDE; 
         bool m_overAboutApp; 
@@ -265,6 +274,8 @@
         bool m_overHintBox;
 
         bool m_showHint;
+        bool m_showPicHint;
+        QImage m_pictureHint;
 
         /** colors for use in drawing text and lines */
         QColor m_fillColor; 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kanagram-4.11.2/src/engine/kanagramgame.cpp 
new/kanagram-4.11.90/src/engine/kanagramgame.cpp
--- old/kanagram-4.11.2/src/engine/kanagramgame.cpp     2013-06-28 
19:18:01.000000000 +0200
+++ new/kanagram-4.11.90/src/engine/kanagramgame.cpp    2013-10-22 
00:10:28.000000000 +0200
@@ -23,8 +23,10 @@
 
 #include "kanagramgame.h"
 
+
 #include "kanagramsettings.h"
 
+#include <KDE/KUrl>
 #include <sharedkvtmlfiles.h>
 #include <keduvocdocument.h>
 #include <keduvocexpression.h>
@@ -35,6 +37,7 @@
 
 #include <QtCore/QFileInfo>
 
+
 KanagramGame::KanagramGame() : m_index(0), m_document(NULL)
 {
     // Get the list of vocabularies
@@ -199,6 +202,8 @@
 
         // lowercase the entry text so german words that start capitalized 
will be lowercased
         m_originalWord = translation->text().toLower();
+        m_picHintUrl = translation->imageUrl();
+
         m_answeredWords.append(m_originalWord);
         createAnagram();
         m_hint = translation->comment();
@@ -213,6 +218,7 @@
         // this file has no entries
         m_originalWord = "";
         m_hint = "";
+        m_picHintUrl = "";
         // TODO: add some error reporting here
     }
 }
@@ -335,4 +341,11 @@
     }
 }
 
+////function to return the picture url
+KUrl KanagramGame::picHint()
+{
+    return m_picHintUrl;
+}
+
+
 #include "kanagramgame.moc"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kanagram-4.11.2/src/engine/kanagramgame.h 
new/kanagram-4.11.90/src/engine/kanagramgame.h
--- old/kanagram-4.11.2/src/engine/kanagramgame.h       2013-06-28 
19:18:01.000000000 +0200
+++ new/kanagram-4.11.90/src/engine/kanagramgame.h      2013-10-22 
00:10:28.000000000 +0200
@@ -27,9 +27,11 @@
 #include <QtCore/QObject>
 #include <QtCore/QStringList>
 #include <QtCore/QHash>
+#include <KDE/KUrl>
 
 #include <krandomsequence.h>
 
+
 class KEduVocDocument;
 
 /** @brief game api
@@ -60,6 +62,9 @@
         /** Get this anagram's answer */
         QString word() const;
 
+        /** Get this anagram's picture hint URL */
+        KUrl picHint();
+
         /** Get the current vocabulary file's title */
         QString documentTitle() const;
 
@@ -142,6 +147,9 @@
         /** The current anagram's hint */
         QString m_hint;
 
+        /** The current anagram's picture if any */
+        KUrl m_picHintUrl;
+
         /** The current anagram's answer */
         QString m_originalWord;
 

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to