Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Check font range which can be rendered by a certain selected font
Check font range which can be rendered by a certain selected font [message #1700671] Mon, 06 July 2015 11:36 Go to next message
Sorin Carbunaru is currently offline Sorin CarbunaruFriend
Messages: 4
Registered: July 2015
Junior Member
Hi,

I am building a character map dialog in SWT. It's a dialog in which you select a font from a combo box and then see a table with all the characters that the font can render.
I can retrieve all platform fonts using:

FontData[] availableFontsData = Display.getDefault().getFontList(null, true);


but I do not know how to test if a specific font can render a certain character.
So I need the SWT equivalent of java.awt.Font.canDisplay(char) or a workaround.

Regards,
Sorin
Re: Check font range which can be rendered by a certain selected font [message #1700746 is a reply to message #1700671] Mon, 06 July 2015 18:37 Go to previous message
Eclipse UserFriend
Unfortunately there is no such API at present (see bug 32120). The best workaround for now is to load the corresponding AWT font and use the same check. Of course, contributions are always welcome.

Brian.
Previous Topic:SWTBrowser langauge
Next Topic:Package Selection Dialog
Goto Forum:
  


Current Time: Tue Mar 19 10:51:40 GMT 2024

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

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

Back to the top