Index: src/main/java/org/apache/pdfbox/encoding/Encoding.java
===================================================================
--- src/main/java/org/apache/pdfbox/encoding/Encoding.java	(revision 826050)
+++ src/main/java/org/apache/pdfbox/encoding/Encoding.java	(working copy)
@@ -20,6 +20,7 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.InputStreamReader;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.Map;
@@ -149,7 +150,16 @@
     }
     
 
+    public Map getCodeToNameMap()
+    {
+        return Collections.unmodifiableMap(codeToName);
+    }
 
+    public Map getNameToCodeMap()
+    {
+        return Collections.unmodifiableMap(nameToCode);
+    }
+
     /**
      * This will add a character encoding.
      *
Index: src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java
===================================================================
--- src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java	(revision 0)
+++ src/main/java/org/apache/pdfbox/pdmodel/font/PDType1CFont.java	(revision 0)
@@ -0,0 +1,553 @@
+/*
+ * Copyright (c) 2009 Villu Ruusmann
+ */
+package org.apache.pdfbox.pdmodel.font;
+
+import java.awt.Font;
+import java.awt.FontFormatException;
+import java.awt.Graphics;
+import java.awt.Graphics2D;
+import java.awt.RenderingHints;
+import java.awt.geom.AffineTransform;
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.InputStream;
+import java.io.IOException;
+import java.lang.reflect.Field;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.apache.fontbox.afm.AFMParser;
+import org.apache.fontbox.afm.FontMetric;
+import org.apache.fontbox.cff.AFMFormatter;
+import org.apache.fontbox.cff.CFFCharset;
+import org.apache.fontbox.cff.CFFEncoding;
+import org.apache.fontbox.cff.CFFFont;
+import org.apache.fontbox.cff.CFFParser;
+import org.apache.fontbox.cff.Type1FontFormatter;
+
+import org.apache.pdfbox.cos.COSArray;
+import org.apache.pdfbox.cos.COSBase;
+import org.apache.pdfbox.cos.COSDictionary;
+import org.apache.pdfbox.cos.COSName;
+import org.apache.pdfbox.cos.COSNumber;
+import org.apache.pdfbox.cos.COSStream;
+import org.apache.pdfbox.encoding.Encoding;
+import org.apache.pdfbox.encoding.EncodingManager;
+import org.apache.pdfbox.pdmodel.common.PDRectangle;
+
+public class PDType1CFont extends PDSimpleFont
+{
+    private CFFFont cffFont = null;
+
+    private Map/*<Integer, String>*/ codeToName = new HashMap();
+
+    private Map/*<Integer, String>*/ codeToCharacter = new HashMap();
+
+    private Map/*<String, Integer>*/ characterToCode = new HashMap();
+
+    private FontMetric fontMetric = null;
+
+    private Font awtFont = null;
+
+    private Map/*<String, Float>*/ glyphWidths = new HashMap();
+
+    private Map/*<String, Float>*/ glyphHeights = new HashMap();
+
+    private Float avgWidth = null;
+
+    private PDRectangle fontBBox = null;
+
+
+    public PDType1CFont( COSDictionary fontDictionary )
+    {
+        super( fontDictionary );
+    }
+
+    public String encode( byte[] bytes, int offset, int length ) throws IOException
+    {
+        ensureLoaded();
+
+        String character = getCharacter(bytes, offset, length);
+        if( character == null )
+        {
+            log.debug("No character for code " + (bytes[offset] & 0xff) + " in " + this.cffFont.getName());
+
+            return null;
+        }
+
+        return character;
+    }
+
+    private String getCharacter( byte[] bytes, int offset, int length )
+    {
+        if( length != 1)
+        {
+            return null;
+        }
+
+        Integer code = Integer.valueOf(bytes[offset] & 0xff);
+
+        return (String)this.codeToCharacter.get(code);
+    }
+
+    public float getFontWidth( byte[] bytes, int offset, int length ) throws IOException
+    {
+        ensureLoaded();
+
+        String name = getName(bytes, offset, length);
+        if( name == null && !Arrays.equals(SPACE_BYTES, bytes) )
+        {
+            log.debug("No name for code " + (bytes[offset] & 0xff) + " in " + this.cffFont.getName());
+
+            return 0;
+        }
+
+        Float width = (Float)this.glyphWidths.get(name);
+        if( width == null )
+        {
+            width = Float.valueOf(this.fontMetric.getCharacterWidth(name));
+            this.glyphWidths.put(name, width);
+        }
+
+        return width.floatValue();
+    }
+
+    public float getFontHeight( byte[] bytes, int offset, int length ) throws IOException
+    {
+        ensureLoaded();
+
+        String name = getName(bytes, offset, length);
+        if( name == null )
+        {
+            log.debug("No name for code " + (bytes[offset] & 0xff) + " in " + this.cffFont.getName());
+
+            return 0;
+        }
+
+        Float height = (Float)this.glyphHeights.get(name);
+        if( height == null )
+        {
+            height = Float.valueOf(this.fontMetric.getCharacterHeight(name));
+            this.glyphHeights.put(name, height);
+        }
+
+        return height.floatValue();
+    }
+
+    private String getName( byte[] bytes, int offset, int length )
+    {
+        if( length != 1 )
+        {
+            return null;
+        }
+
+        Integer code = Integer.valueOf(bytes[offset] & 0xff);
+
+        return (String)this.codeToName.get(code);
+    }
+
+    public float getStringWidth( String string ) throws IOException
+    {
+        ensureLoaded();
+
+        float width = 0;
+
+        for( int i = 0; i < string.length(); i++ )
+        {
+            String character = string.substring(i, i + 1);
+
+            Integer code = getCode(character);
+            if( code == null )
+            {
+                log.debug("No code for character " + character);
+
+                return 0;
+            }
+
+            width += getFontWidth(new byte[]{(byte)code.intValue()}, 0, 1);
+        }
+
+        return width;
+    }
+
+    private Integer getCode( String character )
+    {
+        return (Integer)this.characterToCode.get(character);
+    }
+
+    public PDFontDescriptor getFontDescriptor() throws IOException
+    {
+        ensureLoaded();
+
+        return new PDFontDescriptorAFM(this.fontMetric);
+    }
+
+    public float getAverageFontWidth() throws IOException
+    {
+        ensureLoaded();
+
+        if( this.avgWidth == null )
+        {
+            this.avgWidth = Float.valueOf(this.fontMetric.getAverageCharacterWidth());
+        }
+
+        return this.avgWidth.floatValue();
+    }
+
+    public PDRectangle getFontBoundingBox() throws IOException
+    {
+        ensureLoaded();
+
+        if( this.fontBBox == null )
+        {
+            this.fontBBox = new PDRectangle(this.fontMetric.getFontBBox());
+        }
+
+        return this.fontBBox;
+    }
+
+    public void drawString( String string, Graphics g, float fontSize, AffineTransform at, float x, float y ) throws IOException
+    {
+        ensureLoaded();
+
+        Graphics2D g2d = (Graphics2D)g;
+        g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
+        writeFont(g2d, at, this.awtFont, fontSize, x, y, string);
+    }
+
+    private void ensureLoaded() throws IOException
+    {
+        if( this.cffFont != null )
+        {
+            return;
+        }
+
+        byte[] cffBytes = loadBytes();
+
+        CFFParser cffParser = new CFFParser();
+        List fonts = cffParser.parse(cffBytes);
+
+        this.cffFont = (CFFFont)fonts.get(0);
+
+        CFFEncoding encoding = this.cffFont.getEncoding();
+        PDFEncoding pdfEncoding = new PDFEncoding(encoding);
+
+        CFFCharset charset = this.cffFont.getCharset();
+        PDFCharset pdfCharset = new PDFCharset(charset);
+
+        Map charStringsDict = this.cffFont.getCharStringsDict();
+        Map pdfCharStringsDict = new LinkedHashMap();
+        pdfCharStringsDict.put(".notdef", charStringsDict.get(".notdef"));
+
+        Map codeToName = new LinkedHashMap();
+
+        Collection mappings = this.cffFont.getMappings();
+        for( Iterator it = mappings.iterator(); it.hasNext(); )
+        {
+            CFFFont.Mapping mapping = (CFFFont.Mapping)it.next();
+
+            Integer code = Integer.valueOf(mapping.getCode());
+            String name = mapping.getName();
+
+            codeToName.put(code, name);
+        }
+
+        Set knownNames = new HashSet(codeToName.values());
+
+        Map codeToNameOverride = loadOverride();
+        for( Iterator it = (codeToNameOverride.entrySet()).iterator(); it.hasNext(); )
+        {
+            Map.Entry entry = (Map.Entry)it.next();
+
+            Integer code = (Integer)entry.getKey();
+            String name = (String)entry.getValue();
+
+            if(knownNames.contains(name)){
+                codeToName.put(code, name);
+            }
+        }
+
+        Map nameToCharacter;
+
+        try
+        {
+            Field nameToCharacterField = Encoding.class.getDeclaredField("NAME_TO_CHARACTER");
+            nameToCharacterField.setAccessible(true);
+
+            nameToCharacter = (Map)nameToCharacterField.get(null);
+        }
+        catch( Exception e )
+        {
+            throw new RuntimeException(e);
+        }
+
+        for( Iterator it = (codeToName.entrySet()).iterator(); it.hasNext(); )
+        {
+            Map.Entry entry = (Map.Entry)it.next();
+
+            Integer code = (Integer)entry.getKey();
+            String name = (String)entry.getValue();
+
+            String uniName = "uni";
+
+            String character = (String)nameToCharacter.get(COSName.getPDFName(name));
+            if( character != null )
+            {
+                for( int j = 0; j < character.length(); j++ )
+                {
+                    uniName += hexString(character.charAt(j), 4);
+                }
+            }
+            else
+
+            {
+                uniName += hexString(code.intValue(), 4);
+                character = String.valueOf((char)code.intValue());
+            }
+
+            pdfEncoding.register(code.intValue(), code.intValue());
+            pdfCharset.register(code.intValue(), uniName);
+
+            this.codeToName.put(code, uniName);
+
+            this.codeToCharacter.put(code, character);
+            this.characterToCode.put(character, code);
+
+            pdfCharStringsDict.put(uniName, charStringsDict.get(name));
+        }
+
+        this.cffFont.setEncoding(pdfEncoding);
+        this.cffFont.setCharset(pdfCharset);
+
+        charStringsDict.clear();
+        charStringsDict.putAll(pdfCharStringsDict);
+
+        this.fontMetric = prepareFontMetric(this.cffFont);
+
+        this.awtFont = prepareAwtFont(this.cffFont);
+
+        Number defaultWidthX = (Number)this.cffFont.getProperty("defaultWidthX");
+        this.glyphWidths.put(null, Float.valueOf(defaultWidthX.floatValue()));
+    }
+
+    private byte[] loadBytes() throws IOException
+    {
+        COSDictionary fontDic = (COSDictionary)super.font.getDictionaryObject(COSName.FONT_DESC);
+        if( fontDic != null )
+        {
+            COSStream ff3Stream = (COSStream)fontDic.getDictionaryObject("FontFile3");
+            if( ff3Stream != null )
+            {
+                ByteArrayOutputStream os = new ByteArrayOutputStream();
+
+                InputStream is = ff3Stream.getUnfilteredStream();
+                try
+                {
+                    byte[] buf = new byte[512];
+                    while(true)
+                    {
+                        int count = is.read(buf);
+                        if( count < 0 )
+                        {
+                            break;
+                        }
+                        os.write(buf, 0, count);
+                    }
+                }
+                finally
+                {
+                    is.close();
+                }
+
+                return os.toByteArray();
+            }
+        }
+
+        throw new IOException();
+    }
+
+    private Map loadOverride() throws IOException
+    {
+        Map result = new LinkedHashMap();
+
+        COSBase encoding = super.font.getDictionaryObject(COSName.ENCODING);
+        if( encoding instanceof COSName )
+        {
+            COSName name = (COSName)encoding;
+
+            result.putAll(loadEncoding(name));
+        }
+        else if( encoding instanceof COSDictionary )
+        {
+            COSDictionary encodingDic = (COSDictionary)encoding;
+
+            COSName baseName = (COSName)encodingDic.getDictionaryObject(COSName.BASE_ENCODING);
+            if( baseName != null )
+            {
+                result.putAll(loadEncoding(baseName));
+            }
+
+            COSArray differences = (COSArray)encodingDic.getDictionaryObject(COSName.DIFFERENCES);
+            if( differences != null )
+            {
+                result.putAll(loadDifferences(differences));
+            }
+        }
+
+        return result;
+    }
+
+    private Map loadEncoding(COSName name) throws IOException
+    {
+        Map result = new LinkedHashMap();
+
+        EncodingManager encodingManager = new EncodingManager();
+
+        Encoding encoding = encodingManager.getEncoding(name);
+        for( Iterator it = (encoding.getCodeToNameMap().entrySet()).iterator(); it.hasNext(); ){
+            Map.Entry entry = (Map.Entry)it.next();
+
+            result.put(entry.getKey(), ((COSName)entry.getValue()).getName());
+        }
+
+        return result;
+    }
+
+    private Map loadDifferences(COSArray differences)
+    {
+        Map result = new LinkedHashMap();
+
+        Integer code = null;
+
+        for( int i = 0; i < differences.size(); i++)
+        {
+            COSBase element = differences.get(i);
+
+            if( element instanceof COSNumber )
+            {
+                COSNumber number = (COSNumber)element;
+
+                code = Integer.valueOf(number.intValue());
+            } else
+
+            if( element instanceof COSName )
+            {
+                COSName name = (COSName)element;
+                result.put(code, name.getName());
+
+                code = Integer.valueOf(code.intValue() + 1);
+            }
+        }
+
+        return result;
+    }
+
+    static
+    private String hexString( int code, int length )
+    {
+        String string = Integer.toHexString(code);
+        while(string.length() < length){
+            string = ("0" + string);
+        }
+
+        return string;
+    }
+
+    static
+    private FontMetric prepareFontMetric( CFFFont font ) throws IOException
+    {
+        byte[] afmBytes = AFMFormatter.format(font);
+
+        InputStream is = new ByteArrayInputStream(afmBytes);
+        try
+        {
+            AFMParser afmParser = new AFMParser(is);
+            afmParser.parse();
+
+           return afmParser.getResult();
+        }
+        finally
+        {
+            is.close();
+        }
+    }
+
+    static
+    private Font prepareAwtFont( CFFFont font ) throws IOException
+    {
+        byte[] type1Bytes = Type1FontFormatter.format(font);
+
+        InputStream is = new ByteArrayInputStream(type1Bytes);
+        try
+        {
+            return Font.createFont(Font.TYPE1_FONT, is);
+        }
+        catch( FontFormatException ffe )
+        {
+            throw new IOException(ffe);
+        }
+        finally
+        {
+            is.close();
+        }
+    }
+
+    static
+    private class PDFEncoding extends CFFEncoding
+    {
+        private CFFEncoding parent = null;
+
+
+        private PDFEncoding( CFFEncoding parent )
+        {
+            this.parent = parent;
+        }
+
+        public boolean isFontSpecific()
+        {
+            return true;
+        }
+
+        protected void register( int code, int sid )
+        {
+            super.register(code, sid);
+        }
+    }
+
+    static
+    private class PDFCharset extends CFFCharset
+    {
+        private CFFCharset parent = null;
+
+
+        private PDFCharset( CFFCharset parent )
+        {
+            this.parent = parent;
+        }
+
+        public boolean isFontSpecific()
+        {
+            return true;
+        }
+
+        protected void register( int sid, String name )
+        {
+            super.register(sid, name);
+        }
+    }
+
+    private static final Log log = LogFactory.getLog(PDType1CFont.class);
+
+    private static final byte[] SPACE_BYTES = {(byte)32};
+}
\ No newline at end of file
Index: src/main/java/org/apache/pdfbox/pdmodel/font/PDFontFactory.java
===================================================================
--- src/main/java/org/apache/pdfbox/pdmodel/font/PDFontFactory.java	(revision 826050)
+++ src/main/java/org/apache/pdfbox/pdmodel/font/PDFontFactory.java	(working copy)
@@ -21,6 +21,7 @@
 
 import org.apache.pdfbox.cos.COSDictionary;
 import org.apache.pdfbox.cos.COSName;
+import org.apache.pdfbox.cos.COSStream;
 
 /**
  * This will create the correct type of font based on information in the dictionary.
@@ -99,6 +100,22 @@
         if( subType.equals( COSName.TYPE1) )
         {
             retval = new PDType1Font( dic );
+
+            COSDictionary fontDic = (COSDictionary)dic.getDictionaryObject(COSName.FONT_DESC);
+            if( fontDic != null )
+            {
+                COSStream ffStream = (COSStream)fontDic.getDictionaryObject("FontFile");
+                COSStream ff3Stream = (COSStream)fontDic.getDictionaryObject("FontFile3");
+
+                if( ffStream == null && ff3Stream != null )
+                {
+                    String ff3SubType = ff3Stream.getNameAsString(COSName.SUBTYPE);
+                    if( ff3SubType.equals("Type1C") )
+                    {
+                        retval = new PDType1CFont( dic );
+                    }
+                }
+            }
         }
         else if( subType.equals( COSName.MM_TYPE1 ) )
         {
Index: pom.xml
===================================================================
--- pom.xml	(revision 826050)
+++ pom.xml	(working copy)
@@ -47,7 +47,7 @@
     <dependency>
         <groupId>org.apache.pdfbox</groupId>
         <artifactId>fontbox</artifactId>
-        <version>0.8.0-incubator</version>
+        <version>1.0-SNAPSHOT</version>
     </dependency>
 
     <dependency>
Index: build.xml
===================================================================
--- build.xml	(revision 826050)
+++ build.xml	(working copy)
@@ -48,8 +48,8 @@
     <property name="ant.url" value="${maven.repo1}/org/apache/ant/ant/1.7.1/${ant.name}.jar" />
     <property name="ant.jar" value="${jar.dir}/ant.jar" />
 
-    <property name="fontbox.name" value="fontbox-0.8.0-incubating" />
-    <property name="fontbox.url" value="${maven.repo1}/org/apache/pdfbox/fontbox/0.8.0-incubator/${fontbox.name}.jar" />
+    <property name="fontbox.name" value="fontbox-1.0-SNAPSHOT" />
+    <property name="fontbox.url" value="${maven.repo1}/org/apache/pdfbox/fontbox/1.0-SNAPSHOT/${fontbox.name}.jar" />
     <property name="fontbox.jar" value="${jar.dir}/${fontbox.name}.jar" />
 
     <property name="jempbox.name" value="jempbox-0.8.0-incubating" />
