larrylynn-wf commented on a change in pull request #117:
URL: https://github.com/apache/pdfbox/pull/117#discussion_r631348656



##########
File path: 
pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/TrueTypeEmbedder.java
##########
@@ -136,13 +136,20 @@ public final void buildFontFile2(InputStream ttfStream) 
throws IOException
     /**
      * Returns true if the fsType in the OS/2 table permits embedding.
      */
-    private boolean isEmbeddingPermitted(TrueTypeFont ttf) throws IOException
+    protected boolean isEmbeddingPermitted(TrueTypeFont ttf) throws IOException
     {
         if (ttf.getOS2Windows() != null)
         {
             int fsType = ttf.getOS2Windows().getFsType();
-            if ((fsType & OS2WindowsMetricsTable.FSTYPE_RESTRICTED) ==
-                             OS2WindowsMetricsTable.FSTYPE_RESTRICTED)
+            int maskedFsType = fsType & 0x000F;

Review comment:
       For this PR, I branched off of the trunk.  I believe this is essentially 
the version 3.0.x pre-release codebase.  However, this method is identical in 
trunk and the current stable release version, 2.0.23.  So, I think this patch 
will work for both the 2.0.x codebase and the 3.0.x codebase.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to