Hello,
I am writing a qt console application; in my application, i am parsing an rss source , and then i am searching for a keyword(that comes from user input), finally i am writing the related item in the rss source to a text file.
I get the word to be searched from the console:
	
	cout<<"Authorname ?\n";
    cin>>author;
    searchedAuthor=author;//searchedAuthor is a QString
        cout<<"Authorname ?\n";
    cin>>author;
    searchedAuthor=author;//searchedAuthor is a QString
To copy to clipboard, switch view to plain text mode 
  
parsing the rss:
	
	if (currentTag == "dc:creator"){
                authorString += xml.text().toString();
        if (currentTag == "dc:creator"){
                authorString += xml.text().toString();
To copy to clipboard, switch view to plain text mode 
  
searching for my author:
	
	if(authorString.contains(searchedAuthor,Qt::CaseInsensitive)){
                outputfile << titleString<< "   "<<linkString <<"   "<< descriptionString << authorString <<"\n";
        if(authorString.contains(searchedAuthor,Qt::CaseInsensitive)){
                outputfile << titleString<< "   "<<linkString <<"   "<< descriptionString << authorString <<"\n";
To copy to clipboard, switch view to plain text mode 
  
This code works good for English. But i should use Turkish language( which has some  extra characters like "ğ,ş,ı,ö,ç".  
The problem is that : if authorString contains some of that extra characters "QString::contains" function cannot find the author that it should find. "cout" function works without any problem(displays characters corectly). I dont know much about the character encoding issues;but i've seen setCodecForTr in the docs:
	
	
        QTextCodec::setCodecForTr(QTextCodec::codecForName("eucTR"));
To copy to clipboard, switch view to plain text mode 
  
I didnt know if eucTR is installed or not, just tried...This also didn't work..What can i do to make the "QString::contains" function work properly for Turkish language?
Thanks in advance...
				
			
Bookmarks