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

Side by Side Diff: core/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp

Issue 1885093002: Re-enable warning 4701 for GN build and some cleanup (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « BUILD.gn ('k') | core/fpdfapi/fpdf_render/fpdf_render_pattern.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include <limits.h> 7 #include <limits.h>
8 8
9 #include "core/fpdfapi/fpdf_font/include/cpdf_font.h" 9 #include "core/fpdfapi/fpdf_font/include/cpdf_font.h"
10 #include "core/fpdfapi/fpdf_font/include/cpdf_fontencoding.h" 10 #include "core/fpdfapi/fpdf_font/include/cpdf_fontencoding.h"
(...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after
347 CPDF_Array* pWidths = new CPDF_Array; 347 CPDF_Array* pWidths = new CPDF_Array;
348 for (int i = 0; i < 224; i++) { 348 for (int i = 0; i < 224; i++) {
349 pWidths->AddInteger(char_widths[i]); 349 pWidths->AddInteger(char_widths[i]);
350 } 350 }
351 pBaseDict->SetAt("Widths", pWidths); 351 pBaseDict->SetAt("Widths", pWidths);
352 } else { 352 } else {
353 flags |= PDFFONT_NONSYMBOLIC; 353 flags |= PDFFONT_NONSYMBOLIC;
354 pFontDict = new CPDF_Dictionary; 354 pFontDict = new CPDF_Dictionary;
355 CFX_ByteString cmap; 355 CFX_ByteString cmap;
356 CFX_ByteString ordering; 356 CFX_ByteString ordering;
357 int supplement; 357 int supplement = 0;
358 CPDF_Array* pWidthArray = new CPDF_Array; 358 CPDF_Array* pWidthArray = new CPDF_Array;
359 switch (pLogFont->lfCharSet) { 359 switch (pLogFont->lfCharSet) {
360 case CHINESEBIG5_CHARSET: 360 case CHINESEBIG5_CHARSET:
361 cmap = bVert ? "ETenms-B5-V" : "ETenms-B5-H"; 361 cmap = bVert ? "ETenms-B5-V" : "ETenms-B5-H";
362 ordering = "CNS1"; 362 ordering = "CNS1";
363 supplement = 4; 363 supplement = 4;
364 pWidthArray->AddInteger(1); 364 pWidthArray->AddInteger(1);
365 _InsertWidthArray(hDC, 0x20, 0x7e, pWidthArray); 365 _InsertWidthArray(hDC, 0x20, 0x7e, pWidthArray);
366 break; 366 break;
367 case GB2312_CHARSET: 367 case GB2312_CHARSET:
(...skipping 782 matching lines...) Expand 10 before | Expand all | Expand 10 after
1150 void FPDFAPI_FlatPageAttr(CPDF_Dictionary* pPageDict, 1150 void FPDFAPI_FlatPageAttr(CPDF_Dictionary* pPageDict,
1151 const CFX_ByteStringC& name) { 1151 const CFX_ByteStringC& name) {
1152 if (pPageDict->KeyExist(name)) { 1152 if (pPageDict->KeyExist(name)) {
1153 return; 1153 return;
1154 } 1154 }
1155 CPDF_Object* pObj = FPDFAPI_GetPageAttr(pPageDict, name); 1155 CPDF_Object* pObj = FPDFAPI_GetPageAttr(pPageDict, name);
1156 if (pObj) { 1156 if (pObj) {
1157 pPageDict->SetAt(name, pObj->Clone()); 1157 pPageDict->SetAt(name, pObj->Clone());
1158 } 1158 }
1159 } 1159 }
OLDNEW
« no previous file with comments | « BUILD.gn ('k') | core/fpdfapi/fpdf_render/fpdf_render_pattern.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698