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

Side by Side Diff: fpdfsdk/src/pdfwindow/PWL_Utils.cpp

Issue 1752543002: Add CFX_FloatRect::ToFxRect(). (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 9 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 | « fpdfsdk/src/fxedit/fxet_pageobjs.cpp ('k') | no next file » | 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 "fpdfsdk/include/pdfwindow/PWL_Utils.h" 7 #include "fpdfsdk/include/pdfwindow/PWL_Utils.h"
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 1678 matching lines...) Expand 10 before | Expand all | Expand 10 after
1689 CPVT_WordPlace wpWordStart; 1689 CPVT_WordPlace wpWordStart;
1690 CFX_ByteString sLatinWord; 1690 CFX_ByteString sLatinWord;
1691 1691
1692 CFX_PathData pathSpell; 1692 CFX_PathData pathSpell;
1693 1693
1694 pDevice->SaveState(); 1694 pDevice->SaveState();
1695 1695
1696 if (!rcClip.IsEmpty()) { 1696 if (!rcClip.IsEmpty()) {
1697 CFX_FloatRect rcTemp = rcClip; 1697 CFX_FloatRect rcTemp = rcClip;
1698 pUser2Device->TransformRect(rcTemp); 1698 pUser2Device->TransformRect(rcTemp);
1699 pDevice->SetClip_Rect(FX_RECT((int32_t)rcTemp.left, (int32_t)rcTemp.top, 1699 pDevice->SetClip_Rect(rcTemp.ToFxRect());
1700 (int32_t)rcTemp.right,
1701 (int32_t)rcTemp.bottom));
1702 } 1700 }
1703 1701
1704 if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) { 1702 if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {
1705 if (pEdit->GetFontMap()) { 1703 if (pEdit->GetFontMap()) {
1706 if (pRange) 1704 if (pRange)
1707 pIterator->SetAt(pRange->BeginPos); 1705 pIterator->SetAt(pRange->BeginPos);
1708 else 1706 else
1709 pIterator->SetAt(0); 1707 pIterator->SetAt(0);
1710 1708
1711 CPVT_WordPlace oldplace; 1709 CPVT_WordPlace oldplace;
(...skipping 1962 matching lines...) Expand 10 before | Expand all | Expand 10 after
3674 break; 3672 break;
3675 case COLORTYPE_RGB: 3673 case COLORTYPE_RGB:
3676 CPWL_Utils::ConvertCMYK2RGB(fColor1, fColor2, fColor3, fColor4, 3674 CPWL_Utils::ConvertCMYK2RGB(fColor1, fColor2, fColor3, fColor4,
3677 fColor1, fColor2, fColor3); 3675 fColor1, fColor2, fColor3);
3678 break; 3676 break;
3679 } 3677 }
3680 break; 3678 break;
3681 } 3679 }
3682 nColorType = other_nColorType; 3680 nColorType = other_nColorType;
3683 } 3681 }
OLDNEW
« no previous file with comments | « fpdfsdk/src/fxedit/fxet_pageobjs.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698