1 4 5 9 10 package org.openlaszlo.test; 11 12 import java.io.*; 13 import org.openlaszlo.utils.FileUtils; 14 import org.apache.log4j.*; 15 16 import org.apache.batik.svggen.font.*; 18 import org.apache.batik.svggen.font.table.*; 19 20 public class ttfdump { 21 static public void main (String args[]) { 22 try { 23 File src = new File (args[0]); 24 System.out.println("Trying " + src.getPath()); 25 org.apache.batik.svggen.font.Font ttf; 26 ttf = org.apache.batik.svggen.font.Font.create(src.getPath()); 27 NameTable nameTable = ttf.getNameTable(); 28 System.out.println("Font name: " + nameTable.getRecord((short)1)); 29 } catch (Exception e) { 30 e.printStackTrace(); 31 } 32 } 33 } 34 | Popular Tags |