I created an extension to be able to render icons in the mardown.
This is done by typing [i:package;fontName;code], so, for instance, a radio button and a check button would be rendered as:
[i:null;MaterialIcons;0xe503;null] representa uma opção de escolha única, ou seja, você pode escolher apenas uma das opções indicadas.
[i:null;MaterialIcons;0xef46;null] representa uma opção de escolha múltipla, ou seja, você poderá escolher quantas opções desejar.
Problem is: Flutter doesn't render symbols very well (they are not in the same vertical alignment):

Since TextSpan doesn't have any kind of fix for position, the only way would be to use WidgetSpan, so we could use any widget inside a RichText with a Transform.translate to fix the vertical alignment.
Unfortunately, using WidgetSpan triggers an error here:
https://github.com/tagnote-app/markdown_viewer/blob/b94b9ca0eef56d1beaf899a00aeff529cd24f67f/lib/src/helpers/merge_rich_text.dart#L45
saying WidgetSpan is not a TextSpan.
I created an extension to be able to render icons in the mardown.
This is done by typing
[i:package;fontName;code], so, for instance, a radio button and a check button would be rendered as:Problem is: Flutter doesn't render symbols very well (they are not in the same vertical alignment):
Since
TextSpandoesn't have any kind of fix for position, the only way would be to useWidgetSpan, so we could use any widget inside aRichTextwith aTransform.translateto fix the vertical alignment.Unfortunately, using
WidgetSpantriggers an error here:https://github.com/tagnote-app/markdown_viewer/blob/b94b9ca0eef56d1beaf899a00aeff529cd24f67f/lib/src/helpers/merge_rich_text.dart#L45
saying
WidgetSpanis not aTextSpan.