aagarwal1012 / Animated-Text-Kit

🔔 A flutter package to create cool and beautiful text animations. [Flutter Favorite Package]
https://animated-text-kit.web.app
MIT License
1.65k stars 305 forks source link

Fix position in wavy animation #242

Closed SirusCodes closed 3 years ago

SirusCodes commented 3 years ago

Fixes #235

There were 2 issues which caused the position issue...

  1. CustomPainter was given full size of screen which caused the widget to paint in center while animating and otherwise where the parent positioned it.
  2. Canvas was sizing in the text inappropriately because TextPainter by default uses 1.0 as textScaleFactor while widgets took 0.85.
codecov[bot] commented 3 years ago

Codecov Report

Merging #242 (73b14e4) into master (0a4c2c3) will increase coverage by 0.07%. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #242      +/-   ##
==========================================
+ Coverage   95.31%   95.38%   +0.07%     
==========================================
  Files          10       10              
  Lines         448      455       +7     
==========================================
+ Hits          427      434       +7     
  Misses         21       21              
Impacted Files Coverage Δ
lib/src/wavy.dart 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 0a4c2c3...73b14e4. Read the comment docs.