Qt4 has QChar::toLatin1() as well so we don't need to use toAscii() in Qt4.