[Konsole-devel] [Bug 114535] Using jis7 encoding causes the entire Konsole to freeze.

Kurt V.Hindenburg kurt.hindenburg at kdemail.net
Sun Nov 13 10:45:48 UTC 2005


------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=114535         




------- Additional Comments From kurt.hindenburg kdemail net  2005-11-13 11:45 -------
SVN commit 480103 by hindenburg:

Let's handle the jis7 problem this way.  That way the translators don't have
any new strings and I don't have to worry about the loading/saving not working
again.  It is too bad it is not possible to disable an item in a KSelectAction.

CCBUG: 107329
CCBUG: 114535


 M  +8 -6      konsole.cpp  


--- branches/KDE/3.5/kdebase/konsole/konsole/konsole.cpp #480102:480103
 @ -632,11 +632,6  @
       selectSetEncoding = new KSelectAction( i18n( "&Encoding" ), SmallIconSet( "charset" ), 0, this, SLOT(slotSetEncoding()), actions, "set_encoding" );
       QStringList list = KGlobal::charsets()->descriptiveEncodingNames();
       list.prepend( i18n( "Default" ) );
-
-      // BR114535 : Remove jis7 due to infinite loop.
-      // If you fix this issue and remove the line below,  remember to 
-      // remove the line in setSessionEncoding() (search for jis7).
-      list.remove( i18n( "Japanese ( jis7 )" ) );
       selectSetEncoding->setItems(list);
       selectSetEncoding->setCurrentItem (0);
       selectSetEncoding->plug(m_options);
 @ -863,6 +858,14  @
     bool found;
     QString enc = KGlobal::charsets()->encodingForName(selectSetEncoding->currentText());
     qtc = KGlobal::charsets()->codecForName(enc, found);
+
+    // BR114535 : Remove jis7 due to infinite loop.
+    if ( enc == "jis7" ) {
+      kdWarning()<<"Encoding Japanese (jis7) currently does not work!  BR114535"<<endl;
+      qtc = QTextCodec::codecForLocale();
+      selectSetEncoding->setCurrentItem( 0 );
+    }
+
     if(!found)
     {
       kdWarning() << "Codec " << selectSetEncoding->currentText() << " not found!" << endl;
 @ -2631,7 +2634,6  @
     }
 
     i++;                 // Take into account the first entry: Default
-    if ( i > 24 ) i--;   // Handle the removed jis7 entry
     //kdDebug()<<"setSessionEncoding="<<encoding<<"; "<<i<<endl;
 
     session->setEncodingNo( i );



More information about the konsole-devel mailing list