Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Loading a font .ttf file
Loading a font .ttf file [message #1385942] Thu, 12 June 2014 11:45 Go to next message
jps90 Mising name is currently offline jps90 Mising nameFriend
Messages: 13
Registered: December 2011
Junior Member
I want to use my own font in a RAP-Application. The font is in a .ttf file. Is there any possiblity to load it into my Application?

For RCP I found the following:
final String path = "fonts/myFont.ttf";
final URL pathUrl = BundleUtility.find(PLUGIN_ID, path);
final boolean isFontLoaded = Display.getCurrent().loadFont(pathUrl.toExternalForm());

But the method loadFont() does not exist in my RAP-Application.
Does anyone have a clue how to do it?

Thanks in advance.
Re: Loading a font .ttf file [message #1386294 is a reply to message #1385942] Mon, 16 June 2014 12:01 Go to previous message
Ivan Furnadjiev is currently offline Ivan FurnadjievFriend
Messages: 2334
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
the fonts, used by RAP application, must be available/installed on the
client, not on the server. Using custom fonts in a Web application is
possible with so called web-fonts. Unfortunately, web font support is
still missing in RAP. See this bug:
373270: Enable web fonts in RAP

Ivan Furnadjiev

Twitter: @EclipseRAP

Professional services for RAP and RCP?
Previous Topic:How to add custom html attributes
Next Topic:RAP e4 for Luna. How to install?
Goto Forum:

Current Time: Thu Feb 20 19:08:51 GMT 2020

Powered by FUDForum. Page generated in 0.02320 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top