summaryrefslogtreecommitdiff
path: root/xfa
diff options
context:
space:
mode:
Diffstat (limited to 'xfa')
-rw-r--r--xfa/src/fdp/src/fde/fde_gedevice.cpp34
-rw-r--r--xfa/src/fdp/src/fde/fde_gedevice.h2
-rw-r--r--xfa/src/fdp/src/fde/fde_geobject.cpp3
-rw-r--r--xfa/src/fdp/src/fde/fde_geobject.h3
4 files changed, 16 insertions, 26 deletions
diff --git a/xfa/src/fdp/src/fde/fde_gedevice.cpp b/xfa/src/fdp/src/fde/fde_gedevice.cpp
index fb124e3b4d..1abb656fea 100644
--- a/xfa/src/fdp/src/fde/fde_gedevice.cpp
+++ b/xfa/src/fdp/src/fde/fde_gedevice.cpp
@@ -10,23 +10,18 @@
#include "xfa/src/fdp/src/fde/fde_gedevice.h"
#include "xfa/src/fdp/src/fde/fde_geobject.h"
#include "xfa/src/foxitlib.h"
-#ifndef _FDEPLUS
-#ifdef _cplusplus
-exten "C" {
-#endif
- FX_BOOL FDE_GetStockHatchMask(int32_t iHatchStyle, CFX_DIBitmap & hatchMask) {
- FDE_LPCHATCHDATA pData = FDE_DEVGetHatchData(iHatchStyle);
- if (!pData) {
- return FALSE;
- }
- hatchMask.Create(pData->iWidth, pData->iHeight, FXDIB_1bppMask);
- FXSYS_memcpy(hatchMask.GetBuffer(), pData->MaskBits,
- hatchMask.GetPitch() * pData->iHeight);
- return TRUE;
+
+FX_BOOL FDE_GetStockHatchMask(int32_t iHatchStyle, CFX_DIBitmap& hatchMask) {
+ FDE_LPCHATCHDATA pData = FDE_DEVGetHatchData(iHatchStyle);
+ if (!pData) {
+ return FALSE;
}
-#ifdef _cplusplus
+ hatchMask.Create(pData->iWidth, pData->iHeight, FXDIB_1bppMask);
+ FXSYS_memcpy(hatchMask.GetBuffer(), pData->MaskBits,
+ hatchMask.GetPitch() * pData->iHeight);
+ return TRUE;
}
-#endif
+
IFDE_RenderDevice* IFDE_RenderDevice::Create(CFX_DIBitmap* pBitmap,
FX_BOOL bRgbByteOrder) {
if (pBitmap == NULL) {
@@ -169,7 +164,7 @@ FX_BOOL CFDE_FxgeDevice::DrawString(IFDE_Brush* pBrush,
SubstFxFont.m_WeightCJK = SubstFxFont.m_Weight;
SubstFxFont.m_ItalicAngle = dwFontStyle & FX_FONTSTYLE_Italic ? -12 : 0;
SubstFxFont.m_bItlicCJK = !!(dwFontStyle & FX_FONTSTYLE_Italic);
-#endif
+#endif // _FXM_PLATFORM_ != _FXM_PLATFORM_WINDOWS_
for (int32_t i = 0; i < iCount; ++i) {
pSTFont = pFont->GetSubstFont((int32_t)pCP->m_GlyphIndex);
pCP->m_GlyphIndex &= 0x00FFFFFF;
@@ -186,7 +181,7 @@ FX_BOOL CFDE_FxgeDevice::DrawString(IFDE_Brush* pBrush,
m_pDevice->DrawNormalText(iCurCount, pCurCP, pFxFont, pCache,
-fFontSize, (const CFX_Matrix*)pMatrix,
argb, FXTEXT_CLEARTYPE);
-#endif
+#endif // _FXM_PLATFORM_ != _FXM_PLATFORM_WINDOWS_
}
pCurFont = pSTFont;
pCurCP = pCP;
@@ -210,12 +205,12 @@ FX_BOOL CFDE_FxgeDevice::DrawString(IFDE_Brush* pBrush,
return m_pDevice->DrawNormalText(iCurCount, pCurCP, pFxFont, pCache,
-fFontSize, (const CFX_Matrix*)pMatrix,
argb, FXTEXT_CLEARTYPE);
-#endif
+#endif // _FXM_PLATFORM_ != _FXM_PLATFORM_WINDOWS_
}
#if _FXM_PLATFORM_ != _FXM_PLATFORM_WINDOWS_
FxFont.SetSubstFont(nullptr);
FxFont.SetFace(nullptr);
-#endif
+#endif // _FXM_PLATFORM_ != _FXM_PLATFORM_WINDOWS_
return TRUE;
} break;
default:
@@ -576,4 +571,3 @@ FX_BOOL CFDE_FxgeDevice::FillLinearGradientPath(IFDE_Brush* pBrush,
}
return WrapTexture(pLinearBrush->GetWrapMode(), &bmp, pPath, pMatrix);
}
-#endif
diff --git a/xfa/src/fdp/src/fde/fde_gedevice.h b/xfa/src/fdp/src/fde/fde_gedevice.h
index 1f39895568..765ed954f8 100644
--- a/xfa/src/fdp/src/fde/fde_gedevice.h
+++ b/xfa/src/fdp/src/fde/fde_gedevice.h
@@ -10,7 +10,6 @@
#include "xfa/src/fdp/include/fde_rdv.h"
#include "xfa/src/fgas/include/fx_mem.h"
-#ifndef _FDEPLUS
class CFDE_FxgeDevice : public IFDE_RenderDevice, public CFX_Target {
public:
CFDE_FxgeDevice(CFX_RenderDevice* pDevice, FX_BOOL bOwnerDevice);
@@ -133,6 +132,5 @@ class CFDE_FxgeDevice : public IFDE_RenderDevice, public CFX_Target {
FXTEXT_CHARPOS* m_pCharPos;
int32_t m_iCharCount;
};
-#endif
#endif // XFA_SRC_FDP_SRC_FDE_FDE_GEDEVICE_H_
diff --git a/xfa/src/fdp/src/fde/fde_geobject.cpp b/xfa/src/fdp/src/fde/fde_geobject.cpp
index ed122abbb0..748bbb3f77 100644
--- a/xfa/src/fdp/src/fde/fde_geobject.cpp
+++ b/xfa/src/fdp/src/fde/fde_geobject.cpp
@@ -7,7 +7,7 @@
#include "xfa/src/fdp/src/fde/fde_geobject.h"
#include "xfa/src/fdp/src/fde/fde_object.h"
#include "xfa/src/foxitlib.h"
-#ifndef _FDEPLUS
+
IFDE_Path* IFDE_Path::Create() {
return new CFDE_Path;
}
@@ -264,4 +264,3 @@ void CFDE_Path::GetBBox(CFX_RectF& bbox,
bbox.Set(rect.left, rect.top, rect.Width(), rect.Height());
bbox.Normalize();
}
-#endif
diff --git a/xfa/src/fdp/src/fde/fde_geobject.h b/xfa/src/fdp/src/fde/fde_geobject.h
index c883ebc794..cf8ed51387 100644
--- a/xfa/src/fdp/src/fde/fde_geobject.h
+++ b/xfa/src/fdp/src/fde/fde_geobject.h
@@ -7,8 +7,8 @@
#ifndef XFA_SRC_FDP_SRC_FDE_FDE_GEOBJECT_H_
#define XFA_SRC_FDP_SRC_FDE_FDE_GEOBJECT_H_
-#ifndef _FDEPLUS
#include "xfa/src/foxitlib.h"
+
class CFDE_GEFontMgr;
class CFDE_Path : public IFDE_Path, public CFX_Target {
public:
@@ -52,6 +52,5 @@ class CFDE_Path : public IFDE_Path, public CFX_Target {
FX_FLOAT fTension) const;
CFX_PathData m_Path;
};
-#endif
#endif // XFA_SRC_FDP_SRC_FDE_FDE_GEOBJECT_H_