summaryrefslogtreecommitdiff
path: root/core/fxge/ge
diff options
context:
space:
mode:
Diffstat (limited to 'core/fxge/ge')
-rw-r--r--core/fxge/ge/fx_ge_font.cpp3
-rw-r--r--core/fxge/ge/fx_ge_fontmap.cpp4
2 files changed, 4 insertions, 3 deletions
diff --git a/core/fxge/ge/fx_ge_font.cpp b/core/fxge/ge/fx_ge_font.cpp
index 04019a059c..fab5ea28a9 100644
--- a/core/fxge/ge/fx_ge_font.cpp
+++ b/core/fxge/ge/fx_ge_font.cpp
@@ -4,6 +4,7 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
+#include "core/fpdfapi/fpdf_font/include/cpdf_font.h"
#include "core/fxge/ge/fx_text_int.h"
#include "core/include/fxge/fx_freetype.h"
#include "core/include/fxge/fx_ge.h"
@@ -516,7 +517,7 @@ uint32_t CFX_UnicodeEncodingEx::CharCodeFromUnicode(FX_WCHAR Unicode) const {
return Unicode;
}
}
- return static_cast<uint32_t>(-1);
+ return CPDF_Font::kInvalidCharCode;
}
CFX_UnicodeEncodingEx* FX_CreateFontEncodingEx(CFX_Font* pFont,
diff --git a/core/fxge/ge/fx_ge_fontmap.cpp b/core/fxge/ge/fx_ge_fontmap.cpp
index 709ef0031b..c6a6c5c003 100644
--- a/core/fxge/ge/fx_ge_fontmap.cpp
+++ b/core/fxge/ge/fx_ge_fontmap.cpp
@@ -1329,12 +1329,12 @@ int CFX_FontMapper::GetFaceSize() const {
}
FX_BOOL CFX_FontMapper::IsBuiltinFace(const FXFT_Face face) const {
- for (int i = 0; i < MM_FACE_COUNT; ++i) {
+ for (size_t i = 0; i < MM_FACE_COUNT; ++i) {
if (m_MMFaces[i] == face) {
return TRUE;
}
}
- for (int i = 0; i < FOXIT_FACE_COUNT; ++i) {
+ for (size_t i = 0; i < FOXIT_FACE_COUNT; ++i) {
if (m_FoxitFaces[i] == face) {
return TRUE;
}