diff options
Diffstat (limited to 'pylupdate3')
| -rw-r--r-- | pylupdate3/main.cpp | 6 | ||||
| -rw-r--r-- | pylupdate3/metatranslator.cpp | 14 | ||||
| -rw-r--r-- | pylupdate3/numberh.cpp | 2 | 
3 files changed, 11 insertions, 11 deletions
| diff --git a/pylupdate3/main.cpp b/pylupdate3/main.cpp index 8b0c24c..a3a0f3f 100644 --- a/pylupdate3/main.cpp +++ b/pylupdate3/main.cpp @@ -118,7 +118,7 @@ int main( int argc, char **argv )                      translatorFiles.append( *t );                      metSomething = TRUE;                  } else if ( it.key() == TQString("CODEC") ) { -                    codec = (*t).latin1(); +                    codec = (*t).utf8();                  }              }          } @@ -129,13 +129,13 @@ int main( int argc, char **argv )              if ( !codec.isEmpty() )                  tor.setCodec( codec );              if ( verbose ) -                tqWarning( "Updating '%s'...", (*tf).latin1() ); +                tqWarning( "Updating '%s'...", (*tf).utf8() );              merge( &tor, &fetchedTor, verbose );              if ( noObsolete )                  tor.stripObsoleteMessages();              tor.stripEmptyContexts();              if ( !tor.save(*tf) ) -                tqWarning( "pylupdate error: Cannot save '%s': %s", (*tf).latin1(), +                tqWarning( "pylupdate error: Cannot save '%s': %s", (*tf).utf8(),                    strerror(errno) );          }          if ( !metSomething ) { diff --git a/pylupdate3/metatranslator.cpp b/pylupdate3/metatranslator.cpp index 67b9ca6..f46ee9a 100644 --- a/pylupdate3/metatranslator.cpp +++ b/pylupdate3/metatranslator.cpp @@ -139,8 +139,8 @@ bool TsHandler::endElement( const TQString& /* namespaceURI */,  			     accum.utf8(), TQString::null, TRUE,  			     MetaTranslatorMessage::Unfinished) );  	    else -		tor->insert( MetaTranslatorMessage(context.ascii(), "", -			     accum.ascii(), TQString::null, FALSE, +		tor->insert( MetaTranslatorMessage(context.local8Bit(), "", +			     accum.local8Bit(), TQString::null, FALSE,  			     MetaTranslatorMessage::Unfinished) );  	}      } else if ( qName == TQString("translation") ) { @@ -151,8 +151,8 @@ bool TsHandler::endElement( const TQString& /* namespaceURI */,  					       comment.utf8(), translation,  					       TRUE, type) );  	else -	    tor->insert( MetaTranslatorMessage(context.ascii(), source.ascii(), -					       comment.ascii(), translation, +	    tor->insert( MetaTranslatorMessage(context.local8Bit(), source.local8Bit(), +					       comment.local8Bit(), translation,  					       FALSE, type) );  	inMessage = FALSE;      } @@ -173,9 +173,9 @@ bool TsHandler::fatalError( const TQXmlParseException& exception )  	TQString msg;  	msg.sprintf( "Parse error at line %d, column %d (%s).",  		     exception.lineNumber(), exception.columnNumber(), -		     exception.message().latin1() ); +		     exception.message().utf8() );  	if ( tqApp == 0 ) -	    tqWarning( "XML error: %s", msg.latin1() ); +	    tqWarning( "XML error: %s", msg.utf8() );  	else  	    TQMessageBox::information( tqApp->mainWidget(),  				      TQObject::tr("TQt Linguist"), msg ); @@ -226,7 +226,7 @@ static TQString evilBytes( const TQCString& str, bool utf8 )  	return protect( str );      } else {  	TQString result; -	TQCString t = protect( str ).latin1(); +	TQCString t = protect( str ).utf8();  	int len = (int) t.length();  	for ( int k = 0; k < len; k++ ) {  	    if ( (uchar) t[k] >= 0x7f ) diff --git a/pylupdate3/numberh.cpp b/pylupdate3/numberh.cpp index e5ff5de..a52687b 100644 --- a/pylupdate3/numberh.cpp +++ b/pylupdate3/numberh.cpp @@ -140,7 +140,7 @@ static TQString translationAttempt( const TQString& oldTranslation,  	    for ( k = 0; k < p; k++ ) {  		if ( (!met[k] || pass > 0) &&  		     matchedYet[k] == (int) oldNumbers[k].length() && -		     numberLength(oldTranslation.latin1() + (i + 1) - +		     numberLength(oldTranslation.utf8() + (i + 1) -  				  matchedYet[k]) == matchedYet[k] ) {  		    // the longer the better  		    if ( best == p || matchedYet[k] > matchedYet[best] ) | 
