import java.io.*; import sun.io.*; public class SymbolChart { public static void main(String[] args) { try { FileOutputStream theChart = new FileOutputStream("chart.out"); ByteToCharConverter SymbolToUnicode = ByteToCharConverter.getConverter("MacSymbol"); byte[] symbol = new byte[256]; for (int i = 0; i < 256; i++) symbol[i] = (byte) i; char[] unicode = SymbolToUnicode.convertAll(symbol); for (int i = 0; i < 256; i++) { theChart.write((byte) i); String s = "\t" + i + "\t" + ((int) unicode[i]) + "\n"; theChart.write(s.getBytes()); } theChart.close(); } catch (Exception e) { System.err.println(e); } } }