Author: acumiskey
Date: Tue Nov 18 01:48:38 2008
New Revision: 718536
URL: http://svn.apache.org/viewvc?rev=718536&view=rev
Log:
Default 10pt font fallback removed.
Modified:
xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/afp/svg/AFPTextPainter.java
Modified:
xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/afp/svg/AFPTextPainter.java
URL:
http://svn.apache.org/viewvc/xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/afp/svg/AFPTextPainter.java?rev=718536&r1=718535&r2=718536&view=diff
==============================================================================
---
xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/afp/svg/AFPTextPainter.java
(original)
+++
xmlgraphics/fop/branches/Temp_AFPGOCAResources/src/java/org/apache/fop/afp/svg/AFPTextPainter.java
Tue Nov 18 01:48:38 2008
@@ -115,8 +115,8 @@
private boolean hasUnsupportedAttributes(AttributedCharacterIterator aci) {
boolean hasUnsupported = false;
+ Font font = getFont(aci);
String text = getText(aci);
- Font font = makeFont(aci);
if (hasUnsupportedGlyphs(text, font)) {
log.trace("-> Unsupported glyphs found");
hasUnsupported = true;
@@ -228,8 +228,10 @@
loc = at.transform(loc, null);
// font
- Font font = makeFont(aci);
- nativeTextHandler.setOverrideFont(font);
+ Font font = getFont(aci);
+ if (font != null) {
+ nativeTextHandler.setOverrideFont(font);
+ }
// color
TextPaintInfo tpi = (TextPaintInfo) aci.getAttribute(
@@ -333,11 +335,8 @@
: Font.WEIGHT_NORMAL;
}
- private Font makeFont(AttributedCharacterIterator aci) {
+ private Font getFont(AttributedCharacterIterator aci) {
Float fontSize = (Float)aci.getAttribute(TextAttribute.SIZE);
- if (fontSize == null) {
- fontSize = new Float(10.0f);
- }
String style = getStyle(aci);
int weight = getWeight(aci);
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]