author | zecke <zecke> | 2002-04-25 16:11:10 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-04-25 16:11:10 (UTC) |
commit | e944a214e0efeccd2eb9cc479ad8893427c6b81d (patch) (side-by-side diff) | |
tree | 263f754a34d23738dac6c3dea9dbcb0ce8b6bb3e | |
parent | 48dbc8fb69a5d19f466ea757207e42c3861b4dee (diff) | |
download | opie-e944a214e0efeccd2eb9cc479ad8893427c6b81d.zip opie-e944a214e0efeccd2eb9cc479ad8893427c6b81d.tar.gz opie-e944a214e0efeccd2eb9cc479ad8893427c6b81d.tar.bz2 |
This should fix the Umlaut problem
-rw-r--r-- | libopie/tododb.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libopie/tododb.cpp b/libopie/tododb.cpp index c486723..33fa177 100644 --- a/libopie/tododb.cpp +++ b/libopie/tododb.cpp @@ -32,32 +32,33 @@ public: //else //map.insert( "Categories", QString::null ); map.insert( "Description", (*it).description() ); if( (*it).hasDate() ){ map.insert("DateYear", QString::number( (*it).date().year() ) ); map.insert("DateMonth", QString::number( (*it).date().month() ) ); map.insert("DateDay", QString::number( (*it).date().day() ) ); } map.insert("Uid", QString::number( (*it).uid() ) ); task->setTagName("Task" ); task->setAttributes( map ); tasks->appendChild(task); } QFile file( name); if( file.open(IO_WriteOnly ) ){ QTextStream stream(&file ); + stream.setEncoding( QTextStream::UnicodeUTF8 ); stream << "<!DOCTYPE Tasks>" << endl; tasks->save(stream ); delete tasks; stream << "</Tasks>" << endl; file.close(); return true; } return false; } QValueList<ToDoEvent> load( const QString &name ){ qWarning("loading tododb" ); QValueList<ToDoEvent> m_todos; XMLElement *root = XMLElement::load( name ); if(root != 0l ){ // start parsing qWarning("ToDoDB::load tagName(): %s", root->tagName().latin1() ); //if( root->tagName() == QString::fromLatin1("Tasks" ) ){// Start |