Converting fonts to fonts !?!

Is there an (easy) way to convert System.Drawing.Font objects to GridFontInfo objects. I want to do this because i want the user to choose his font through a regular FontDialog (i think that the FontListBox and FontComboBox aren't user friendly enough.) thanks Olivier

1 Reply

AD Administrator Syncfusion Team May 29, 2003 04:57 PM UTC

System.Drawin.Font has several properties such as FontStyle, Name and others. To initialize a GridFontInfo from such a font just set these properties manually in the GridFontInfo object. Example: System.Drawing.Font font; style.Font.FontStyle = font.FontStyle; style.Font.Size = font.SizeInPoints; style.Font.FaceName = font.Name; Stefan

Loader.
Up arrow icon