Bug 65102 - Typo: "Special character" button hides the main toolbar
Summary: Typo: "Special character" button hides the main toolbar
Status: RESOLVED FIXED
Alias: None
Product: khangman
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: Anne-Marie Mahfouf
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-28 17:57 UTC by Mikko Ikola
Modified: 2003-09-28 22:57 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mikko Ikola 2003-09-28 17:57:03 UTC
Version:           1.2 (using KDE 3.1.9)
Compiler:          gcc version 3.3.2 20030908 (Debian prerelease)
OS:          Linux (i686) release 2.4.21

If you add a "Special character" button from "Settings" -> "Configure shortcuts" it appears ok in the main toolbar, but if you press it, the main toolbar disappears. (I guess that doesn't have anything to do with special characters?) Just a little typo, a bit misleading though.
Comment 1 Mikko Ikola 2003-09-28 20:30:17 UTC
A typo in my report... the menu should be "Settings" -> "Configure toolbars" 
Comment 2 Anne-Marie Mahfouf 2003-09-28 22:57:45 UTC
Subject: kdeedu/khangman/khangman

CVS commit by annma: 

fix the code so to resolve bug 65102. Suppress the KToggleToolBar action so that it does not appear anymore in the Configure Toolbar dialog where it did bnot behave correctly

CCMAIL=65102-done@bugs.kde.org


  M +5 -5      khangman.cpp   1.91
  M +1 -1      khangman.h   1.45
  M +0 -1      khangmanui.rc   1.14


--- kdeedu/khangman/khangman/khangman.cpp  #1.90:1.91
@@ -78,5 +78,4 @@ KHangMan::KHangMan()
     secondToolbar->setBarPos(KToolBar::Bottom);
     connect(m_view, SIGNAL(signalChangeLanguage(int)), this, SLOT(changeLanguage(int)));
-    m_bCharToolbar=true;
     loadSettings();
     loadLangToolBar();
@@ -97,5 +96,5 @@ void KHangMan::setupActions()
     createStandardStatusBarAction();
     setStandardToolBarMenuEnabled(true);
-    secondAct = new KToggleToolBarAction(secondToolbar, i18n("Special Characters"), actionCollection(), "second_act");
+    //secondAct = new KToggleToolBarAction(secondToolbar, i18n("Special Characters"), actionCollection(), "second_act");
     langAct = new KSelectAction(i18n("&Languages"), 0, this, SLOT(slotLanguage()), actionCollection(), "combo_lang");
     langAct->setItems(m_sortedNames);
@@ -273,5 +272,5 @@ void KHangMan::loadSettings()
 
     // Show/hide characters toolbar
-    m_bCharToolbar = config->readBoolEntry( "showCharToolbar", true);
+    m_bCharToolbar = config->readBoolEntry( "showCharToolbar", false);
     if (m_bCharToolbar) secondToolbar->show();
     else secondToolbar->hide();
@@ -491,4 +490,6 @@ void KHangMan::slotSofter()
 void KHangMan::loadLangToolBar()
 {
+        if (secondToolbar->isVisible() && (m_view->language != "en" || m_view->language != "it"))
+            m_bCharToolbar=true;
         secondToolbar->clear();
         if (m_view->language=="es" || m_view->language == "pt" || m_view->language == "ca")
@@ -552,8 +553,7 @@ void KHangMan::loadLangToolBar()
         if (m_bCharToolbar) {
                 secondToolbar->show();
-                secondAct->setChecked(true);
         }
         else secondToolbar->hide();
-        if (m_view->language == "en" || m_view->language == "it")
+        if (m_view->language == "en" || m_view->language == "it")//no special chars in those languages
                 secondToolbar->hide();
 }

--- kdeedu/khangman/khangman/khangman.h  #1.44:1.45
@@ -192,5 +192,5 @@ private:
     KToggleAction *hintAct;
     KToggleAction *accentsAct;
-    KToggleToolBarAction *secondAct;
+    //KToggleToolBarAction *secondAct;
     KSelectAction *langAct, *levelAct, *modeAct;
     QPopupMenu *langPopup;

--- kdeedu/khangman/khangman/khangmanui.rc  #1.13:1.14
@@ -38,4 +38,3 @@
         <Action name="combo_mode"/>
 </ToolBar>
-
 </kpartgui>