styled_text
Text widget with formatted text using tags. Makes it easier to use formatted text in multilingual applications.
10.0.0
105K downloads/mo
#1105 most downloaded on pub.dev
andyduke/styled_text_package
What this package is like to depend on
Last release 28 days ago
27 Jul 2026
Release timing varies
gaps range from 3 weeks to 1.6 years
Most releases are documented
notes for 27 of 32 stable releases
Nothing withdrawn
no release was ever pulled
7 years old
39 releases · first in 2019
2 releases in the last 12 months
see the full history below
Release timeline
39 releases · May 2019 to Jul 2026Releases
latest 39-
10.0.027 Jul 2026Release notes
Open source →- Bump
xmldependency to^7.0.0for compatibility with packages that requirexml7 (e.g.pdf/printing). Thanks to @mohanedy.
- Bump
-
9.0.014 Jan 2026 -
9.0.0-beta-425 Jun 2024 pre-releaseRelease notes
Open source →- Fixed a bug in asynchronous parsing of tag attributes - the last set of attributes "stuck" in nested tags. Thanks to @Mithos5r, @rambah and @Merlin1stHere.
-
9.0.0-beta-228 May 2024 pre-releaseRelease notes
Open source →- The constructors of some widgets and classes are now constant:
- StyledText
- CustomStyledText
- StyledTextTagBase
- StyledTextTag
- StyledTextWidgetBuilderTag
- StyledTextIconTag
- StyledTextActionTag
- StyledTextCustomTag
- The constructors of some widgets and classes are now constant:
-
9.0.0-beta-128 May 2024 pre-releaseRelease notes
Open source →- Text parsing has been changed from asynchronous to synchronous.
This fixes an issue with the
StyledTextwidget resizing when text parsing is complete, which was causing problems in lists. To return asynchronous parsing, theasyncparameter has been added to theStyledTextconstructor. This change was made possible thanks to the help of @Maatteogekko. - Require Flutter 3.16 and Dart 3.2.
- Text parsing has been changed from asynchronous to synchronous.
This fixes an issue with the
-
8.1.025 Jul 2023Release notes
Open source →- A new base widget,
CustomStyledText, has been added that allows you to implement the construction of aRichTextwidget, for example, when using theAutoSizeTextwidget (thanks to @maeddin).
- A new base widget,
-
8.0.025 Jul 2023Release notes
Open source →-
A new parameter has been added to the
buildersignature of theStyledTextWidgetBuilderTagwidget:textContent- the text content of the tag; thanks to @ThomasGysemans.Usage example:
StyledText( text: "Famous equation: E=mc<sup>2</sup>", tags: { 'sup': StyledTextWidgetBuilderTag( (_, attributes, textContent) { return Transform.translate( offset: const Offset(0.5, -4), child: Text( textContent ?? "", textScaleFactor: 0.85, ), ); }, ), }, ),
-
-
7.0.026 Jan 2023Release notes
Open source →- Compatibility with Flutter 3.7.0.
- New parameters
contextMenuBuilder,selectionControls,selectionHeightStyle,selectionWidthStyle,onSelectionChanged,magnifierConfiguration,semanticsLabelhave been added toStyledText.selectable. - In
StyledText.selectable, thetoolbarOptionsparameter has been deprecated.
-
6.0.011 Oct 2022 -
5.1.011 Apr 2022 -
5.0.027 Feb 2022Nothing published for this version
-
5.0.0+127 Feb 2022Release notes
Open source →StyledTextnow reacts to theme and default text style changes.- Fixed flickering when rebuilding without changing text and styles.
- Removed deprecated stuff.
-
4.0.013 Dec 2021Nothing published for this version
-
4.0.0+113 Dec 2021Release notes
Open source →- [Breaking Changes] Removed deprecated widgets and classes from version 2.x.
-
3.0.409 Oct 2021Nothing published for this version
-
3.0.4+131 Oct 2021Release notes
Open source →- Fixed a bug in
StyledTextActionTag(tag's content was not passed to the first parameter of the callback).
- Fixed a bug in
-
3.0.313 Sep 2021Release notes
Open source →Attention! Deprecated constructs from version 2.x will be removed in the next update.
- Flutter 2.5 compatibility.
-
3.0.229 Jul 2021Release notes
Open source →- [Breaking Changes] In
StyledTextWidgetBuilderTag.buildernow the tag attributes are passed as the second parameter.
- [Breaking Changes] In
-
3.0.128 May 2021 -
3.0.019 May 2021 -
3.0.0-beta04 May 2021 pre-releaseNothing published for this version
-
3.0.0-beta+104 May 2021 pre-releaseNothing published for this version
-
3.0.0-beta+204 May 2021 pre-releaseRelease notes
Open source →- [Breaking Changes] Changed the way text tags are styled. Now, instead of
TextStyleand classes that implement it, you need to use new classes that describe the styles and behavior of tags. - [Breaking changes] The
newLineAsBreaksparameter is nowtrueby default. - Added the ability to insert any widgets into the text.
- [Breaking Changes] Changed the way text tags are styled. Now, instead of
-
2.0.017 Apr 2021 -
2.0.0-nullsafety.011 Mar 2021 pre-release -
1.0.314 Dec 2020Nothing published for this version
-
1.0.3+114 Dec 2020Release notes
Open source →- Added
CustomTextStyletext style, for which you can specify handling of tag attributes.
- Added
-
1.0.3+222 Jan 2021Release notes
Open source →- Made a workaround to keep whitespace between tags:
<b>bold</b>&space;<i>italic</i>. - Added
size,colorandbackgroundColorparameters toIconStyleclass.
- Made a workaround to keep whitespace between tags:
-
1.0.3+324 Jan 2021 -
1.0.3+409 Feb 2021 -
1.0.212 Nov 2020Nothing published for this version
-
1.0.2+112 Nov 2020Release notes
Open source →- Added the
StyledText.selectableconstructor to create selectable text. - Added guidance on escaping XML special characters in text.
- The deprecated
isNewLineAsBreaksparameter has been removed.
- Added the
-
1.0.129 Apr 2020Release notes
Open source →- The parameter isNewLineAsBreaks has been added, indicating not to ignore line breaks in the source text.
- Added description of parameters via doc comments.
-
1.0.1+129 Apr 2020Release notes
Open source →- The parameter isNewLineAsBreaks has been renamed to newLineAsBreaks, isNewLineAsBreaks is deprecated.
-
1.0.1+215 Sep 2020Release notes
Open source →- Improved support for DefaultTextSyle, now
styleproperty is merging with DefaultTextSyle. - Fixed a bug where no redrawing occurred when changing
styleproperty.
- Improved support for DefaultTextSyle, now
-
1.0.1+317 Sep 2020 -
1.0.017 May 2019 -
1.0.0+117 May 2019 -
1.0.0+227 Apr 2020Release notes
Open source →- Allow XML special chars: < (<), & (&), > (>), " ("), and ' (')
- Avoid memory leak log message