BufferedImage img = new BufferedImage(800, 300, BufferedImage.TYPE_INT_ARGB); Graphics g = img.getGraphics();
InputStream fi = Thread.currentThread().getContextClassLoader().getResourceAsStream("fonts/msyh.ttf"); BufferedInputStream bisYh = new BufferedInputStream(fi); Font yahei = Font.createFont(Font.TRUETYPE_FONT, bisYh);