Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(211)

Side by Side Diff: core/src/fpdfapi/fpdf_font/ttgsubtable.h

Issue 1252613002: FX_BOOL considered harmful. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Manual edits. Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef CORE_SRC_FPDFAPI_FPDF_FONT_TTGSUBTABLE_H_ 7 #ifndef CORE_SRC_FPDFAPI_FPDF_FONT_TTGSUBTABLE_H_
8 #define CORE_SRC_FPDFAPI_FPDF_FONT_TTGSUBTABLE_H_ 8 #define CORE_SRC_FPDFAPI_FPDF_FONT_TTGSUBTABLE_H_
9 9
10 #include "../../../include/fxge/fx_freetype.h" 10 #include "../../../include/fxge/fx_freetype.h"
11 #include "../../../include/fxcrt/fx_basic.h" 11 #include "../../../include/fxcrt/fx_basic.h"
12 #include "common.h" 12 #include "common.h"
13 13
14 class CFX_GlyphMap 14 class CFX_GlyphMap
15 { 15 {
16 public: 16 public:
17 CFX_GlyphMap(); 17 CFX_GlyphMap();
18 ~CFX_GlyphMap(); 18 ~CFX_GlyphMap();
19 void SetAt(int key, int value); 19 void SetAt(int key, int value);
20 FX_BOOL» Lookup(int key, int &value); 20 bool» Lookup(int key, int &value);
21 protected: 21 protected:
22 CFX_BinaryBuf m_Buffer; 22 CFX_BinaryBuf m_Buffer;
23 }; 23 };
24 class CFX_CTTGSUBTable 24 class CFX_CTTGSUBTable
25 { 25 {
26 public: 26 public:
27 CFX_CTTGSUBTable(void): m_bFeautureMapLoad(FALSE), loaded(false) {}; 27 CFX_CTTGSUBTable(void): m_bFeautureMapLoad(false), loaded(false) {};
28 CFX_CTTGSUBTable(FT_Bytes gsub): m_bFeautureMapLoad(FALSE), loaded(false) 28 CFX_CTTGSUBTable(FT_Bytes gsub): m_bFeautureMapLoad(false), loaded(false)
29 { 29 {
30 LoadGSUBTable(gsub); 30 LoadGSUBTable(gsub);
31 } 31 }
32 virtual ~CFX_CTTGSUBTable() {} 32 virtual ~CFX_CTTGSUBTable() {}
33 bool IsOk(void) const 33 bool IsOk(void) const
34 { 34 {
35 return loaded; 35 return loaded;
36 } 36 }
37 bool LoadGSUBTable(FT_Bytes gsub); 37 bool LoadGSUBTable(FT_Bytes gsub);
38 bool GetVerticalGlyph(TT_uint32_t glyphnum, TT_uint32_t *vglyphnum); 38 bool GetVerticalGlyph(TT_uint32_t glyphnum, TT_uint32_t *vglyphnum);
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 p += 4; 388 p += 4;
389 return *(TT_int32_t*)&ret; 389 return *(TT_int32_t*)&ret;
390 } 390 }
391 TT_uint32_t GetUInt32(FT_Bytes& p) const 391 TT_uint32_t GetUInt32(FT_Bytes& p) const
392 { 392 {
393 TT_uint32_t ret = p[0] << 24 | p[1] << 16 | p[2] << 8 | p[3]; 393 TT_uint32_t ret = p[0] << 24 | p[1] << 16 | p[2] << 8 | p[3];
394 p += 4; 394 p += 4;
395 return ret; 395 return ret;
396 } 396 }
397 CFX_CMapDWordToDWord m_featureMap; 397 CFX_CMapDWordToDWord m_featureMap;
398 FX_BOOL» m_bFeautureMapLoad; 398 bool» m_bFeautureMapLoad;
399 bool loaded; 399 bool loaded;
400 struct tt_gsub_header header; 400 struct tt_gsub_header header;
401 struct TScriptList ScriptList; 401 struct TScriptList ScriptList;
402 struct TFeatureList FeatureList; 402 struct TFeatureList FeatureList;
403 struct TLookupList LookupList; 403 struct TLookupList LookupList;
404 }; 404 };
405 class CFX_GSUBTable final : public IFX_GSUBTable 405 class CFX_GSUBTable final : public IFX_GSUBTable
406 { 406 {
407 public: 407 public:
408 ~CFX_GSUBTable() override {} 408 ~CFX_GSUBTable() override {}
409 virtual FX_BOOL GetVerticalGlyph(FX_DWORD glyphnum, FX_DWORD* vglyphnum) ove rride; 409 virtual bool GetVerticalGlyph(FX_DWORD glyphnum, FX_DWORD* vglyphnum) overri de;
410 410
411 CFX_CTTGSUBTable m_GsubImp; 411 CFX_CTTGSUBTable m_GsubImp;
412 }; 412 };
413 413
414 #endif // CORE_SRC_FPDFAPI_FPDF_FONT_TTGSUBTABLE_H_ 414 #endif // CORE_SRC_FPDFAPI_FPDF_FONT_TTGSUBTABLE_H_
OLDNEW
« no previous file with comments | « core/src/fpdfapi/fpdf_font/fpdf_font_cid.cpp ('k') | core/src/fpdfapi/fpdf_font/ttgsubtable.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698