chat_bubbles
chat_bubbles copied to clipboard
Issue displaying: Spanish accented characters
please see attached image:
Question: Is there a way to set UTF-8 for all rendered text from ChatGPT?
Thanks
Hey @mycloudvip ,The two things that come to my mind is
- Font Support: Ensure that the font you're using for your text supports the Spanish accented characters. Some fonts might not include all the necessary characters. You might want to use a font that is known to support a wide range of characters. and
-
Locale and Encoding: Flutter automatically handles the locale and encoding of text. However, you can make sure that your app's locale is set correctly by using the MaterialApp's locale property. For Spanish, you can use
const Locale('es', 'ES')
.
MaterialApp(
locale: const Locale('es', 'ES'), // or just add the locale to the availableLocales list in the MaterialApp
// ... other properties
)
I personally don't think this is the package's issue (As its very basic flutter code inside), so after you make sure you have done checked the 2 requirements above and those don't work i want you to confirm if the characters are rendered well on all screens, try debugPrint(theMessage)
and check if it prints the message on the debug console correct or not.
If it does print well then i suggest you try providing a textstyle
to the bubble widget OR wrapping the bubbleWidget in a DefaultTextStyle
Widget and provide a textstyle and if it doesn't well then you know where the errors are comming from.
Cheers! ✌️