| 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 "../../../../third_party/base/nonstd_unique_ptr.h" | 7 #include "../../../include/fxge/fx_freetype.h" |
| 8 #include "../../../include/fxge/fx_ge.h" | 8 #include "../../../include/fxge/fx_ge.h" |
| 9 #include "../../../include/fxge/fx_freetype.h" | 9 #include "third_party/base/nonstd_unique_ptr.h" |
| 10 #include "ttgsubtable.h" | 10 #include "ttgsubtable.h" |
| 11 | 11 |
| 12 CFX_GlyphMap::CFX_GlyphMap() {} | 12 CFX_GlyphMap::CFX_GlyphMap() {} |
| 13 CFX_GlyphMap::~CFX_GlyphMap() {} | 13 CFX_GlyphMap::~CFX_GlyphMap() {} |
| 14 extern "C" { | 14 extern "C" { |
| 15 static int _CompareInt(const void* p1, const void* p2) { | 15 static int _CompareInt(const void* p1, const void* p2) { |
| 16 return (*(FX_DWORD*)p1) - (*(FX_DWORD*)p2); | 16 return (*(FX_DWORD*)p1) - (*(FX_DWORD*)p2); |
| 17 } | 17 } |
| 18 }; | 18 }; |
| 19 struct _IntPair { | 19 struct _IntPair { |
| (...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 403 FXFT_Load_Sfnt_Table(pFont->GetFace(), FT_MAKE_TAG('G', 'S', 'U', 'B'), 0, | 403 FXFT_Load_Sfnt_Table(pFont->GetFace(), FT_MAKE_TAG('G', 'S', 'U', 'B'), 0, |
| 404 pFont->GetSubData(), NULL); | 404 pFont->GetSubData(), NULL); |
| 405 if (!error && pFont->GetSubData()) { | 405 if (!error && pFont->GetSubData()) { |
| 406 nonstd::unique_ptr<CFX_GSUBTable> pGsubTable(new CFX_GSUBTable); | 406 nonstd::unique_ptr<CFX_GSUBTable> pGsubTable(new CFX_GSUBTable); |
| 407 if (pGsubTable->m_GsubImp.LoadGSUBTable((FT_Bytes)pFont->GetSubData())) { | 407 if (pGsubTable->m_GsubImp.LoadGSUBTable((FT_Bytes)pFont->GetSubData())) { |
| 408 return pGsubTable.release(); | 408 return pGsubTable.release(); |
| 409 } | 409 } |
| 410 } | 410 } |
| 411 return NULL; | 411 return NULL; |
| 412 } | 412 } |
| OLD | NEW |