You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Shey Rab Pawo <pa...@gmail.com> on 2005/02/16 08:28:44 UTC
Odd temp file being created: "+~JF38289.tmp"
I hope that this is a Tomcat question. I am using Tomcat 5.0 and
Struts 1.2.6. I am getting a temp file seemingly related to my fonts
whenever I dynamically create new image buttons on the fly, which I do
on almost all pages, and then cache them. My code to get the fonts,
reading from .ttf files, is as follows:
public synchronized static Font getFont(String fontLogicalName,
Map attributes) {
File file = null;
Font font = null;
FileInputStream fontStream = null;
String physicalName = null;
String familyName = null;
boolean realValue = true;
physicalName = (String)fonts.get(fontLogicalName + "FONT");
familyName = (String)fonts.get(fontLogicalName + "FAMILY");
attributes.put(TextAttribute.FONT,fontLogicalName);
attributes.put(TextAttribute.FAMILY,familyName);
if(physicalName == null) {
try {
font = new Font(attributes);
} catch (Exception e) {
// ERROR HANDLING
}
}
try {
file = new File(MY_CLASSPATH_TO_FONT_FILE);
fontStream = new FileInputStream(file);
font = Font.createFont(Font.TRUETYPE_FONT,fontStream);
font = font.deriveFont(attributes);
fontStream.close();
} catch (FileNotFoundException fnfe) {
// ERROR HANDLING
} catch (IOException ioe) {
// ERROR HANDLING
} catch (FontFormatException ffe) {
// ERROR HANDLING
}
return font;
}
Does anyone see why I am getting these files? Is this Tomcat related?
The names are like "+~JF38289.tmp". Any help?
--
The radiance of all the stars does not equal a sixteenth part of the
moon's radiance, likewise, good deeds giving us merit, all these do
not equal a sixteenth part of the merit of loving-kindness..
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org