public virtual void AppendGlyphsWithSpecificEncodingTest() { PdfSimpleFont <FontProgram> fontToTest = new PdfSimpleFontTest.TestSimpleFont(FontEncoding.CreateFontSpecificEncoding ()); IList <Glyph> toAppend = new List <Glyph>(); int processed = fontToTest.AppendGlyphs("te", 0, 1, toAppend); NUnit.Framework.Assert.AreEqual(2, processed); IList <Glyph> glyphs = new List <Glyph>(); glyphs.Add(T_GLYPH_FONT_SPECIFIC); glyphs.Add(E_GLYPH_FONT_SPECIFIC); NUnit.Framework.Assert.AreEqual(glyphs, toAppend); }
public virtual void AppendGlyphsWithEmptyEncodingTest() { PdfSimpleFont <FontProgram> fontToTest = new PdfSimpleFontTest.TestSimpleFont(FontEncoding.CreateEmptyFontEncoding ()); IList <Glyph> toAppend = new List <Glyph>(); int processed = fontToTest.AppendGlyphs("e ete", 0, 4, toAppend); NUnit.Framework.Assert.AreEqual(3, processed); IList <Glyph> glyphs = new List <Glyph>(); glyphs.Add(E_GLYPH_CUSTOM_MAPPED); glyphs.Add(E_GLYPH_CUSTOM_MAPPED); NUnit.Framework.Assert.AreEqual(glyphs, toAppend); }