diff options
Diffstat (limited to 'core/fpdfapi/font')
-rw-r--r-- | core/fpdfapi/font/cpdf_cidfont.cpp | 2 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_cidfont.h | 2 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_type3font.cpp | 8 |
3 files changed, 6 insertions, 6 deletions
diff --git a/core/fpdfapi/font/cpdf_cidfont.cpp b/core/fpdfapi/font/cpdf_cidfont.cpp index 6e050c4bc7..7d14a9ea0a 100644 --- a/core/fpdfapi/font/cpdf_cidfont.cpp +++ b/core/fpdfapi/font/cpdf_cidfont.cpp @@ -823,7 +823,7 @@ void CPDF_CIDFont::LoadMetricsArray(CPDF_Array* pArray, } // static -FX_FLOAT CPDF_CIDFont::CIDTransformToFloat(uint8_t ch) { +float CPDF_CIDFont::CIDTransformToFloat(uint8_t ch) { return (ch < 128 ? ch : ch - 255) * (1.0f / 127); } diff --git a/core/fpdfapi/font/cpdf_cidfont.h b/core/fpdfapi/font/cpdf_cidfont.h index e256be1af5..ec7da6a9bf 100644 --- a/core/fpdfapi/font/cpdf_cidfont.h +++ b/core/fpdfapi/font/cpdf_cidfont.h @@ -36,7 +36,7 @@ class CPDF_CIDFont : public CPDF_Font { CPDF_CIDFont(); ~CPDF_CIDFont() override; - static FX_FLOAT CIDTransformToFloat(uint8_t ch); + static float CIDTransformToFloat(uint8_t ch); // CPDF_Font: bool IsCIDFont() const override; diff --git a/core/fpdfapi/font/cpdf_type3font.cpp b/core/fpdfapi/font/cpdf_type3font.cpp index b7ff8c9cf0..10a116ab46 100644 --- a/core/fpdfapi/font/cpdf_type3font.cpp +++ b/core/fpdfapi/font/cpdf_type3font.cpp @@ -44,7 +44,7 @@ CPDF_Type3Font* CPDF_Type3Font::AsType3Font() { bool CPDF_Type3Font::Load() { m_pFontResources = m_pFontDict->GetDictFor("Resources"); CPDF_Array* pMatrix = m_pFontDict->GetArrayFor("FontMatrix"); - FX_FLOAT xscale = 1.0f, yscale = 1.0f; + float xscale = 1.0f, yscale = 1.0f; if (pMatrix) { m_FontMatrix = pMatrix->GetMatrix(); xscale = m_FontMatrix.a; @@ -112,12 +112,12 @@ CPDF_Type3Char* CPDF_Type3Font::LoadChar(uint32_t charcode) { if (it != m_CacheMap.end()) return it->second.get(); - FX_FLOAT scale = m_FontMatrix.GetXUnit(); + float scale = m_FontMatrix.GetXUnit(); pNewChar->m_Width = (int32_t)(pNewChar->m_Width * scale + 0.5f); FX_RECT& rcBBox = pNewChar->m_BBox; CFX_FloatRect char_rect( - (FX_FLOAT)rcBBox.left / 1000.0f, (FX_FLOAT)rcBBox.bottom / 1000.0f, - (FX_FLOAT)rcBBox.right / 1000.0f, (FX_FLOAT)rcBBox.top / 1000.0f); + (float)rcBBox.left / 1000.0f, (float)rcBBox.bottom / 1000.0f, + (float)rcBBox.right / 1000.0f, (float)rcBBox.top / 1000.0f); if (rcBBox.right <= rcBBox.left || rcBBox.bottom >= rcBBox.top) char_rect = pNewChar->m_pForm->CalcBoundingBox(); |