You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would really like to be able to change the font size but it seems that the rendered text disappears entirely as soon as I assign a new TextStyle to the "textStyle" property.
Here's what my code looks like:
HtmlWidget(this.content, webView: true, webViewJs: true, textStyle: new TextStyle(fontSize: 15.0));
You need to get the default text style and adjust it instead of creating a new style from scratch (it won't have a color so it's invisible). I will try to improve this in the next version. In the mean time, please try this:
final defaultStyle =DefaultTextStyle.of(context).style;
final textStyle = defaultStyle.copyWith(fontSize:15);
returnHtmlWidget(...);
I would really like to be able to change the font size but it seems that the rendered text disappears entirely as soon as I assign a new TextStyle to the "textStyle" property.
Here's what my code looks like:
HtmlWidget(this.content, webView: true, webViewJs: true, textStyle: new TextStyle(fontSize: 15.0));
It works fine without the textStyle:
HtmlWidget(this.content, webView: true, webViewJs: true);
Any thoughts on this?
The text was updated successfully, but these errors were encountered: