summaryrefslogtreecommitdiff
path: root/filter/source/graphicfilter/idxf
diff options
context:
space:
mode:
Diffstat (limited to 'filter/source/graphicfilter/idxf')
-rw-r--r--filter/source/graphicfilter/idxf/dxf2mtf.cxx32
-rw-r--r--filter/source/graphicfilter/idxf/dxfblkrd.cxx10
-rw-r--r--filter/source/graphicfilter/idxf/dxfentrd.cxx12
-rw-r--r--filter/source/graphicfilter/idxf/dxfentrd.hxx2
-rw-r--r--filter/source/graphicfilter/idxf/dxfreprd.cxx6
-rw-r--r--filter/source/graphicfilter/idxf/dxftblrd.cxx38
6 files changed, 50 insertions, 50 deletions
diff --git a/filter/source/graphicfilter/idxf/dxf2mtf.cxx b/filter/source/graphicfilter/idxf/dxf2mtf.cxx
index 7ca557a00893..d8fbfdb83371 100644
--- a/filter/source/graphicfilter/idxf/dxf2mtf.cxx
+++ b/filter/source/graphicfilter/idxf/dxf2mtf.cxx
@@ -33,7 +33,7 @@ sal_uLong DXF2GDIMetaFile::CountEntities(const DXFEntities & rEntities)
sal_uLong nRes;
nRes=0;
- for (pBE=rEntities.pFirst; pBE!=NULL; pBE=pBE->pSucc) nRes++;
+ for (pBE=rEntities.pFirst; pBE!=nullptr; pBE=pBE->pSucc) nRes++;
return nRes;
}
@@ -56,7 +56,7 @@ long DXF2GDIMetaFile::GetEntityColor(const DXFBasicEntity & rE)
nColor=nParentLayerColor;
} else {
pLayer=pDXF->aTables.SearchLayer(rE.m_sLayer);
- if (pLayer!=NULL) nColor=pLayer->nColor;
+ if (pLayer!=nullptr) nColor=pLayer->nColor;
else nColor=nParentLayerColor;
}
}
@@ -70,7 +70,7 @@ DXFLineInfo DXF2GDIMetaFile::LTypeToDXFLineInfo(OString const& rLineType)
DXFLineInfo aDXFLineInfo;
pLT = pDXF->aTables.SearchLType(rLineType);
- if (pLT==NULL || pLT->nDashCount == 0) {
+ if (pLT==nullptr || pLT->nDashCount == 0) {
aDXFLineInfo.eStyle = LINE_SOLID;
}
else {
@@ -129,7 +129,7 @@ DXFLineInfo DXF2GDIMetaFile::GetEntityDXFLineInfo(const DXFBasicEntity & rE)
aDXFLineInfo=aParentLayerDXFLineInfo;
} else {
const DXFLayer * pLayer=pDXF->aTables.SearchLayer(rE.m_sLayer);
- if (pLayer!=NULL) {
+ if (pLayer!=nullptr) {
aDXFLineInfo = LTypeToDXFLineInfo(pLayer->m_sLineType);
}
else aDXFLineInfo=aParentLayerDXFLineInfo;
@@ -438,7 +438,7 @@ void DXF2GDIMetaFile::DrawInsertEntity(const DXFInsertEntity & rE, const DXFTran
{
const DXFBlock * pB;
pB=pDXF->aBlocks.Search(rE.m_sName);
- if (pB!=NULL) {
+ if (pB!=nullptr) {
DXFTransform aDXFTransform1(1.0,1.0,1.0,DXFVector(0.0,0.0,0.0)-pB->aBasePoint);
DXFTransform aDXFTransform2(rE.fXScale,rE.fYScale,rE.fZScale,rE.fRotAngle,rE.aP0);
DXFTransform aT(
@@ -455,7 +455,7 @@ void DXF2GDIMetaFile::DrawInsertEntity(const DXFInsertEntity & rE, const DXFTran
aBlockDXFLineInfo=GetEntityDXFLineInfo(rE);
if (rE.m_sLayer.getLength() > 1) {
DXFLayer * pLayer=pDXF->aTables.SearchLayer(rE.m_sLayer);
- if (pLayer!=NULL) {
+ if (pLayer!=nullptr) {
nParentLayerColor=pLayer->nColor;
aParentLayerDXFLineInfo = LTypeToDXFLineInfo(pLayer->m_sLineType);
}
@@ -501,7 +501,7 @@ void DXF2GDIMetaFile::DrawPolyLineEntity(const DXFPolyLineEntity & rE, const DXF
nPolySize=0;
pBE=rE.pSucc;
- while (pBE!=NULL && pBE->eType==DXF_VERTEX) {
+ while (pBE!=nullptr && pBE->eType==DXF_VERTEX) {
nPolySize++;
pBE=pBE->pSucc;
}
@@ -648,7 +648,7 @@ void DXF2GDIMetaFile::DrawDimensionEntity(const DXFDimensionEntity & rE, const D
{
const DXFBlock * pB;
pB=pDXF->aBlocks.Search(rE.m_sPseudoBlock);
- if (pB!=NULL) {
+ if (pB!=nullptr) {
DXFTransform aT(
DXFTransform(1.0,1.0,1.0,DXFVector(0.0,0.0,0.0)-pB->aBasePoint),
rTransform
@@ -663,7 +663,7 @@ void DXF2GDIMetaFile::DrawDimensionEntity(const DXFDimensionEntity & rE, const D
aBlockDXFLineInfo=GetEntityDXFLineInfo(rE);
if (rE.m_sLayer.getLength() > 1) {
DXFLayer * pLayer=pDXF->aTables.SearchLayer(rE.m_sLayer);
- if (pLayer!=NULL) {
+ if (pLayer!=nullptr) {
nParentLayerColor=pLayer->nColor;
aParentLayerDXFLineInfo = LTypeToDXFLineInfo(pLayer->m_sLineType);
}
@@ -686,7 +686,7 @@ void DXF2GDIMetaFile::DrawEntities(const DXFEntities & rEntities,
const DXFBasicEntity * pE=rEntities.pFirst;
- while (pE!=NULL && bStatus) {
+ while (pE!=nullptr && bStatus) {
if (pE->nSpace==0) {
if (pE->aExtrusion.fz==1.0) {
pT=&rTransform;
@@ -749,8 +749,8 @@ void DXF2GDIMetaFile::DrawEntities(const DXFEntities & rEntities,
DXF2GDIMetaFile::DXF2GDIMetaFile()
- : pVirDev(NULL)
- , pDXF(NULL)
+ : pVirDev(nullptr)
+ , pDXF(nullptr)
, bStatus(false)
, OptPointsPerCircle(0)
, nMinPercent(0)
@@ -797,7 +797,7 @@ bool DXF2GDIMetaFile::Convert(const DXFRepresentation & rDXF, GDIMetaFile & rMTF
aBlockDXFLineInfo.fDistance = 0;
pLayer=pDXF->aTables.SearchLayer("0");
- if (pLayer!=NULL) {
+ if (pLayer!=nullptr) {
nParentLayerColor=pLayer->nColor & 0xff;
aParentLayerDXFLineInfo = LTypeToDXFLineInfo(pLayer->m_sLineType);
}
@@ -820,12 +820,12 @@ bool DXF2GDIMetaFile::Convert(const DXFRepresentation & rDXF, GDIMetaFile & rMTF
aActFont = pVirDev->GetFont();
pVPort=pDXF->aTables.SearchVPort("*ACTIVE");
- if (pVPort!=NULL) {
+ if (pVPort!=nullptr) {
if (pVPort->aDirection.fx==0 && pVPort->aDirection.fy==0)
- pVPort=NULL;
+ pVPort=nullptr;
}
- if (pVPort==NULL) {
+ if (pVPort==nullptr) {
if (pDXF->aBoundingBox.bEmpty)
bStatus=false;
else {
diff --git a/filter/source/graphicfilter/idxf/dxfblkrd.cxx b/filter/source/graphicfilter/idxf/dxfblkrd.cxx
index 00f8e4f4fee5..d16428f3e850 100644
--- a/filter/source/graphicfilter/idxf/dxfblkrd.cxx
+++ b/filter/source/graphicfilter/idxf/dxfblkrd.cxx
@@ -28,7 +28,7 @@
DXFBlock::DXFBlock()
- : pSucc(NULL)
+ : pSucc(nullptr)
, nFlags(0)
{
}
@@ -73,7 +73,7 @@ void DXFBlock::Read(DXFGroupReader & rDGR)
DXFBlocks::DXFBlocks()
{
- pFirst=NULL;
+ pFirst=nullptr;
}
@@ -88,7 +88,7 @@ void DXFBlocks::Read(DXFGroupReader & rDGR)
DXFBlock * pB, * * ppSucc;
ppSucc=&pFirst;
- while (*ppSucc!=NULL) ppSucc=&((*ppSucc)->pSucc);
+ while (*ppSucc!=nullptr) ppSucc=&((*ppSucc)->pSucc);
for (;;) {
while (rDGR.GetG()!=0) rDGR.Read();
@@ -108,7 +108,7 @@ void DXFBlocks::Read(DXFGroupReader & rDGR)
DXFBlock * DXFBlocks::Search(OString const& rName) const
{
DXFBlock * pB;
- for (pB=pFirst; pB!=NULL; pB=pB->pSucc) {
+ for (pB=pFirst; pB!=nullptr; pB=pB->pSucc) {
if (rName == pB->m_sName) break;
}
return pB;
@@ -119,7 +119,7 @@ void DXFBlocks::Clear()
{
DXFBlock * ptmp;
- while (pFirst!=NULL) {
+ while (pFirst!=nullptr) {
ptmp=pFirst;
pFirst=ptmp->pSucc;
delete ptmp;
diff --git a/filter/source/graphicfilter/idxf/dxfentrd.cxx b/filter/source/graphicfilter/idxf/dxfentrd.cxx
index 0291d5be8f85..755b9df2bc78 100644
--- a/filter/source/graphicfilter/idxf/dxfentrd.cxx
+++ b/filter/source/graphicfilter/idxf/dxfentrd.cxx
@@ -28,7 +28,7 @@ DXFBasicEntity::DXFBasicEntity(DXFEntityType eThisType)
, m_sLineType("BYLAYER")
{
eType=eThisType;
- pSucc=NULL;
+ pSucc=nullptr;
fElevation=0;
fThickness=0;
nColor=256;
@@ -411,7 +411,7 @@ DXFLWPolyLineEntity::DXFLWPolyLineEntity() :
fConstantWidth( 0.0 ),
fStartWidth( 0.0 ),
fEndWidth( 0.0 ),
- pP( NULL )
+ pP( nullptr )
{
}
@@ -571,7 +571,7 @@ DXFBoundaryPathData::DXFBoundaryPathData() :
nEdgeCount( 0 ),
bIsPolyLine( true ),
nPointIndex( 0 ),
- pP( NULL )
+ pP( nullptr )
{
}
@@ -662,7 +662,7 @@ DXFHatchEntity::DXFHatchEntity() :
nHatchPatternDefinitionLines( 0 ),
fPixelSize( 1.0 ),
nNumberOfSeedPoints( 0 ),
- pBoundaryPathData( NULL )
+ pBoundaryPathData( nullptr )
{
}
@@ -803,7 +803,7 @@ void DXFEntities::Read(DXFGroupReader & rDGR)
DXFBasicEntity * pE, * * ppSucc;
ppSucc=&pFirst;
- while (*ppSucc!=NULL) ppSucc=&((*ppSucc)->pSucc);
+ while (*ppSucc!=nullptr) ppSucc=&((*ppSucc)->pSucc);
while (rDGR.GetG()!=0) rDGR.Read();
@@ -847,7 +847,7 @@ void DXFEntities::Clear()
{
DXFBasicEntity * ptmp;
- while (pFirst!=NULL) {
+ while (pFirst!=nullptr) {
ptmp=pFirst;
pFirst=ptmp->pSucc;
delete ptmp;
diff --git a/filter/source/graphicfilter/idxf/dxfentrd.hxx b/filter/source/graphicfilter/idxf/dxfentrd.hxx
index 603d43fd4356..638f3ad12ee9 100644
--- a/filter/source/graphicfilter/idxf/dxfentrd.hxx
+++ b/filter/source/graphicfilter/idxf/dxfentrd.hxx
@@ -528,7 +528,7 @@ public:
inline DXFEntities::DXFEntities()
{
- pFirst=NULL;
+ pFirst=nullptr;
}
diff --git a/filter/source/graphicfilter/idxf/dxfreprd.cxx b/filter/source/graphicfilter/idxf/dxfreprd.cxx
index c276e58e8766..6c1993e91997 100644
--- a/filter/source/graphicfilter/idxf/dxfreprd.cxx
+++ b/filter/source/graphicfilter/idxf/dxfreprd.cxx
@@ -244,7 +244,7 @@ void DXFRepresentation::CalcBoundingBox(const DXFEntities & rEntities,
DXFBoundingBox & rBox)
{
DXFBasicEntity * pBE=rEntities.pFirst;
- while (pBE!=NULL) {
+ while (pBE!=nullptr) {
switch (pBE->eType) {
case DXF_LINE: {
const DXFLineEntity * pE = static_cast<const DXFLineEntity*>(pBE);
@@ -315,7 +315,7 @@ void DXFRepresentation::CalcBoundingBox(const DXFEntities & rEntities,
DXFBoundingBox aBox;
DXFVector aP;
pB=aBlocks.Search(pE->m_sName);
- if (pB==NULL) break;
+ if (pB==nullptr) break;
CalcBoundingBox(*pB,aBox);
if (aBox.bEmpty) break;
aP.fx=(aBox.fMinX-pB->aBasePoint.fx)*pE->fXScale+pE->aP0.fx;
@@ -357,7 +357,7 @@ void DXFRepresentation::CalcBoundingBox(const DXFEntities & rEntities,
DXFBoundingBox aBox;
DXFVector aP;
pB = aBlocks.Search(pE->m_sPseudoBlock);
- if (pB==NULL) break;
+ if (pB==nullptr) break;
CalcBoundingBox(*pB,aBox);
if (aBox.bEmpty) break;
aP.fx=aBox.fMinX-pB->aBasePoint.fx;
diff --git a/filter/source/graphicfilter/idxf/dxftblrd.cxx b/filter/source/graphicfilter/idxf/dxftblrd.cxx
index 26d96dd3a653..1d2f8b483428 100644
--- a/filter/source/graphicfilter/idxf/dxftblrd.cxx
+++ b/filter/source/graphicfilter/idxf/dxftblrd.cxx
@@ -24,7 +24,7 @@
//----------------------------------DXFLType-----------------------------------
DXFLType::DXFLType()
- : pSucc(NULL)
+ : pSucc(nullptr)
, nFlags(0)
, nDashCount(0)
, fPatternLength(0.0)
@@ -81,7 +81,7 @@ void DXFLType::Read(DXFGroupReader & rDGR)
DXFLayer::DXFLayer()
{
- pSucc=NULL;
+ pSucc=nullptr;
nFlags=0;
nColor=-1;
}
@@ -112,7 +112,7 @@ void DXFLayer::Read(DXFGroupReader & rDGR)
DXFStyle::DXFStyle()
{
- pSucc=NULL;
+ pSucc=nullptr;
nFlags=0;
fHeight=0.0;
fWidthFak=1.0;
@@ -162,7 +162,7 @@ void DXFStyle::Read(DXFGroupReader & rDGR)
DXFVPort::DXFVPort()
{
- pSucc=NULL;
+ pSucc=nullptr;
nFlags=0;
fMinX=0;
@@ -250,10 +250,10 @@ void DXFVPort::Read(DXFGroupReader & rDGR)
DXFTables::DXFTables()
{
- pLTypes=NULL;
- pLayers=NULL;
- pStyles=NULL;
- pVPorts=NULL;
+ pLTypes=nullptr;
+ pLayers=nullptr;
+ pStyles=nullptr;
+ pVPorts=nullptr;
}
@@ -271,16 +271,16 @@ void DXFTables::Read(DXFGroupReader & rDGR)
DXFVPort * * ppVP, * pVP;
ppLT=&pLTypes;
- while(*ppLT!=NULL) ppLT=&((*ppLT)->pSucc);
+ while(*ppLT!=nullptr) ppLT=&((*ppLT)->pSucc);
ppLa=&pLayers;
- while(*ppLa!=NULL) ppLa=&((*ppLa)->pSucc);
+ while(*ppLa!=nullptr) ppLa=&((*ppLa)->pSucc);
ppSt=&pStyles;
- while(*ppSt!=NULL) ppSt=&((*ppSt)->pSucc);
+ while(*ppSt!=nullptr) ppSt=&((*ppSt)->pSucc);
ppVP=&pVPorts;
- while(*ppVP!=NULL) ppVP=&((*ppVP)->pSucc);
+ while(*ppVP!=nullptr) ppVP=&((*ppVP)->pSucc);
for (;;) {
while (rDGR.GetG()!=0) rDGR.Read();
@@ -322,22 +322,22 @@ void DXFTables::Clear()
DXFStyle * pSt;
DXFVPort * pVP;
- while (pStyles!=NULL) {
+ while (pStyles!=nullptr) {
pSt=pStyles;
pStyles=pSt->pSucc;
delete pSt;
}
- while (pLayers!=NULL) {
+ while (pLayers!=nullptr) {
pLa=pLayers;
pLayers=pLa->pSucc;
delete pLa;
}
- while (pLTypes!=NULL) {
+ while (pLTypes!=nullptr) {
pLT=pLTypes;
pLTypes=pLT->pSucc;
delete pLT;
}
- while (pVPorts!=NULL) {
+ while (pVPorts!=nullptr) {
pVP=pVPorts;
pVPorts=pVP->pSucc;
delete pVP;
@@ -348,7 +348,7 @@ void DXFTables::Clear()
DXFLType * DXFTables::SearchLType(OString const& rName) const
{
DXFLType * p;
- for (p=pLTypes; p!=NULL; p=p->pSucc) {
+ for (p=pLTypes; p!=nullptr; p=p->pSucc) {
if (rName == p->m_sName) break;
}
return p;
@@ -358,7 +358,7 @@ DXFLType * DXFTables::SearchLType(OString const& rName) const
DXFLayer * DXFTables::SearchLayer(OString const& rName) const
{
DXFLayer * p;
- for (p=pLayers; p!=NULL; p=p->pSucc) {
+ for (p=pLayers; p!=nullptr; p=p->pSucc) {
if (rName == p->m_sName) break;
}
return p;
@@ -368,7 +368,7 @@ DXFLayer * DXFTables::SearchLayer(OString const& rName) const
DXFVPort * DXFTables::SearchVPort(OString const& rName) const
{
DXFVPort * p;
- for (p=pVPorts; p!=NULL; p=p->pSucc) {
+ for (p=pVPorts; p!=nullptr; p=p->pSucc) {
if (rName == p->m_sName) break;
}
return p;