Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

霓虹灯效果那个有问题 #1

Open
xinshengBoy opened this issue Dec 24, 2019 · 1 comment
Open

霓虹灯效果那个有问题 #1

xinshengBoy opened this issue Dec 24, 2019 · 1 comment

Comments

@xinshengBoy
Copy link

看了一下那个霓虹灯的效果,在计算文字长度的时候是不是需要将padding也计算进去呢。
如果文字长度不够一行的话,比如十个字左右的话,光影不会走到文字的最后面就会返回了

@baopengjian
Copy link
Owner

是的,这里主要是LinearGradient的API应用,实际案例中的padding根据自己的需求加上去,LinearGradient的构造方法可以修改参数

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants