Bug 97951 - Actions are not displayed under UTF-8
Summary: Actions are not displayed under UTF-8
Status: RESOLVED FIXED
Alias: None
Product: konversation
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Slackware Linux
: NOR normal
Target Milestone: ---
Assignee: Konversation Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-01-26 21:20 UTC by Marco Gulino
Modified: 2010-07-01 15:58 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 Marco Gulino 2005-01-26 21:20:12 UTC
Version:            (using KDE KDE 3.3.90)
Installed from:    Slackware Packages
OS:                Linux

UTF-8 does not work on (others) actions, when filling it with some non-ascii chars you can see only:
[21:19:17] * tux is saying yèèèèèèèè!!!
Comment 1 Ismail Donmez 2005-02-02 21:06:47 UTC
CVS commit by cartman: 

Make unicode work in actions again. Needed to revert Dirk's patch. Because if KStringHandler::isUtf8() returns
false it doesn't mean string is necessarily not unicode. So instead of reverting to ISO-8859-1 ourselves, use
channel encoding specified by user or identity codec.
BUG:97951


  M +0 -5      server.cpp   1.432


--- kdeextragear-2/konversation/konversation/server.cpp  #1.431:1.432
@@ -1063,9 +1063,4 @@ void Server::incoming()
         codec = IRCCharsets::codecForName(channelEncoding);
 
-
-      // if channel encoding is utf-8 and the string is definitely not utf-8
-      // then try latin-1
-      if ( !isUtf8 && codec->mibEnum() == 106 )
-        codec = QTextCodec::codecForMib( 4 /* iso-8859-1 */ );
       inputBuffer << codec->toUnicode(qcsBufferLines.front());
     }


Comment 2 Ismail Donmez 2010-07-01 15:58:14 UTC
commit 6ce39f15d1c60af2f0c4bac6955fecf7e047b27b
Author: İsmail Dönmez <ismail@kde.org>
Date:   Wed Feb 2 20:06:41 2005 +0000

    Make unicode work in actions again. Needed to revert Dirk's patch. Because if KStringHandler::isUtf8() returns
    false it doesn't mean string is necessarily not unicode. So instead of reverting to ISO-8859-1 ourselves, use
    channel encoding specified by user or identity codec.
    BUG:97951
    
    svn path=/trunk/kdeextragear-2/konversation/; revision=385497

diff --git a/konversation/server.cpp b/konversation/server.cpp
index 1d952b6..3528f82 100644
--- a/konversation/server.cpp
+++ b/konversation/server.cpp
@@ -1062,11 +1062,6 @@ void Server::incoming()
       if(!channelEncoding.isEmpty())
         codec = IRCCharsets::codecForName(channelEncoding);
 
-
-      // if channel encoding is utf-8 and the string is definitely not utf-8
-      // then try latin-1
-      if ( !isUtf8 && codec->mibEnum() == 106 )
-        codec = QTextCodec::codecForMib( 4 /* iso-8859-1 */ );
       inputBuffer << codec->toUnicode(qcsBufferLines.front());
     }
     qcsBufferLines.pop_front();