| 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 "xfa/fxfa/app/xfa_textlayout.h" | 7 #include "xfa/fxfa/app/xfa_textlayout.h" |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 } | 30 } |
| 31 void CXFA_CSSTagProvider::GetNextAttribute(FX_POSITION& pos, | 31 void CXFA_CSSTagProvider::GetNextAttribute(FX_POSITION& pos, |
| 32 CFX_WideStringC& wsAttr, | 32 CFX_WideStringC& wsAttr, |
| 33 CFX_WideStringC& wsValue) { | 33 CFX_WideStringC& wsValue) { |
| 34 if (pos == NULL) { | 34 if (pos == NULL) { |
| 35 return; | 35 return; |
| 36 } | 36 } |
| 37 CFX_WideString* pName = NULL; | 37 CFX_WideString* pName = NULL; |
| 38 CFX_WideString* pValue = NULL; | 38 CFX_WideString* pValue = NULL; |
| 39 m_Attributes.GetNextAssoc(pos, (void*&)pName, (void*&)pValue); | 39 m_Attributes.GetNextAssoc(pos, (void*&)pName, (void*&)pValue); |
| 40 wsAttr = *pName; | 40 wsAttr = pName->AsStringC(); |
| 41 wsValue = *pValue; | 41 wsValue = pValue->AsStringC(); |
| 42 } | 42 } |
| 43 void CXFA_CSSTagProvider::SetAttribute(const CFX_WideString& wsAttr, | 43 void CXFA_CSSTagProvider::SetAttribute(const CFX_WideString& wsAttr, |
| 44 const CFX_WideString& wsValue) { | 44 const CFX_WideString& wsValue) { |
| 45 CFX_WideString* pName = new CFX_WideString(); | 45 CFX_WideString* pName = new CFX_WideString(); |
| 46 CFX_WideString* pValue = new CFX_WideString(); | 46 CFX_WideString* pValue = new CFX_WideString(); |
| 47 *pName = wsAttr; | 47 *pName = wsAttr; |
| 48 *pValue = wsValue; | 48 *pValue = wsValue; |
| 49 m_Attributes.SetAt(pName, pValue); | 49 m_Attributes.SetAt(pName, pValue); |
| 50 } | 50 } |
| 51 void CXFA_TextParseContext::SetDecls(const IFDE_CSSDeclaration** ppDeclArray, | 51 void CXFA_TextParseContext::SetDecls(const IFDE_CSSDeclaration** ppDeclArray, |
| (...skipping 1938 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1990 tr.iLength = iLength; | 1990 tr.iLength = iLength; |
| 1991 tr.fFontSize = pPiece->fFontSize; | 1991 tr.fFontSize = pPiece->fFontSize; |
| 1992 tr.iBidiLevel = pPiece->iBidiLevel; | 1992 tr.iBidiLevel = pPiece->iBidiLevel; |
| 1993 tr.iCharRotation = 0; | 1993 tr.iCharRotation = 0; |
| 1994 tr.wLineBreakChar = L'\n'; | 1994 tr.wLineBreakChar = L'\n'; |
| 1995 tr.iVerticalScale = pPiece->iVerScale; | 1995 tr.iVerticalScale = pPiece->iVerScale; |
| 1996 tr.dwLayoutStyles = FX_RTFLAYOUTSTYLE_ExpandTab; | 1996 tr.dwLayoutStyles = FX_RTFLAYOUTSTYLE_ExpandTab; |
| 1997 tr.iHorizontalScale = pPiece->iHorScale; | 1997 tr.iHorizontalScale = pPiece->iHorScale; |
| 1998 return TRUE; | 1998 return TRUE; |
| 1999 } | 1999 } |
| OLD | NEW |