How to Enumerate Installed Fonts?

You can talk about anything related to LB Booster here, not covered in another category
Post Reply
PabloSl
Posts: 2
Joined: Mon Jun 15, 2020 10:16 pm

How to Enumerate Installed Fonts?

Post by PabloSl » Mon Jun 15, 2020 10:19 pm

Hello,

I would like to have a listbox filled with the Windows installed fonts. Any code greatly apreciated.

Thank you in advance.

-Pablo

guest
Site Admin
Posts: 109
Joined: Tue Apr 03, 2018 1:34 pm

Re: How to Enumerate Installed Fonts?

Post by guest » Tue Jun 16, 2020 10:31 am

PabloSl wrote:
Mon Jun 15, 2020 10:19 pm
I would like to have a listbox filled with the Windows installed fonts. Any code greatly apreciated.
A Google search found this but it's quite old (1999) and works by exporting the font list from the registry, so I don't know how compatible with 'modern' Windows it is likely to be. It also needs tweaking to run in LBB.

Preferably use the Windows EnumFonts (or EnumFontFamilies) API function, although I've not tried it myself.

PabloSl
Posts: 2
Joined: Mon Jun 15, 2020 10:16 pm

Re: How to Enumerate Installed Fonts?

Post by PabloSl » Tue Jun 16, 2020 7:33 pm

Thank you for the info. But I have no idea how to translate that C stuff into something useful. Can somebody translate that to LB? TIA.

-Pablo

guest
Site Admin
Posts: 109
Joined: Tue Apr 03, 2018 1:34 pm

Re: How to Enumerate Installed Fonts?

Post by guest » Fri Jun 19, 2020 1:33 am

Have you considered using the standard Windows Choose Font dialog? If there is some way you could use that, it would be simpler than creating your own font selector using a LB listbox:

Image

Post Reply