Thanks for following along! This is a tagged release (2021.1029.0).
Breaking Changes
TextFlowContainer
no longer returns raw SpriteText
s, returning ITextPart
s instead
In preparation for adding localisation support to TextFlowContainer
s, the various AddText()
/AddLine()
overloads will no longer return raw SpriteText
s. Instead, an ITextPart
structure will be returned.
Via ITextPart
, the consumer can both access all Drawables
associated with a given piece of text, as well as react to any future changes in representation of the text by subscribing to DrawablePartsRecreated
. In the future, with more localisation changes, this event will be invoked once a LocalisableString
's displayable content changes, which will trigger a recreation of all parts' drawables, upon which any manual adjustments applied to Drawables
can be re-applied again.
For consumers wanting to implement their own ITextPart
s to extend the functionality of TextFlowContainer
, an abstract TextPart
is also provided which implements the typical flow of handling Drawables
and DrawablePartsRecreated
. The only thing that a consumer has to do when inheriting that class is to implement CreateDrawablesFor(TextFlowContainer)
.
What's Changed
- Update
var
usage inspections to disallow for built-in types by @peppy in #4846 - Apply "use explicit type (built-in types)" inspection fix by @ekrctb in #4847
- Update nvika by @smoogipoo in #4848
- Add support for hardware video decoding by @Opelkuh in #4839
- Restructure
TextFlowContainer
to be backed by collection ofITextPart
s by @bdach in #4703
Full Changelog: 2021.1026.0...2021.1029.0