Possible to define a FONT with a saved String ?
Posted: Fri Feb 22, 2008 11:07 am
Hello from Germany,
I have a small problem :
Yesterday i added the option to the messagebar-programm,
that the user can define his own fonts.
The fontstring "NAME Arial SIZE 21 0 BOLD ITALIC"
is saved in a INI-File
Normaly i must do :
DEFINE FONT oFont NAME "Arial" SIZE 21, 0 BOLD ITALIC
The Action creates the Fontstring :
ACTION ( oSAY4:GetFont(), oSAY4:SelFont(), ;
e_FTYP4 := " NAME " + '"' + oSAY4:oFont:cFaceName + '"'+ ;
" SIZE " + ALLTRIM(STR( oSAY4:oFont:nHeight ) ) + ;
", 0 " + ;
IIF( oSAY4:oFont:lBold = .T., " BOLD", "") + ;
IIF( oSAY4:oFont:lItalic = .T., " ITALIC", "" ) )
e_FTYPE4 := is the FONT-STRING will be stored in the INI-File
But it is impossible to work with a Var like
DEFINE FONT oFont e_FTYPE4
Is there another way to handle this, to define a Font with a Var ?
Regards
Uwe
I have a small problem :
Yesterday i added the option to the messagebar-programm,
that the user can define his own fonts.
The fontstring "NAME Arial SIZE 21 0 BOLD ITALIC"
is saved in a INI-File
Normaly i must do :
DEFINE FONT oFont NAME "Arial" SIZE 21, 0 BOLD ITALIC
The Action creates the Fontstring :
ACTION ( oSAY4:GetFont(), oSAY4:SelFont(), ;
e_FTYP4 := " NAME " + '"' + oSAY4:oFont:cFaceName + '"'+ ;
" SIZE " + ALLTRIM(STR( oSAY4:oFont:nHeight ) ) + ;
", 0 " + ;
IIF( oSAY4:oFont:lBold = .T., " BOLD", "") + ;
IIF( oSAY4:oFont:lItalic = .T., " ITALIC", "" ) )
e_FTYPE4 := is the FONT-STRING will be stored in the INI-File
But it is impossible to work with a Var like
DEFINE FONT oFont e_FTYPE4
Is there another way to handle this, to define a Font with a Var ?
Regards
Uwe