[Uml-devel] kdesdk/umbrello/umbrello

Jonathan Riddell jr at jriddell.org
Mon Jul 21 05:30:15 UTC 2003


On Sun, Jul 20, 2003 at 04:51:06PM +0200, Sebastian Stein wrote:
> CVS commit by sstein: 
> 
> hopefully fix the following bug:
> 
> "When I write cyrilic charaters in text, it is visible. When I load that document, cyrilic character becoms ???????. Probably saving in iso8859-1 (default). There is no way, (as I know) to change this."
> by Aleksandar Ribic
> 
>   M +2 -0      umldoc.cpp   1.45
> 
> --- kdesdk/umbrello/umbrello/umldoc.cpp  #1.44:1.45
> @@ -1138,4 +1138,5 @@ bool UMLDoc::saveToXMI(QIODevice& file) 
>          root.appendChild( content );
>          QTextStream stream( &file );
> +        stream.setEncoding(QTextStream::UnicodeUTF8);
>          stream << doc.toString();
>          return status;
> @@ -1144,4 +1145,5 @@ bool UMLDoc::saveToXMI(QIODevice& file) 
>  bool UMLDoc::loadFromXMI( QIODevice & file ) {
>          QTextStream stream( &file );
> +        stream.setEncoding(QTextStream::UnicodeUTF8);
>          QString data = stream.read();
>          QString error;

Looks good Seb, that seems to fix it.  Surprised we havn't had anyone
complaining about that before (maybe most people code in latin languages).

Jonathan Riddell




More information about the umbrello-devel mailing list