TransWikia.com

How to specify font size in nifty GUI when using ttf fonts

Game Development Asked by Teeracroptus on November 2, 2021

I’m trying to use a font with a larger size in a ttf file using nifty GUI. All questions and answers I’ve seen are concerned with making fonts in fnt fonts in a different size, but the size I want to use is actually included in the ttf file. I tried setting fontSize and size attributes with no effect (no errors but the font size does not change either)

Below is the xml excerpt where I’m trying to use the ttf font with a large size:

<control id="score"
name="label"
color="#fff"
text="0"
width="50%"
height="20%"
textHAlign="left"
font="Interface/Fonts/Kenney Future.ttf"/>

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP