mirai icon indicating copy to clipboard operation
mirai copied to clipboard

feat: Added support for font family using fonts from assets and G-Fonts

Open i-asimkhan opened this issue 1 year ago • 2 comments

Description

Added support for font family using fonts from assets and G-Fonts

Related Issues

Closes #118

Type of Change

  • [X] New feature (non-breaking change which adds functionality)
  • [ ] Bug fix (non-breaking change which fixes an issue)
  • [ ] Breaking change (fix or feature that would cause existing functionality to change)
  • [ ] Code refactor
  • [ ] Build configuration change
  • [ ] Documentation
  • [ ] Chore

i-asimkhan avatar Jul 26 '23 14:07 i-asimkhan

Hey @RodolfoSilva I have come up with something called MiraiFontFamily https://github.com/Securrency-OSS/mirai/blob/760557731389f83d6e86513b0c54bd7de6764b5c/packages/mirai/lib/src/parsers/mirai_font_family/mirai_font_family.dart#L10

This is great because it detects whether to load the font from the assets or through http (google_fonts)

i-asimkhan avatar Jul 26 '23 14:07 i-asimkhan

Hey @RodolfoSilva I have come up with something called MiraiFontFamily

https://github.com/Securrency-OSS/mirai/blob/760557731389f83d6e86513b0c54bd7de6764b5c/packages/mirai/lib/src/parsers/mirai_font_family/mirai_font_family.dart#L10

This is great because it detects whether to load the font from the assets or through http (google_fonts)

I loved this solution @i-asimkhan . It's more extensible...

RodolfoSilva avatar Jul 27 '23 08:07 RodolfoSilva