Completed
Last Updated: 27 May 2019 10:51 by ADMIN
Release Fixed in R2 2019 (LIB 2019.2.603)
Hristo
Created on: 16 May 2019 05:30
Category: FontDropDownList
Type: Feature Request
0
RadFontDropDownList: Expose API to programmatically load fonts
The new feature will allow custom fonts to be loaded in the control. We can already load custom fonts using the ThemeResolutionService class. We could use the custom in-memory font loaded by the ThemeResolutionService and add it to the FontDropDownList.
2 comments
ADMIN
Dimitar
Posted on: 27 May 2019 10:51
Hello,

Item will be released in 2019 R2 SP1 and LIB 2019.2.603 scheduled for 3rd of June.

The new feature will allow custom fonts to be loaded in the control. We can already load custom fonts using the ThemeResolutionService class. We could use the custom in-memory font loaded by the ThemeResolutionService and add it to the FontDropDownList.

A custom font can be loaded this way:
using (Stream stream = System.Reflection.Assembly.GetAssembly(this.GetType()).GetManifestResourceStream("_408823_RadRichTextEditorCustomFonts.HelveticaLt.ttf"))
{
   ThemeResolutionService.LoadFont(stream);
}
 
FontFamily ff = ThemeResolutionService.GetCustomFont("Helvetica-Light");
this.radFontDropDownList1.AddFont(ff);
...
this.radFontDropDownList1.RemoveFont(ff);

The above methods have overloads accepting the font family name as string.

Regards,
Dimitar
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
ADMIN
Hristo
Posted on: 16 May 2019 05:46
Hi,

The item is already in development and the feature will be made available with the 2019 R2 SP1 release.

Regards,
Hristo
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.