Why are there red squiggles under font file names in Android Studio? - Stack Overflow

There are lots of questions about red squiggles in Android Studio, but I could not find one for this pa

There are lots of questions about red squiggles in Android Studio, but I could not find one for this particular situation. I am posting this in case it helps someone.

I downloaded Work Sans from fonts.google, unzipped it, and moved a couple of the .ttf files into a newly-created resource folder named font. The files have red squiggles under them, but when I hover over them, no error message appears.

When I click on the files I see "Lorem ipsum..." rendered fine.

What is the issue with these files?

There are lots of questions about red squiggles in Android Studio, but I could not find one for this particular situation. I am posting this in case it helps someone.

I downloaded Work Sans from fonts.google, unzipped it, and moved a couple of the .ttf files into a newly-created resource folder named font. The files have red squiggles under them, but when I hover over them, no error message appears.

When I click on the files I see "Lorem ipsum..." rendered fine.

What is the issue with these files?

Share asked Mar 7 at 14:41 bartonstanleybartonstanley 1,32714 silver badges30 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

As downloaded, the names of the files were of the form WorkSans-SomeModifier.ttf, e.g. WorkSans-Light.ttf. I renamed the files to be of the form work_sans_some_modifier.ttf, e.g. work_sans_light.ttf, i.e. snake case. The red squiggles disappeared and I was able to reference those fonts.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744923342a4601272.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信