I’m beginning to understand a little more how to handle Corona’s api and I wanted to ask if this would be a good technique to handle fonts. I’m on a phone so I do not going to use the <>
*****************************
–In main lua set a local variable to pass a font as a string
local font = “myFont.ttf”
composer.setVariable( font )
*****************************
–In scenes
local text1 = display.newText( “Font Test!”, 100, 200, composer.getVariable(font), 16 )
*****************************
Or
*****************************
At the top of each scene module set a local variable to use “font”
local sceneFont = composer. getVariable( font)
–create
local text1 = display.newText( “Font Test!”, 100, 200, sceneFont, 16 )