| OLD | NEW |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #include "../../../include/fpdfapi/fpdf_page.h" | 7 #include "../../../include/fpdfapi/fpdf_page.h" |
| 8 #include "../../../include/fxge/fx_freetype.h" | 8 #include "../../../include/fxge/fx_freetype.h" |
| 9 extern FX_WCHAR PDF_UnicodeFromAdobeName(const FX_CHAR*); | 9 extern FX_WCHAR PDF_UnicodeFromAdobeName(const FX_CHAR*); |
| 10 const struct _UnicodeAlt { | 10 const struct _UnicodeAlt { |
| (...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 603 return NULL; | 603 return NULL; |
| 604 } | 604 } |
| 605 FX_DWORD PDF_PredefinedCharCodeFromUnicode(int encoding, FX_WCHAR unicode) | 605 FX_DWORD PDF_PredefinedCharCodeFromUnicode(int encoding, FX_WCHAR unicode) |
| 606 { | 606 { |
| 607 return PDF_FindCode(PDF_UnicodesForPredefinedCharSet(encoding), unicode); | 607 return PDF_FindCode(PDF_UnicodesForPredefinedCharSet(encoding), unicode); |
| 608 } | 608 } |
| 609 #ifdef __cplusplus | 609 #ifdef __cplusplus |
| 610 extern "C" { | 610 extern "C" { |
| 611 #endif | 611 #endif |
| 612 extern int FXFT_unicode_from_adobe_name(const char* name); | 612 extern int FXFT_unicode_from_adobe_name(const char* name); |
| 613 extern void FXFT_adobe_name_from_unicode(char* glyph_name, FX_WCHAR unicode); |
| 613 #ifdef __cplusplus | 614 #ifdef __cplusplus |
| 614 } | 615 } |
| 615 #endif | 616 #endif |
| 616 FX_WCHAR PDF_UnicodeFromAdobeName(const FX_CHAR* name) | 617 FX_WCHAR PDF_UnicodeFromAdobeName(const FX_CHAR* name) |
| 617 { | 618 { |
| 618 return (FX_WCHAR)(FXFT_unicode_from_adobe_name(name) & 0x7FFFFFFF); | 619 return (FX_WCHAR)(FXFT_unicode_from_adobe_name(name) & 0x7FFFFFFF); |
| 619 } | 620 } |
| 620 CFX_ByteString PDF_AdobeNameFromUnicode(FX_WCHAR unicode) | 621 CFX_ByteString PDF_AdobeNameFromUnicode(FX_WCHAR unicode) |
| 621 { | 622 { |
| 622 char glyph_name[64]; | 623 char glyph_name[64]; |
| 623 FXFT_adobe_name_from_unicode(glyph_name, unicode); | 624 FXFT_adobe_name_from_unicode(glyph_name, unicode); |
| 624 return CFX_ByteString(glyph_name, -1); | 625 return CFX_ByteString(glyph_name, -1); |
| 625 } | 626 } |
| OLD | NEW |