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 <limits> | 7 #include <limits> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "core/fxcodec/include/fx_codec.h" | 10 #include "core/fxcodec/include/fx_codec.h" |
(...skipping 833 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
844 dest_width, anti_alias, pFont->GetSubstFont()->m_Weight, | 844 dest_width, anti_alias, pFont->GetSubstFont()->m_Weight, |
845 pFont->GetSubstFont()->m_ItalicAngle, pFont->IsVertical(), | 845 pFont->GetSubstFont()->m_ItalicAngle, pFont->IsVertical(), |
846 3); | 846 3); |
847 else | 847 else |
848 keygen.Generate(7, (int)(pMatrix->a * 10000), (int)(pMatrix->b * 10000), | 848 keygen.Generate(7, (int)(pMatrix->a * 10000), (int)(pMatrix->b * 10000), |
849 (int)(pMatrix->c * 10000), (int)(pMatrix->d * 10000), | 849 (int)(pMatrix->c * 10000), (int)(pMatrix->d * 10000), |
850 dest_width, anti_alias, 3); | 850 dest_width, anti_alias, 3); |
851 } | 851 } |
852 #endif | 852 #endif |
853 CFX_ByteString FaceGlyphsKey(keygen.m_Key, keygen.m_KeyLen); | 853 CFX_ByteString FaceGlyphsKey(keygen.m_Key, keygen.m_KeyLen); |
854 #if _FXM_PLATFORM_ != _FXM_PLATFORM_APPLE_ | 854 #if _FXM_PLATFORM_ != _FXM_PLATFORM_APPLE_ || defined _SKIA_SUPPORT_ |
855 return LookUpGlyphBitmap(pFont, pMatrix, FaceGlyphsKey, glyph_index, | 855 return LookUpGlyphBitmap(pFont, pMatrix, FaceGlyphsKey, glyph_index, |
856 bFontStyle, dest_width, anti_alias); | 856 bFontStyle, dest_width, anti_alias); |
857 #else | 857 #else |
858 if (text_flags & FXTEXT_NO_NATIVETEXT) { | 858 if (text_flags & FXTEXT_NO_NATIVETEXT) { |
859 return LookUpGlyphBitmap(pFont, pMatrix, FaceGlyphsKey, glyph_index, | 859 return LookUpGlyphBitmap(pFont, pMatrix, FaceGlyphsKey, glyph_index, |
860 bFontStyle, dest_width, anti_alias); | 860 bFontStyle, dest_width, anti_alias); |
861 } | 861 } |
862 CFX_GlyphBitmap* pGlyphBitmap; | 862 CFX_GlyphBitmap* pGlyphBitmap; |
863 auto it = m_SizeMap.find(FaceGlyphsKey); | 863 auto it = m_SizeMap.find(FaceGlyphsKey); |
864 if (it != m_SizeMap.end()) { | 864 if (it != m_SizeMap.end()) { |
(...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1402 void _CFX_UniqueKeyGen::Generate(int count, ...) { | 1402 void _CFX_UniqueKeyGen::Generate(int count, ...) { |
1403 va_list argList; | 1403 va_list argList; |
1404 va_start(argList, count); | 1404 va_start(argList, count); |
1405 for (int i = 0; i < count; i++) { | 1405 for (int i = 0; i < count; i++) { |
1406 int p = va_arg(argList, int); | 1406 int p = va_arg(argList, int); |
1407 ((uint32_t*)m_Key)[i] = p; | 1407 ((uint32_t*)m_Key)[i] = p; |
1408 } | 1408 } |
1409 va_end(argList); | 1409 va_end(argList); |
1410 m_KeyLen = count * sizeof(uint32_t); | 1410 m_KeyLen = count * sizeof(uint32_t); |
1411 } | 1411 } |
OLD | NEW |