You should add a font before setting it, not after. The ON INIT event starts later than SET FONT and therefore does not work.
Code: Select all
(...)
IF ! FILE( CMedia + 'Fonts\tecnico.fino.ttf' )
MSGBOX( "No existe el archivo")
* STRFILE ( HMG_LoadResourceRawFile ( 'tecnico', RT_RCDATA ), 'tecnico.fino.ttf' )
ENDIF
AddFont( CMedia + 'Fonts\tecnico.fino.ttf' )
DEFINE WINDOW Form_1 AT 0 , 0 WIDTH 640 HEIGHT 480 NOSIZE MAIN BACKCOLOR { 000, 023, 052 } ;
ON INIT msgbox ("ON INIT") ;
ON RELEASE RemoveFont( CMedia + 'Fonts\tecnico.fino.ttf' )
SET FONT TO "tecnico", 13
msgbox ("Set font")
*-----------------------------------------------------------------------------------
(...)