-
Notifications
You must be signed in to change notification settings - Fork 247
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix ByteEncodingCMapTable.CharacterCodeToGlyphIndex() to account for …
…glyph mapping length, add test and fix #881
- Loading branch information
Showing
3 changed files
with
25 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
namespace UglyToad.PdfPig.Tests.Integration | ||
{ | ||
using System.Linq; | ||
|
||
public class TrueTypeTests | ||
{ | ||
[Fact] | ||
public void Issue881() | ||
{ | ||
var file = IntegrationHelpers.GetDocumentPath("issue_881.pdf"); | ||
|
||
using (var document = PdfDocument.Open(file)) | ||
{ | ||
var page = document.GetPage(1); | ||
var words = page.GetWords().ToArray(); | ||
Assert.Equal(4, words.Length); | ||
Assert.Equal("IDNR:", words[0].Text); | ||
Assert.Equal("4174", words[1].Text); | ||
Assert.Equal("/", words[2].Text); | ||
Assert.Equal("06.08.2018", words[3].Text); | ||
} | ||
} | ||
} | ||
} |