| 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/fpdfdoc/fpdf_doc.h" | 7 #include "core/include/fpdfdoc/fpdf_doc.h" |
| 8 #include "doc_utils.h" | 8 #include "doc_utils.h" |
| 9 | 9 |
| 10 static const int FPDFDOC_UTILS_MAXRECURSION = 32; | 10 static const int FPDFDOC_UTILS_MAXRECURSION = 32; |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 CPDF_SimpleParser syntax(m_csDA); | 201 CPDF_SimpleParser syntax(m_csDA); |
| 202 if (syntax.FindTagParam("Tm", 6)) { | 202 if (syntax.FindTagParam("Tm", 6)) { |
| 203 for (int i = 0; i < 6; i++) { | 203 for (int i = 0; i < 6; i++) { |
| 204 csTM += (CFX_ByteString)syntax.GetWord(); | 204 csTM += (CFX_ByteString)syntax.GetWord(); |
| 205 csTM += " "; | 205 csTM += " "; |
| 206 } | 206 } |
| 207 csTM += (CFX_ByteString)syntax.GetWord(); | 207 csTM += (CFX_ByteString)syntax.GetWord(); |
| 208 } | 208 } |
| 209 return csTM; | 209 return csTM; |
| 210 } | 210 } |
| 211 CFX_AffineMatrix CPDF_DefaultAppearance::GetTextMatrix() { | 211 CFX_Matrix CPDF_DefaultAppearance::GetTextMatrix() { |
| 212 CFX_AffineMatrix tm; | 212 CFX_Matrix tm; |
| 213 if (m_csDA.IsEmpty()) { | 213 if (m_csDA.IsEmpty()) { |
| 214 return tm; | 214 return tm; |
| 215 } | 215 } |
| 216 CPDF_SimpleParser syntax(m_csDA); | 216 CPDF_SimpleParser syntax(m_csDA); |
| 217 if (syntax.FindTagParam("Tm", 6)) { | 217 if (syntax.FindTagParam("Tm", 6)) { |
| 218 FX_FLOAT f[6]; | 218 FX_FLOAT f[6]; |
| 219 for (int i = 0; i < 6; i++) { | 219 for (int i = 0; i < 6; i++) { |
| 220 f[i] = FX_atof((CFX_ByteString)syntax.GetWord()); | 220 f[i] = FX_atof((CFX_ByteString)syntax.GetWord()); |
| 221 } | 221 } |
| 222 tm.Set(f[0], f[1], f[2], f[3], f[4], f[5]); | 222 tm.Set(f[0], f[1], f[2], f[3], f[4], f[5]); |
| (...skipping 495 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 718 CPDF_Object* pAttr = pFieldDict->GetElementValue(name); | 718 CPDF_Object* pAttr = pFieldDict->GetElementValue(name); |
| 719 if (pAttr) { | 719 if (pAttr) { |
| 720 return pAttr; | 720 return pAttr; |
| 721 } | 721 } |
| 722 CPDF_Dictionary* pParent = pFieldDict->GetDict("Parent"); | 722 CPDF_Dictionary* pParent = pFieldDict->GetDict("Parent"); |
| 723 if (pParent == NULL) { | 723 if (pParent == NULL) { |
| 724 return NULL; | 724 return NULL; |
| 725 } | 725 } |
| 726 return FPDF_GetFieldAttr(pParent, name, nLevel + 1); | 726 return FPDF_GetFieldAttr(pParent, name, nLevel + 1); |
| 727 } | 727 } |
| OLD | NEW |