| 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 "core/include/fpdfapi/cpdf_document.h" | 7 #include "core/include/fpdfapi/cpdf_document.h" |
| 8 #include "core/include/fpdfapi/cpdf_simple_parser.h" |
| 8 #include "core/include/fpdfdoc/fpdf_doc.h" | 9 #include "core/include/fpdfdoc/fpdf_doc.h" |
| 9 #include "core/src/fpdfdoc/doc_utils.h" | 10 #include "core/src/fpdfdoc/doc_utils.h" |
| 10 | 11 |
| 11 FX_BOOL PDF_FormField_IsUnison(CPDF_FormField* pField) { | 12 FX_BOOL PDF_FormField_IsUnison(CPDF_FormField* pField) { |
| 12 FX_BOOL bUnison = FALSE; | 13 FX_BOOL bUnison = FALSE; |
| 13 if (pField->GetType() == CPDF_FormField::CheckBox) { | 14 if (pField->GetType() == CPDF_FormField::CheckBox) { |
| 14 bUnison = TRUE; | 15 bUnison = TRUE; |
| 15 } else { | 16 } else { |
| 16 FX_DWORD dwFlags = pField->GetFieldFlags(); | 17 FX_DWORD dwFlags = pField->GetFieldFlags(); |
| 17 bUnison = ((dwFlags & 0x2000000) != 0); | 18 bUnison = ((dwFlags & 0x2000000) != 0); |
| (...skipping 1065 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1083 pFontDict = m_pForm->m_pFormDict->GetDictBy("DR") | 1084 pFontDict = m_pForm->m_pFormDict->GetDictBy("DR") |
| 1084 ->GetDictBy("Font") | 1085 ->GetDictBy("Font") |
| 1085 ->GetDictBy(font_name); | 1086 ->GetDictBy(font_name); |
| 1086 | 1087 |
| 1087 if (!pFontDict) { | 1088 if (!pFontDict) { |
| 1088 return; | 1089 return; |
| 1089 } | 1090 } |
| 1090 m_pFont = m_pForm->m_pDocument->LoadFont(pFontDict); | 1091 m_pFont = m_pForm->m_pDocument->LoadFont(pFontDict); |
| 1091 m_FontSize = FX_atof(syntax.GetWord()); | 1092 m_FontSize = FX_atof(syntax.GetWord()); |
| 1092 } | 1093 } |
| OLD | NEW |