Using specific fonts on MacOs

Using latest from haxelib. AddingText works.

On windows using:
#if windows
var tempotextformat:TextFormat = new TextFormat(“ARSMAQUETTEPRO-BLACK_0.OTF”, 36, 0xFFFFFF, true, null, null, null, null,CENTER, null, null, null, null);
var equipastextformat:TextFormat = new TextFormat(“ARSMAQUETTEPRO-MEDIUM.OTF”, 36, 0xFFFFFF, true, null, null, null, null,CENTER, null, null, null, null);
#end

#if flash
var tempotextformat:TextFormat = new TextFormat("ARS Maquette Pro Black", 36, 0xFFFFFF, true, null, null, null, null,CENTER, null, null, null, null);
var equipastextformat:TextFormat = new TextFormat("ARS Maquette Pro Light", 36, 0xFFFFFF, true, null, null, null, null,CENTER, null, null, null, null);
#end

works either for flash or cpp compile.

Neither of the two option work under for macos, for some reason, help ?

Try doing -verbose while you build, it should show the detected font names while building your project. That should tell you what font name string you should use in your TextFormat class

1 Like