Date: 02-16-2022
Return to Index
created by gbSnippets
'Compilable Example: (Jose Includes)
'font from http://www.twyman.org.uk/Fonts/
#Compiler PBWin 9, PBWin 10
#Compile EXE
#Dim All
%Unicode=1
#Include "Win32API.inc"
%IDC_Label = 500
Global hDlg,hFont As Dword, fName$
Function PBMain() As Long
Dialog New Pixels, 0, "LED Font Test",300,300,400,75, %WS_OverlappedWindow To hDlg
Control Add Label, hDlg, %IDC_Label,"0123456789 ABC HIJ hij xyz", 10,10,380,30
fName = EXE.Path$ + "led.ttf"
AddFontResource(ByVal StrPtr(fName))
Font New "7 Segment", 20, 0, %Symbol_Charset To hFont
Control Set Font hDlg, %IDC_Label, hFont
Dialog Show Modal hDlg
DeleteObject hFont
RemoveFontResource(ByVal StrPtr(fName))
End Function
'gbs_00897
'Date: 03-10-2012
http://www.garybeene.com/sw/gbsnippets.htm