Display all installed fonts in a RibbonComboBox.

Topics related to the Krypton Ribbon.

Moderators: Phil Wright, Chris Porter

Display all installed fonts in a RibbonComboBox.

Postby Mark_Greenwood » Fri Sep 30, 2011 7:16 pm

The title says it all. I'm making a test word processor and I need to display and be able to choose fonts that are installed. I can deal with the rest, I just need to know how I can display and then choose a font.

*EDIT*: May I also add that I would like the same with another combobox but then display available sizes.

Thank you very much.
Steps to the internets climax: 1) UKF Dubstep. 2) Loud. 3) Visual Studio + Krypton Suite. 4) ???? 5) Profit !!!11!1one
User avatar
Mark_Greenwood
 
Posts: 2
Joined: Tue Sep 27, 2011 5:57 am
Location: Montreal, QC, Canada

Re: Display all installed fonts in a RibbonComboBox.

Postby spidergeuse » Fri Oct 14, 2011 9:39 am

You may try something like this
Code: Select all
            System.Drawing.Text.InstalledFontCollection fonts = new System.Drawing.Text.InstalledFontCollection();
            foreach (FontFamily family in fonts.Families)
            {
                kryptonRibbonGroupComboBox1.Items.Add(family.Name);
            }
spidergeuse
 
Posts: 11
Joined: Thu Oct 01, 2009 10:27 pm


Return to Krypton Ribbon

Who is online

Users browsing this forum: No registered users and 0 guests

cron