- boolean accurateText = true;
-
- String renderStyle = jalview.bin.Cache.getDefault("EPS_RENDERING",
- "Prompt each time");
-
- // If we need to prompt, and if the GUI is visible then
- // Prompt for EPS rendering style
- if (renderStyle.equalsIgnoreCase("Prompt each time")
- && !(System.getProperty("java.awt.headless") != null && System
- .getProperty("java.awt.headless").equals("true")))
- {
- EPSOptions eps = new EPSOptions();
- renderStyle = eps.getValue();
-
- if (renderStyle == null || eps.cancelled)
- {
- return;
- }
- }
-
- if (renderStyle.equalsIgnoreCase("text"))
- {
- accurateText = false;
- }
-
- try
- {
- pg = new EpsGraphics2D(title, out, 0, 0, width, height);
- Graphics2D ig2 = (Graphics2D) pg;
- ig2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
- RenderingHints.VALUE_ANTIALIAS_ON);
-
- pg.setAccurateTextMode(accurateText);
-
- graphics = pg;
- } catch (Exception ex)
- {
- }
+ bi = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
+ graphics = bi.getGraphics();
+ Graphics2D ig2 = (Graphics2D) graphics;
+ ig2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
+ RenderingHints.VALUE_ANTIALIAS_ON);