TMP_FontAsset.frontInfo is obsolete

Anyone know how to fix this line

float capHeight = cInfo.baseLine + cInfo.fontAsset.fontInfo.CapHeight * cInfo.scale;

Assets\TextMesh Pro\Examples & Extras\Scripts\TMP_TextInfoDebugTool.cs(135,52): warning CS0618: ‘TMP_FontAsset.fontInfo’ is obsolete: ‘The fontInfo property and underlying type is now obsolete. Please use the faceInfo property and FaceInfo type instead.’

Font Assets should be automatically upgraded to new format.

CapHeight is the top of lowercase letters which you can manually set in the Face Info in the Inspector. To help you visualize this, you can add the TMP_TextInfoDebugTool.cs script included in the TMP Examples & Extras to any Text object

I was searching the web for this warning. It’s the only warning in my project and i don’t know how to eliminate it. I don’t think it has any impact on my project, but it annoys me quite a bit… .I run Version 3.0.6 of TMP.

2 Likes