Fixed downcase issue for UTF-8 strings.