home *** CD-ROM | disk | FTP | other *** search
/ Programming in Microsoft Windows with C# / Programacion en Microsoft Windows con C#.iso / Original Code / Text and Fonts / InstalledFontsList / InstalledFontsList.cs next >
Encoding:
Text File  |  2001-01-15  |  688 b   |  25 lines

  1. //-------------------------------------------------
  2. // InstalledFontsList.cs ⌐ 2001 by Charles Petzold
  3. //-------------------------------------------------
  4. using System;
  5. using System.Drawing;
  6. using System.Drawing.Text;
  7. using System.Windows.Forms;
  8.  
  9. class InstalledFontsList: FamiliesList
  10. {
  11.      public new static void Main()
  12.      {
  13.           Application.Run(new InstalledFontsList());
  14.      }
  15.      public InstalledFontsList()
  16.      {
  17.           Text = "InstalledFontCollection List";
  18.      }
  19.      protected override FontFamily[] GetFontFamilyArray(Graphics grfx)
  20.      {
  21.           FontCollection fc = new InstalledFontCollection();
  22.           return fc.Families;
  23.      }
  24. }
  25.