Is there a way to get a list of all fonts?
Blitz3D Forums/Blitz3D Beginners Area/Is there a way to get a list of all fonts?
| ||
I'm not really sure which forum this should be in, but here goes: For an obscure reason, I want to have all fonts loaded into an array. eg I want to be able to do Setfont(Font(i)) To get all fonts into Font() I tried loading them based on their filename. Unfortunately, it wants their "font name" which apparently isn't the same thing. For example: Loadfont("Times New Roman") works fine. Loadfont("Times") doesn't. Where can I get a list of all the font names? On the off-chance anyone has a clue what I'm talking about, thanks in advance :) |
| ||
I'm interested too... I think people who write software that enumerates the fonts available on the system access the Windows API... Also, font information is contained in the registry, under this key in Win98: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts I know this is not much help, but hopefully someone who knows more will see your post :) |
| ||
Interestingly it's not under that key on my machine. It's under: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Fonts On Win 98SE as well! Lord knows why. |
| ||
oops I stand corrected thanks MasterBeaker |
| ||
Thanks guys, mine's in the same place as Masterbeaker's using 98 version 4.1 I exported them to a text file in regedit and I made Blitz convert them into a workable font list. I can at least get the program working with this. However whenever I add new fonts, I'd have to export again. It'd also only work on this computer. Is there anyway I can access the registry through Blitz? Thanks, God knows what I'd do without this forum |
| ||
there's this DLL, but I believe it has issues readingat the moment. *EDIT* or maybe this one? |
| ||
They are the same one. |