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
Hello,
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: 2426
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
Hi,
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
https://bugs.eclipse.org/bugs/show_bug.cgi?id=373270
Best,
Ivan

--
Ivan Furnadjiev

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

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


Current Time: Wed Apr 24 17:14:33 GMT 2024

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

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

Back to the top