Remove all `.metadata` files across the monorepo and add them to
.gitignore.
They just serve to cause conflicts whenever someone runs anything and
according to @wolfenrain "we don't need them".
```
Package Name Current Version Updated Version Update Reason
flame 1.29.0 2.0.0 updated with major changes
flame_sprite_fusion 0.1.3+12 0.2.0 updated with major changes
flame_svg 1.11.12 1.11.13 updated with patch changes
flame_test 1.19.2 2.0.0 updated with major changes
flame_texturepacker 4.3.1 4.4.0 updated with minor changes
flame_tiled 3.0.3 3.0.4 updated with patch changes
flame_behavior_tree 0.1.3+12 0.1.3+13 dependency was updated
flame_oxygen 0.2.3+12 0.2.3+13 dependency was updated
flame_isolate 0.6.2+12 0.6.2+13 dependency was updated
flame_fire_atlas 1.8.7 1.8.8 dependency was updated
flame_audio 2.11.6 2.11.7 dependency was updated
flame_spine 0.2.2+12 0.2.2+13 dependency was updated
flame_bloc 1.12.13 1.12.14 dependency was updated
flame_kenney_xml 0.1.1+12 0.1.1+13 dependency was updated
flame_lottie 0.4.2+12 0.4.2+13 dependency was updated
flame_markdown 0.2.4+5 0.2.4+6 dependency was updated
flame_console 0.1.2+8 0.1.2+9 dependency was updated
flame_rive 1.10.15 1.10.16 dependency was updated
flame_forge2d 0.19.0+2 0.19.0+3 dependency was updated
flame_noise 0.3.2+12 0.3.2+13 dependency was updated
flame_riverpod 5.4.15 5.4.16 dependency was updated
flame_network_assets 0.3.3+12 0.3.3+13 dependency was updated
flame_3d 0.1.0-dev.12 0.1.0-dev.13 dependency was updated
```
The following 25 packages will be updated:
```
Package Name Current Version Updated Version Update Reason
jenny 1.3.2 1.3.3 manual versioning
flame 1.26.1 1.27.0 updated with minor changes
flame_3d 0.1.0-dev.8 0.1.0-dev.9 updated with minor changes
flame_forge2d 0.18.3 0.18.3+1 updated with patch changes
flame_isolate 0.6.2+8 0.6.2+9 updated with patch changes
flame_lint 1.2.3 1.3.0 updated with minor changes
flame_rive 1.10.11 1.10.12 updated with patch changes
flame_texturepacker 4.1.8 4.1.9 updated with patch changes
flame_tiled 2.0.3 3.0.0 updated with major changes
flame_behavior_tree 0.1.3+8 0.1.3+9 dependency was updated
flame_test 1.18.2 1.18.3 dependency was updated
flame_oxygen 0.2.3+8 0.2.3+9 dependency was updated
flame_sprite_fusion 0.1.3+8 0.1.3+9 dependency was updated
flame_fire_atlas 1.8.3 1.8.4 dependency was updated
flame_audio 2.11.2 2.11.3 dependency was updated
flame_spine 0.2.2+8 0.2.2+9 dependency was updated
flame_bloc 1.12.9 1.12.10 dependency was updated
flame_kenney_xml 0.1.1+8 0.1.1+9 dependency was updated
flame_lottie 0.4.2+8 0.4.2+9 dependency was updated
flame_markdown 0.2.4+1 0.2.4+2 dependency was updated
flame_console 0.1.2+4 0.1.2+5 dependency was updated
flame_noise 0.3.2+8 0.3.2+9 dependency was updated
flame_riverpod 5.4.11 5.4.12 dependency was updated
flame_svg 1.11.8 1.11.9 dependency was updated
flame_network_assets 0.3.3+8 0.3.3+9 dependency was updated
```
Updates to use the new color method `withValues`.
---------
Co-authored-by: Lukas Klingsbo <lukas.klingsbo@gmail.com>
Co-authored-by: Jochum van der Ploeg <jochum@vdploeg.net>
Update cicd.yml file on flame_3d to match main.
Since we finally updated main, we should require no difference
whatsoever on this file anymore.
This will require downgrading all the color changes, which is fine. This
should never have been a part of flame_3d to begin with.
Files were "untouched" by checking out the exact version as they are in
main right now (will need to rebase flame_3d to main later). I had to
add a couple more files because the files on main had dependencies on
changes that are not yet rebased on flame_3d. These extra diffs should
disappear when I do the final rebase.
This PR bumps the min sdk constraint to 3.3.0. It also updates one of
the golden tests for flame_svg which was failing with a slight
difference in the svg output around the edges. The difference was very
minor an barely noticeable visually.
```
Package Name Current Version Updated Version Update Reason
flame 1.16.0 1.17.0 manual versioning
flame_forge2d 0.17.0 0.17.1 manual versioning
flame_oxygen 0.2.0 0.2.1 manual versioning
behavior_tree 0.1.0 0.1.1 updated with minor changes
flame_behavior_tree 0.1.0 0.1.1 updated with minor changes
flame_network_assets 0.3.0 0.3.1 updated with minor changes
flame_sprite_fusion 0.1.0 0.1.1 updated with minor changes
flame_texturepacker 3.1.0 3.2.0 updated with minor changes
flame_tiled 1.19.0 1.20.0 updated with minor changes
flame_test 1.16.0 1.16.1 dependency was updated
flame_isolate 0.6.0 0.6.0+1 dependency was updated
flame_fire_atlas 1.5.0 1.5.1 dependency was updated
flame_audio 2.10.0 2.10.1 dependency was updated
flame_spine 0.2.0 0.2.0+1 dependency was updated
flame_bloc 1.11.0 1.11.1 dependency was updated
flame_lottie 0.4.0 0.4.0+1 dependency was updated
flame_markdown 0.2.0 0.2.0+1 dependency was updated
flame_rive 1.10.0 1.10.1 dependency was updated
flame_noise 0.3.0 0.3.0+1 dependency was updated
flame_riverpod 5.4.0 5.4.1 dependency was updated
flame_svg 1.10.0 1.10.1 dependency was updated
```
```
The following 18 packages will be updated:
Package Name Current Version Updated Version Update Reason
flame 1.14.0 1.15.0 updated with minor changes
flame_isolate 0.5.0+7 0.5.1 updated with minor changes
flame_noise 0.1.1+12 0.2.0 updated with major changes
flame_riverpod 5.1.5 5.2.0 updated with minor changes
flame_test 1.15.3 1.15.4 updated with patch changes
flame_texturepacker 2.1.0 3.0.0 updated with major changes
flame_oxygen 0.1.9+7 0.1.9+8 dependency was updated
flame_tiled 1.18.3 1.18.4 dependency was updated
flame_fire_atlas 1.4.7 1.4.8 dependency was updated
flame_audio 2.1.7 2.1.8 dependency was updated
flame_spine 0.1.1+9 0.1.1+10 dependency was updated
flame_bloc 1.10.9 1.10.10 dependency was updated
flame_rive 1.9.10 1.9.11 dependency was updated
flame_lottie 0.3.0+7 0.3.0+8 dependency was updated
flame_markdown 0.1.1+7 0.1.1+8 dependency was updated
flame_forge2d 0.16.0+4 0.16.0+5 dependency was updated
flame_svg 1.8.9 1.8.10 dependency was updated
flame_network_assets 0.2.0+12 0.2.0+13 dependency was updated
```
```
The following 17 packages will be updated:
Package Name Current Version Updated Version Update Reason
flame 1.11.0 1.12.0 updated with minor changes
flame_riverpod 5.0.0 5.1.0 updated with minor changes
flame_test 1.15.0 1.15.1 dependency was updated
flame_tiled 1.18.0 1.18.1 dependency was updated
flame_oxygen 0.1.9+4 0.1.9+5 dependency was updated
flame_isolate 0.5.0+4 0.5.0+5 dependency was updated
flame_fire_atlas 1.4.4 1.4.5 dependency was updated
flame_audio 2.1.4 2.1.5 dependency was updated
flame_spine 0.1.1+6 0.1.1+7 dependency was updated
flame_bloc 1.10.6 1.10.7 dependency was updated
flame_lottie 0.3.0+4 0.3.0+5 dependency was updated
flame_markdown 0.1.1+4 0.1.1+5 dependency was updated
flame_rive 1.9.7 1.9.8 dependency was updated
flame_forge2d 0.16.0+1 0.16.0+2 dependency was updated
flame_noise 0.1.1+9 0.1.1+10 dependency was updated
flame_svg 1.8.6 1.8.7 dependency was updated
flame_network_assets 0.2.0+9 0.2.0+10 dependency was updated
```
While studying the existing text rendering pipeline and infrastructure, in order to better document it and add some easier user-facing ways to render rich text, I found it to be on a slightly overcomplicated state that seems to me to be an artifact of a migration.
Let me first briefly describe how it works with some diagrams (I am writing docs for everything and will re-use this content but wanted to propose this PR first as it will change how things look like).
We have 3 hierarchies related to rendering:
renderers: children of TextRenderer, these define how to render text (style). do not include text
formatters: children of TextFormatter, this also define how to render text (style), but a bit more higher level than TextRenderer.
elements: these are laid-out, styled and ready-render pieces of text (style + string), created by formatters
Note that the renderers and formatters kinda serve the same purpose, but the renderers are a more low-level API. Here is how it it looks like today:
Not only that but all of our TextRenderer are actually FormatterTextRenderer, which just use a formatter to "comply" with the "renderer" interface. There are no "raw" TextRenderers anymore.
This current structure seems to clearly derive from an unfinished transition into the new, higher level and more flexible "formatter" structure while still supporting the "renderers" while we transition. That transition, though, seems to have completed.
The current state makes things more complicated as our current versions of components (TextComponent and TextBoxComponent), specifically the former, have branching code to support both the raw TextRenderer and the specific FormatterTextRenderer implementation, which breaks the inheritance encapsulation and voids its purpose in the first place.
The purpose of this PR is to simplify this class structure by:
remove the base TextRenderer
rename FormatterTextRenderer to TextRenderer: all renderers are formatter-based now
update all references
simplify the code of the components by only dealing with (former FormatterTextRenderer) TextRenderers
This is what it looks like now:
Note that while this is a breaking change, it should not affect most users as they should be using much more user-facing classes, like the aforementioned components, instead of the backing implementations. In fact even if they use the renderers, they probably use one of the concrete implementations anyway, TextPaint or SpriteFontRenderer. Notwithstanding, I added migration instructions below.
This is a small step towards a world where we completely combine the converts of renderers and formatters, as, in my eyes, they do the same thing (carry the style information w/o the text).
Possible future (but definitely breaking) changes:
remove renderers entirely and use formatters directly
consider renaming formatters to renderers (or not)
rename TextPaint as the name does not make sense in any hierarchical model we use
(what I am really interested in): allow the creation of text_ and text_box_ components directly from renderers + elements
# Description
This does two things:
## Use double quotes for SDK constraints
Standardize the usage of single or double quotes to specify sdk
constraints across pubspecs
I see no reason this should not be kept consistent
I also see no reason to prefer one over the other, so I searched the
code base and there are 7 instances of single quote vs 32 of double
quotes, so I favored the later
## Update all SDK constraints to 2.18
Let me know if there are any issues with it, but I believe we should
keep this consistent across all packages.
Also there is a pubspec on root which imply all should be on 2.18
anyway.
## Checklist
- [x] I have followed the [Contributor Guide] when preparing my PR.
- [x] I have updated/added tests for ALL new/updated/fixed
functionality.
- [x] I have updated/added relevant documentation in `docs` and added
dartdoc comments with `///`.
- [x] I have updated/added relevant examples in `examples` or `docs`.
## Breaking Change?
- [ ] Yes, this PR is a breaking change.
- [x] No, this PR is not a breaking change.
<!-- Links -->
[Contributor Guide]:
https://github.com/flame-engine/flame/blob/main/CONTRIBUTING.md
[Conventional Commit]: https://conventionalcommits.org/
[CHANGELOG]:
https://github.com/flame-engine/flame/blob/main/CHANGELOG.md
Co-authored-by: Lukas Klingsbo <me@lukas.fyi>