fontSize = new Float(10f);
}
String style = getStyle(aci);
int weight = getWeight(aci);
FontInfo fontInfo = nativeTextHandler.getFontInfo();
String fontFamily = null;
List gvtFonts = (List) aci.getAttribute(
GVTAttributedCharacterIterator.TextAttribute.GVT_FONT_FAMILIES);
if (gvtFonts != null) {
Iterator i = gvtFonts.iterator();
while (i.hasNext()) {
GVTFontFamily fam = (GVTFontFamily) i.next();
/* (todo) Enable SVG Font painting
if (fam instanceof SVGFontFamily) {
PROXY_PAINTER.paint(node, g2d);
return;
}*/
fontFamily = fam.getFamilyName();
if (fontInfo.hasFont(fontFamily, style, weight)) {
FontTriplet triplet = fontInfo.fontLookup(
fontFamily, style, weight);
int fsize = (int)(fontSize.floatValue() * 1000);
return fontInfo.getFontInstance(triplet, fsize);
}
}
}
FontTriplet triplet = fontInfo.fontLookup("any", style, Font.WEIGHT_NORMAL);
int fsize = (int)(fontSize.floatValue() * 1000);
return fontInfo.getFontInstance(triplet, fsize);
}