Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes forum!
    Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

"fonts not found"

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator

everyday a new problem.

i have a simple program (below). Works fine on my laptop. when i run the same thing on a unix server, i get an error, telling me that FontManager can't find the fonts. it sounds like a problem with the java installation on unix. i can see font files in the /lib/fonts directory. doesn't make sense to me.

any suggestions on what the problem might be?

java.lang.Error: Probable fatal error:No fonts found.
:at sun.font.FontManager.getDefaultPhysicalFont(FontManager.java:1095)
:at sun.font.FontManager.initialiseDeferredFont(FontManager.java:966)
:at sun.font.FontManager.initialiseDeferredFonts(FontManager.java:791)

etc......

import java.awt.Font;
import java.awt.GraphicsEnvironment;
public class FontFamilyNameList {
public static void main(String[] args) {
// Get all available font family names from GraphicsEnvironment
System.setProperty("java.awt.headless", "true");
GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
String familyNames[] = ge.getAvailableFontFamilyNames();
for (String familyName : familyNames) {
System.out.println("Family names: " + familyName);
}
}
}

 
Greenhorn
Posts: 21
Eclipse IDE Oracle Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
try to read this discussion.

Probable fatal error: No fonts found
 
Sheriff
Posts: 22684
128
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Once is enough, Bill. UseOneThreadPerQuestion. Because your other thread has more information in the starting post I'll close this one but link to it in the other one because of Myk's post.
 
Please do not shoot the fish in this barrel. But you can shoot at this tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
    Bookmark Topic Watch Topic
  • New Topic