diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2011-03-13 06:49:58 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2011-03-13 06:49:58 -0500 |
commit | 8021c2f31277989f87ca8224234358760bb3c865 (patch) | |
tree | 9675645b64b705b590bf1f68556414bd6caecda9 /lotuswordpro | |
parent | 84660a54284fe27d294daa11490edbaa81b32376 (diff) |
convert tools type in lotuswordpro
Diffstat (limited to 'lotuswordpro')
30 files changed, 156 insertions, 156 deletions
diff --git a/lotuswordpro/source/filter/LotusWordProImportFilter.cxx b/lotuswordpro/source/filter/LotusWordProImportFilter.cxx index 993d1ecabee1..a7c52135668a 100644 --- a/lotuswordpro/source/filter/LotusWordProImportFilter.cxx +++ b/lotuswordpro/source/filter/LotusWordProImportFilter.cxx @@ -156,8 +156,8 @@ private: void parseDoc() { - UINT8 nDelim, nDummy, nLen, nData; - UINT16 nOpcode; + sal_uInt8 nDelim, nDummy, nLen, nData; + sal_uInt16 nOpcode; OUStringBuffer sBuf( MAXCHARS ); sal_Int32 nChars = 0; @@ -173,7 +173,7 @@ private: m_InputStream >> nLen >> nDummy; while( nLen > 0 && !m_InputStream.IsEof() ) { - UINT8 nChar; + sal_uInt8 nChar; m_InputStream >> nChar; if( CheckValidData( nChar ) ) { diff --git a/lotuswordpro/source/filter/bencont.cxx b/lotuswordpro/source/filter/bencont.cxx index c66b8768b83f..1e1bd6a0f101 100644 --- a/lotuswordpro/source/filter/bencont.cxx +++ b/lotuswordpro/source/filter/bencont.cxx @@ -69,7 +69,7 @@ const char gsBenMagicBytes[] = BEN_MAGIC_BYTES; * @param pointer to pointer of Bento Container object * @return error code */ -ULONG BenOpenContainer(LwpSvStream * pStream, pLtcBenContainer * ppContainer) +sal_uLong BenOpenContainer(LwpSvStream * pStream, pLtcBenContainer * ppContainer) { BenError Err; @@ -247,7 +247,7 @@ BenError LtcBenContainer::Read(BenDataPtr pBuffer, unsigned long MaxSize, */ BenError LtcBenContainer::ReadKnownSize(BenDataPtr pBuffer, unsigned long Amt) { - ULONG ulLength; + sal_uLong ulLength; ulLength = cpStream->Read(pBuffer, Amt); if(ulLength == Amt) { @@ -367,7 +367,7 @@ LtcUtBenValueStream * LtcBenContainer::FindObjectValueStreamWithObjectIDAndPrope * @param pointer to length of bento file * @return BenError */ -BenError LtcBenContainer::GetSize(ULONG * pLength) +BenError LtcBenContainer::GetSize(sal_uLong * pLength) { *pLength = m_ulLength; return BenErr_OK; diff --git a/lotuswordpro/source/filter/bento.hxx b/lotuswordpro/source/filter/bento.hxx index e3008f14ade0..56b04b122a91 100644 --- a/lotuswordpro/source/filter/bento.hxx +++ b/lotuswordpro/source/filter/bento.hxx @@ -89,23 +89,23 @@ namespace OpenStormBento #define ASWENTRY_SIZE 204 struct ClsId { - INT32 n1; - INT16 n2, n3; - UINT8 n4, n5, n6, n7, n8, n9, n10, n11; + sal_Int32 n1; + sal_Int16 n2, n3; + sal_uInt8 n4, n5, n6, n7, n8, n9, n10, n11; }; class AswEntry //total length: 204 { - UINT16 nName[ 68 ]; //Name of IStorage or IStream referenced by this entry, length = 136 - INT32 nMtime[ 2 ]; - INT32 nCtime[ 2 ]; - INT32 nAtime[ 2 ]; + sal_uInt16 nName[ 68 ]; //Name of IStorage or IStream referenced by this entry, length = 136 + sal_Int32 nMtime[ 2 ]; + sal_Int32 nCtime[ 2 ]; + sal_Int32 nAtime[ 2 ]; ClsId aClsId; //CLSID from OLE 2 IStorage::SetClass call - UINT32 nStatebits; //State bits from OLE 2 IStorage::SetStateBits call - UINT32 nType; // STGTY_STORAGE: 1 or STGTY_STREAM:2, - UINT32 nObjectIDRef; //Persistent Bento reference to Bento object for this IStorage or IStream - UINT32 nMversion; - UINT32 nLversion; - UINT32 nReserved[2]; //skip 16 char + sal_uInt32 nStatebits; //State bits from OLE 2 IStorage::SetStateBits call + sal_uInt32 nType; // STGTY_STORAGE: 1 or STGTY_STREAM:2, + sal_uInt32 nObjectIDRef; //Persistent Bento reference to Bento object for this IStorage or IStream + sal_uInt32 nMversion; + sal_uInt32 nLversion; + sal_uInt32 nReserved[2]; //skip 16 char public: AswEntry(); void Init(); // initialize the data @@ -113,12 +113,12 @@ public: void GetName( String& rName ) const; void Load( const void* ); void Store( void* ); - UINT32 GetType() const { return nType; } - void SetType( UINT32 t ) { nType = t;} + sal_uInt32 GetType() const { return nType; } + void SetType( sal_uInt32 t ) { nType = t;} const ClsId& GetClassId() const { return aClsId;} void SetClassId( const ClsId& ); - void SetObjectID(UINT32 id) { nObjectIDRef = id;} - UINT32 GetObjectID() const { return nObjectIDRef;} + void SetObjectID(sal_uInt32 id) { nObjectIDRef = id;} + sal_uInt32 GetObjectID() const { return nObjectIDRef;} }; //End by @@ -197,7 +197,7 @@ typedef unsigned long BenContainerPos; typedef unsigned long BenObjectID; typedef unsigned long BenGeneration; -ULONG BenOpenContainer(LwpSvStream * pStream, pLtcBenContainer * ppContainer); +sal_uLong BenOpenContainer(LwpSvStream * pStream, pLtcBenContainer * ppContainer); class CBenIDListElmt : public CUtListElmt { @@ -241,21 +241,21 @@ public: // Overridden methods /* added by */ CBenValue * GetValue(){ return cpValue; }; - ULONG GetSize() { return m_ulValueLength; }; + sal_uLong GetSize() { return m_ulValueLength; }; protected: // Overridden methods - virtual ULONG GetData( void* pData, ULONG nSize ); - virtual ULONG PutData( const void* pData, ULONG nSize ); - virtual ULONG SeekPos( ULONG nPos ); - virtual void SetSize( ULONG nSize ); + virtual sal_uLong GetData( void* pData, sal_uLong nSize ); + virtual sal_uLong PutData( const void* pData, sal_uLong nSize ); + virtual sal_uLong SeekPos( sal_uLong nPos ); + virtual void SetSize( sal_uLong nSize ); virtual void FlushData(); private: // Data pCBenValue cpValue; unsigned long cCurrentPosition; - ULONG m_ulValueLength; // Added by , sum of length of all sub-valuesegments -// void GetAmountLeft(ULONG * pAmtLeft); useless in SODC + sal_uLong m_ulValueLength; // Added by , sum of length of all sub-valuesegments +// void GetAmountLeft(sal_uLong * pAmtLeft); useless in SODC }; class LtcBenContainer @@ -303,7 +303,7 @@ public: // Internal methods LtcUtBenValueStream * FindOLEStorageStreamWithObjectName(const char * sObjectName, AswEntry& rDirStruct); void ReadAswEntry(SvStream * pStream, AswEntry& rEntry); - BenError GetSize(ULONG * pLength); + BenError GetSize(sal_uLong * pLength); LwpSvStream * GetStream() { return cpStream; @@ -312,7 +312,7 @@ private: // Data CUtOwningList cObjects; CUtList cNamedObjects; LwpSvStream * cpStream; - ULONG m_ulLength; // Added for TOCRead.cpp + sal_uLong m_ulLength; // Added for TOCRead.cpp BenObjectID cNextAvailObjectID; // for new object }; diff --git a/lotuswordpro/source/filter/lwpcolor.hxx b/lotuswordpro/source/filter/lwpcolor.hxx index d1912709721d..61ed9c3e2d8b 100644 --- a/lotuswordpro/source/filter/lwpcolor.hxx +++ b/lotuswordpro/source/filter/lwpcolor.hxx @@ -81,7 +81,7 @@ public: sal_uInt16 GetRed(); sal_uInt16 GetGreen(); sal_uInt16 GetBlue(); - BOOL IsValidColor(); + sal_Bool IsValidColor(); sal_uInt32 To24Color(); LwpColor& operator = (const LwpColor& rOther); sal_Bool IsTransparent(); @@ -118,7 +118,7 @@ inline sal_uInt16 LwpColor::GetBlue() { return m_nBlue; } -inline BOOL LwpColor::IsValidColor() +inline sal_Bool LwpColor::IsValidColor() { return ((m_nExtra!=AGLRGB_INVALID) && (m_nExtra!=AGLRGB_TRANSPARENT)); } diff --git a/lotuswordpro/source/filter/lwpdoc.hxx b/lotuswordpro/source/filter/lwpdoc.hxx index 178280ad58bc..1995759de7bd 100644 --- a/lotuswordpro/source/filter/lwpdoc.hxx +++ b/lotuswordpro/source/filter/lwpdoc.hxx @@ -190,7 +190,7 @@ private: inline sal_Bool LwpDocument::IsChildDoc() { - return (sal_Bool) ((m_nPersistentFlags & DOC_CHILDDOC) ? TRUE : FALSE); + return (sal_Bool) ((m_nPersistentFlags & DOC_CHILDDOC) ? sal_True : sal_False); } inline sal_Bool LwpDocument::HonorProtection() { diff --git a/lotuswordpro/source/filter/lwpfilter.cxx b/lotuswordpro/source/filter/lwpfilter.cxx index b9e640935fc8..0c4ef8229ff9 100644 --- a/lotuswordpro/source/filter/lwpfilter.cxx +++ b/lotuswordpro/source/filter/lwpfilter.cxx @@ -484,7 +484,7 @@ sal_Bool IsWordProStr(const sal_Int8 *pBuf) sal_Bool IsWordproFile(rtl::OUString file) { sal_Bool bRet = sal_False; - SfxMedium aMedium( file, STREAM_STD_READ, FALSE); + SfxMedium aMedium( file, STREAM_STD_READ, sal_False); SvStream* pStm = aMedium.GetInStream(); if(pStm) diff --git a/lotuswordpro/source/filter/lwpfont.cxx b/lotuswordpro/source/filter/lwpfont.cxx index a06a99dffcbf..85eb7f76881a 100644 --- a/lotuswordpro/source/filter/lwpfont.cxx +++ b/lotuswordpro/source/filter/lwpfont.cxx @@ -94,13 +94,13 @@ void LwpFontAttrEntry::Override( XFFont*pFont ) if (IsSuperOverridden()) { if(Is(SUPERSCRIPT)) - pFont->SetPosition(TRUE); + pFont->SetPosition(sal_True); } if (IsSubOverridden()) { if(Is(SUBSCRIPT)) - pFont->SetPosition(FALSE); + pFont->SetPosition(sal_False); } if (IsUnderlineOverridden()) @@ -168,50 +168,50 @@ void LwpFontAttrEntry::Override( XFFont*pFont ) // pFont->SetTightness(cTightness);*/ } -BOOL LwpFontAttrEntry::Is(sal_uInt16 Attr) +sal_Bool LwpFontAttrEntry::Is(sal_uInt16 Attr) { return (0 != (m_nAttrBits & Attr)); } -BOOL LwpFontAttrEntry::IsBoldOverridden() +sal_Bool LwpFontAttrEntry::IsBoldOverridden() { return (0 != (m_nAttrOverrideBits & BOLD)); } -BOOL LwpFontAttrEntry::IsItalicOverridden() +sal_Bool LwpFontAttrEntry::IsItalicOverridden() { return (0 != (m_nAttrOverrideBits & ITALIC)); } -BOOL LwpFontAttrEntry::IsStrikeThruOverridden() +sal_Bool LwpFontAttrEntry::IsStrikeThruOverridden() { return (0 != (m_nAttrOverrideBits & STRIKETHRU)); } -BOOL LwpFontAttrEntry::IsSmallCapsOverridden() +sal_Bool LwpFontAttrEntry::IsSmallCapsOverridden() { return (0 != (m_nAttrOverrideBits & SMALLCAPS)); } -BOOL LwpFontAttrEntry::IsSuperOverridden() +sal_Bool LwpFontAttrEntry::IsSuperOverridden() { return (0 != (m_nAttrOverrideBits & SUPERSCRIPT)); } -BOOL LwpFontAttrEntry::IsSubOverridden() +sal_Bool LwpFontAttrEntry::IsSubOverridden() { return (0 != (m_nAttrOverrideBits & SUBSCRIPT)); } -BOOL LwpFontAttrEntry::IsSuperSubOverridden() +sal_Bool LwpFontAttrEntry::IsSuperSubOverridden() { return (0 != (m_nAttrOverrideBits & (SUPERSCRIPT | SUBSCRIPT))); } -BOOL LwpFontAttrEntry::IsUnderlineOverridden() +sal_Bool LwpFontAttrEntry::IsUnderlineOverridden() { return (0 != (m_nAttrOverrideBits2 & UNDER)); } -BOOL LwpFontAttrEntry::IsCaseOverridden() +sal_Bool LwpFontAttrEntry::IsCaseOverridden() { return (0 != (m_nAttrOverrideBits2 & CASE)); } @@ -330,38 +330,38 @@ void LwpFontNameEntry::Override(XFFont* pFont) // pFont->SetTightness(cTightness); } -BOOL LwpFontNameEntry::IsFaceNameOverridden() +sal_Bool LwpFontNameEntry::IsFaceNameOverridden() { return (0 != (m_nOverrideBits & FACENAME)); } -BOOL LwpFontNameEntry::IsAltFaceNameOverridden() +sal_Bool LwpFontNameEntry::IsAltFaceNameOverridden() { return (0 != (m_nOverrideBits & ALTFACENAME)); } -BOOL LwpFontNameEntry::IsPointSizeOverridden() +sal_Bool LwpFontNameEntry::IsPointSizeOverridden() { return (0 != (m_nOverrideBits & POINTSIZE)); } -BOOL LwpFontNameEntry::IsColorOverridden() +sal_Bool LwpFontNameEntry::IsColorOverridden() { return (0 != (m_nOverrideBits & COLOR)); } -BOOL LwpFontNameEntry::IsBackgroundColorOverridden() +sal_Bool LwpFontNameEntry::IsBackgroundColorOverridden() { return (0 != (m_nOverrideBits & BKCOLOR)); } //TODO -//BOOL LwpFontNameEntry::IsTightnessOverridden() +//sal_Bool LwpFontNameEntry::IsTightnessOverridden() //{ // return (0 != (m_nOverrideBits & TIGHTNESS)); //} -//BOOL LwpFontNameEntry::IsAnythingOverridden() +//sal_Bool LwpFontNameEntry::IsAnythingOverridden() //{ // return (0 != (m_nOverrideBits & ALL_BITS)); //} diff --git a/lotuswordpro/source/filter/lwpfont.hxx b/lotuswordpro/source/filter/lwpfont.hxx index 0c639eb5b868..3d27bac87858 100644 --- a/lotuswordpro/source/filter/lwpfont.hxx +++ b/lotuswordpro/source/filter/lwpfont.hxx @@ -118,8 +118,8 @@ public: inline sal_uInt16 GetFaceID(){return m_nFaceName;} inline sal_uInt16 GetAltFaceID(){return m_nAltFaceName;} void Override(XFFont* pFont); - inline BOOL IsFaceNameOverridden(); - inline BOOL IsAltFaceNameOverridden(); + inline sal_Bool IsFaceNameOverridden(); + inline sal_Bool IsAltFaceNameOverridden(); private: //Data of CFontDescriptionOverrideBase sal_uInt8 m_nOverrideBits; @@ -146,12 +146,12 @@ private: | TIGHTNESS | FACENAME | BKCOLOR) }; - inline BOOL IsPointSizeOverridden(); - inline BOOL IsColorOverridden(); - inline BOOL IsBackgroundColorOverridden(); + inline sal_Bool IsPointSizeOverridden(); + inline sal_Bool IsColorOverridden(); + inline sal_Bool IsBackgroundColorOverridden(); //TODO -// inline BOOL IsTightnessOverridden(); -// inline BOOL IsAnythingOverridden(); +// inline sal_Bool IsTightnessOverridden(); +// inline sal_Bool IsAnythingOverridden(); }; class LwpFontNameManager @@ -220,16 +220,16 @@ private: UNDER = 0x02, ALL_ATTRS2 = CASE | UNDER }; - BOOL Is(sal_uInt16 Attr); - BOOL IsBoldOverridden(); - BOOL IsItalicOverridden(); - BOOL IsStrikeThruOverridden(); - BOOL IsSmallCapsOverridden(); - BOOL IsSuperOverridden(); - BOOL IsSubOverridden(); - BOOL IsSuperSubOverridden(); - BOOL IsUnderlineOverridden(); - BOOL IsCaseOverridden(); + sal_Bool Is(sal_uInt16 Attr); + sal_Bool IsBoldOverridden(); + sal_Bool IsItalicOverridden(); + sal_Bool IsStrikeThruOverridden(); + sal_Bool IsSmallCapsOverridden(); + sal_Bool IsSuperOverridden(); + sal_Bool IsSubOverridden(); + sal_Bool IsSuperSubOverridden(); + sal_Bool IsUnderlineOverridden(); + sal_Bool IsCaseOverridden(); }; diff --git a/lotuswordpro/source/filter/lwpfoundry.cxx b/lotuswordpro/source/filter/lwpfoundry.cxx index 2cc2c1eb3db6..9f898d97a0b4 100644 --- a/lotuswordpro/source/filter/lwpfoundry.cxx +++ b/lotuswordpro/source/filter/lwpfoundry.cxx @@ -358,7 +358,7 @@ void LwpVersionManager::Skip(LwpObjectStream *pStrm) while(Count--) { pStrm->QuickRead(&tag, sizeof(tag)); - USHORT len; + sal_uInt16 len; switch(tag) { case TAG_USER_VERSION: @@ -369,7 +369,7 @@ void LwpVersionManager::Skip(LwpObjectStream *pStrm) break; default: - pStrm->QuickRead(&len, sizeof(USHORT)); + pStrm->QuickRead(&len, sizeof(sal_uInt16)); pStrm->SeekRel(len); pStrm->SkipExtra(); break; diff --git a/lotuswordpro/source/filter/lwpfribptr.cxx b/lotuswordpro/source/filter/lwpfribptr.cxx index 9c23aae54e1e..124bdab037f5 100644 --- a/lotuswordpro/source/filter/lwpfribptr.cxx +++ b/lotuswordpro/source/filter/lwpfribptr.cxx @@ -109,12 +109,12 @@ void LwpFribPtr::ReadPara(LwpObjectStream* pObjStrm) sal_uInt8 FribTag=0; sal_uInt8 FribType; sal_uInt8 FribEditor; - BOOL ProblemFrib; + sal_Bool ProblemFrib; LwpFrib* pCurFrib = m_pFribs = NULL; for(;;) { - ProblemFrib = FALSE; + ProblemFrib = sal_False; // Get the frib type pObjStrm->QuickRead(&FribTag, sizeof(FribTag)); @@ -152,7 +152,7 @@ void LwpFribPtr::ReadPara(LwpObjectStream* pObjStrm) pCurFrib = pFrib; } else - ProblemFrib = TRUE; + ProblemFrib = sal_True; } } diff --git a/lotuswordpro/source/filter/lwpgrfobj.cxx b/lotuswordpro/source/filter/lwpgrfobj.cxx index bfb6fa43b7d2..24f33125e6c7 100644 --- a/lotuswordpro/source/filter/lwpgrfobj.cxx +++ b/lotuswordpro/source/filter/lwpgrfobj.cxx @@ -281,7 +281,7 @@ void LwpGraphicObject::XFConvert (XFContentContainer* pCont) Rectangle LwpGraphicObject::GetRectIn100thMM() { #define To100thMM(num) (long)(2540* (double(num)/(72 * 65536L))) - INT32 nLeft,nTop,nRight,nBottom; + sal_Int32 nLeft,nTop,nRight,nBottom; GetRect(nLeft,nTop,nRight,nBottom); return Rectangle( To100thMM(nLeft),To100thMM(nTop),To100thMM(nRight),To100thMM(nBottom) ); } @@ -294,7 +294,7 @@ Rectangle LwpGraphicObject::GetRectIn100thMM() XFRect LwpGraphicObject::GetRectInCM() { #define ToCM(num) (2.54*(double(num)/(72 * 65536L))) - INT32 nLeft,nTop,nRight,nBottom; + sal_Int32 nLeft,nTop,nRight,nBottom; GetRect(nLeft,nTop,nRight,nBottom); return XFRect( ToCM(nLeft),ToCM(nTop),ToCM(nRight-nLeft),ToCM(nBottom-nTop) ); } @@ -308,7 +308,7 @@ XFRect LwpGraphicObject::GetRectInCM() * @param nBottom */ #include "lwpframelayout.hxx" -void LwpGraphicObject::GetRect(INT32& nLeft, INT32& nTop, INT32& nRight, INT32& nBottom) +void LwpGraphicObject::GetRect(sal_Int32& nLeft, sal_Int32& nTop, sal_Int32& nRight, sal_Int32& nBottom) { nLeft = nTop = nRight = nBottom = 0; @@ -523,7 +523,7 @@ sal_uInt32 LwpGraphicObject::GetGrafData(sal_uInt8*& pGrafData) if (pMemGrafStream) { // read image data - UINT32 nPos = pGrafStream->Tell(); + sal_uInt32 nPos = pGrafStream->Tell(); pGrafStream->Seek(STREAM_SEEK_TO_END); sal_uInt32 nDataLen = pGrafStream->Tell(); pGrafStream->Seek(nPos); diff --git a/lotuswordpro/source/filter/lwpgrfobj.hxx b/lotuswordpro/source/filter/lwpgrfobj.hxx index d8a7c79c8111..b5c3ef4cdeac 100644 --- a/lotuswordpro/source/filter/lwpgrfobj.hxx +++ b/lotuswordpro/source/filter/lwpgrfobj.hxx @@ -104,7 +104,7 @@ private: ImageProcessingData m_aIPData; - void GetRect(INT32& nLeft, INT32& nTop, INT32& nRight, INT32& nBottom); + void GetRect(sal_Int32& nLeft, sal_Int32& nTop, sal_Int32& nRight, sal_Int32& nBottom); XFRect GetRectInCM(); Rectangle GetRectIn100thMM(); void XFConvertEquation(XFContentContainer* pCont); diff --git a/lotuswordpro/source/filter/lwplayout.cxx b/lotuswordpro/source/filter/lwplayout.cxx index 1c0c9b7a8c19..af6aa83f40af 100644 --- a/lotuswordpro/source/filter/lwplayout.cxx +++ b/lotuswordpro/source/filter/lwplayout.cxx @@ -689,7 +689,7 @@ double LwpMiddleLayout::GetGeometryWidth() * @descr: Whether the margins is same as parent layout * */ -BOOL LwpMiddleLayout::MarginsSameAsParent() +sal_Bool LwpMiddleLayout::MarginsSameAsParent() { if(m_nOverrideFlag & OVER_MARGINS) { diff --git a/lotuswordpro/source/filter/lwplayout.hxx b/lotuswordpro/source/filter/lwplayout.hxx index 722274c9b016..3e82247720a9 100644 --- a/lotuswordpro/source/filter/lwplayout.hxx +++ b/lotuswordpro/source/filter/lwplayout.hxx @@ -280,7 +280,7 @@ class LwpMiddleLayout : public LwpVirtualLayout public: LwpMiddleLayout( LwpObjectHeader &objHdr, LwpSvStream* pStrm ); virtual ~LwpMiddleLayout(); - virtual BOOL MarginsSameAsParent(); + virtual sal_Bool MarginsSameAsParent(); virtual double GetMarginsValue(const sal_uInt8& nWhichSide); virtual double GetExtMarginsValue(const sal_uInt8& nWhichSide); LwpLayoutGeometry* GetGeometry(); diff --git a/lotuswordpro/source/filter/lwpnumericfmt.cxx b/lotuswordpro/source/filter/lwpnumericfmt.cxx index df7a5a5c4fa2..4a4964920632 100644 --- a/lotuswordpro/source/filter/lwpnumericfmt.cxx +++ b/lotuswordpro/source/filter/lwpnumericfmt.cxx @@ -215,7 +215,7 @@ void LwpNumericFormat::Read() * @return sal_Bool. */ sal_Bool -LwpNumericFormat::IsCurrencyFormat(USHORT Format) +LwpNumericFormat::IsCurrencyFormat(sal_uInt16 Format) { switch (Format) { @@ -277,7 +277,7 @@ LwpNumericFormat::IsCurrencyFormat(USHORT Format) * @param * @return. */ -USHORT +sal_uInt16 LwpNumericFormat::GetDecimalPlaces(void) { if (IsDecimalPlacesOverridden()) @@ -503,8 +503,8 @@ OUString LwpNumericFormat::reencode(OUString sCode) * @param * @return */ -USHORT -LwpNumericFormat::GetDefaultDecimalPlaces(USHORT Format) +sal_uInt16 +LwpNumericFormat::GetDefaultDecimalPlaces(sal_uInt16 Format) { switch (Format) { diff --git a/lotuswordpro/source/filter/lwpnumericfmt.hxx b/lotuswordpro/source/filter/lwpnumericfmt.hxx index 9ba3d02903a0..72f2faa1c8d3 100644 --- a/lotuswordpro/source/filter/lwpnumericfmt.hxx +++ b/lotuswordpro/source/filter/lwpnumericfmt.hxx @@ -192,7 +192,7 @@ private: std::map<sal_uInt16,LwpCurrencyInfo> m_aCurrencyInfo; void InitCurrencySymbol() { - USHORT nC=FMT_ARGENTINEANPESO; + sal_uInt16 nC=FMT_ARGENTINEANPESO; m_aCurrencyInfo[nC++]=LwpCurrencyInfo(String::CreateFromAscii("A")); //FMT_ARGENTINEANPESO = 1, m_aCurrencyInfo[nC++]=LwpCurrencyInfo(String::CreateFromAscii("A$")); //FMT_AUSTRALIANDOLLAR = 2, m_aCurrencyInfo[nC++]=LwpCurrencyInfo(String::CreateFromAscii("oS"),sal_True, sal_True);//FMT_AUSTRIANSCHILLING = 3, @@ -248,8 +248,8 @@ public: LwpNumericFormat(LwpObjectStream * pStrm); ~LwpNumericFormat(){} void Read(); - static sal_Bool IsCurrencyFormat(USHORT Format); - USHORT GetDecimalPlaces(void); + static sal_Bool IsCurrencyFormat(sal_uInt16 Format); + sal_uInt16 GetDecimalPlaces(void); sal_Bool IsDecimalPlacesOverridden(void); sal_Bool IsNegativeOverridden(void); sal_Bool IsZeroOverridden(void); @@ -273,7 +273,7 @@ private: sal_uInt16 cDecimalPlaces; - static USHORT GetDefaultDecimalPlaces(USHORT Format); + static sal_uInt16 GetDefaultDecimalPlaces(sal_uInt16 Format); static LwpCurrencyPool m_aCurrencyInfo; void GetCurrencyStr(LwpNumericFormatSubset aNumber, String& aPrefix, String& aSuffix, sal_Bool bNegtive=sal_False); diff --git a/lotuswordpro/source/filter/lwpobjid.hxx b/lotuswordpro/source/filter/lwpobjid.hxx index 96e6c6d82529..284e4a721428 100644 --- a/lotuswordpro/source/filter/lwpobjid.hxx +++ b/lotuswordpro/source/filter/lwpobjid.hxx @@ -93,7 +93,7 @@ public: sal_uInt32 DiskSize() const; sal_uInt32 DiskSizeIndexed() const; - BOOL IsNull() const; + sal_Bool IsNull() const; sal_Bool IsCompressed(); sal_uInt32 GetLow() const ; @@ -101,24 +101,24 @@ public: void SetLow(sal_uInt32 nl); void SetHigh(sal_uInt16 nh); - BOOL operator == (const LwpObjectID &Other) const; - BOOL operator != (const LwpObjectID &Other) const; + sal_Bool operator == (const LwpObjectID &Other) const; + sal_Bool operator != (const LwpObjectID &Other) const; sal_Char* GetBuffer(sal_Char* buf); LwpObject* obj(VO_TYPE tag=VO_INVALID) const; size_t HashCode() const; }; -inline BOOL LwpObjectID::IsNull() const +inline sal_Bool LwpObjectID::IsNull() const { return (m_nLow == 0) && (m_nHigh == 0); } -inline BOOL LwpObjectID::operator == (const LwpObjectID &Other) const +inline sal_Bool LwpObjectID::operator == (const LwpObjectID &Other) const { return (m_nHigh == Other.m_nHigh) && (m_nLow == Other.m_nLow); } -inline BOOL LwpObjectID::operator != (const LwpObjectID &Other) const +inline sal_Bool LwpObjectID::operator != (const LwpObjectID &Other) const { return (m_nHigh != Other.m_nHigh) || (m_nLow != Other.m_nLow); } diff --git a/lotuswordpro/source/filter/lwpobjstrm.cxx b/lotuswordpro/source/filter/lwpobjstrm.cxx index 458de2d47d8e..8d5567b84e34 100644 --- a/lotuswordpro/source/filter/lwpobjstrm.cxx +++ b/lotuswordpro/source/filter/lwpobjstrm.cxx @@ -64,7 +64,7 @@ /** * @descr ctor() from LwpSvStream */ -LwpObjectStream::LwpObjectStream(LwpSvStream *pStrm, BOOL isCompressed, sal_uInt16 size) +LwpObjectStream::LwpObjectStream(LwpSvStream *pStrm, sal_Bool isCompressed, sal_uInt16 size) :m_pContentBuf(NULL), m_nBufSize(size), m_nReadPos(0), m_pStrm(pStrm), m_bCompressed(isCompressed) { @@ -189,14 +189,14 @@ void LwpObjectStream::SeekRel(sal_uInt16 pos) /** * @descr Seek to pos in object buffer/buffer */ -BOOL LwpObjectStream::Seek( sal_uInt16 pos) +sal_Bool LwpObjectStream::Seek( sal_uInt16 pos) { if (pos < m_nBufSize) { m_nReadPos = pos; - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } /** diff --git a/lotuswordpro/source/filter/lwpobjstrm.hxx b/lotuswordpro/source/filter/lwpobjstrm.hxx index aca5a552994d..a4a1668f449b 100644 --- a/lotuswordpro/source/filter/lwpobjstrm.hxx +++ b/lotuswordpro/source/filter/lwpobjstrm.hxx @@ -75,7 +75,7 @@ class LwpObjectStream { public: - LwpObjectStream(LwpSvStream *pStrm, BOOL isCompressed, sal_uInt16 size); + LwpObjectStream(LwpSvStream *pStrm, sal_Bool isCompressed, sal_uInt16 size); ~LwpObjectStream(); private: sal_uInt8* m_pContentBuf; //The content buffer of the object @@ -87,12 +87,12 @@ private: sal_uInt16 m_nBufSize; //The total size of m_pContentBuf sal_uInt16 m_nReadPos; //The position of the quick read LwpSvStream* m_pStrm; - BOOL m_bCompressed; + sal_Bool m_bCompressed; public: sal_uInt16 QuickRead(void* buf, sal_uInt16 len); sal_uInt16 GetPos() { return m_nReadPos; } void SeekRel(sal_uInt16 pos); - BOOL Seek( sal_uInt16 pos); + sal_Bool Seek( sal_uInt16 pos); void SkipExtra(); sal_uInt16 CheckExtra(); diff --git a/lotuswordpro/source/filter/lwpoleobject.cxx b/lotuswordpro/source/filter/lwpoleobject.cxx index 58708c94a873..dd28aab29c45 100644 --- a/lotuswordpro/source/filter/lwpoleobject.cxx +++ b/lotuswordpro/source/filter/lwpoleobject.cxx @@ -297,7 +297,7 @@ Rectangle LwpOleObject::GetOLEObjectSize( SotStorage * pStor ) const return aSize; - for( USHORT i = 1; i < 10; i++ ) + for( sal_uInt16 i = 1; i < 10; i++ ) { SotStorageStreamRef xStm = pStor->OpenSotStream( aStreamName, STREAM_READ | STREAM_NOCREATE ); @@ -326,9 +326,9 @@ Rectangle LwpOleObject::GetOLEObjectSize( SotStorage * pStor ) const /** * @descr: Read OLE object picture information */ -BOOL LwpOlePres::Read( SvStream & /*rStm*/ ) +sal_Bool LwpOlePres::Read( SvStream & /*rStm*/ ) { - return TRUE; + return sal_True; } /** @@ -337,17 +337,17 @@ BOOL LwpOlePres::Read( SvStream & /*rStm*/ ) void LwpOlePres::Write( SvStream & rStm ) { WriteClipboardFormat( rStm, FORMAT_GDIMETAFILE ); - rStm << (INT32)(nJobLen +4); // immer leeres TargetDevice + rStm << (sal_Int32)(nJobLen +4); // immer leeres TargetDevice if( nJobLen ) rStm.Write( pJob, nJobLen ); - rStm << (UINT32)nAspect; - rStm << (INT32)-1; //L-Index immer -1 - rStm << (INT32)nAdvFlags; - rStm << (INT32)0; //Compression - rStm << (INT32)aSize.Width(); - rStm << (INT32)aSize.Height(); - ULONG nPos = rStm.Tell(); - rStm << (INT32)0; + rStm << (sal_uInt32)nAspect; + rStm << (sal_Int32)-1; //L-Index immer -1 + rStm << (sal_Int32)nAdvFlags; + rStm << (sal_Int32)0; //Compression + rStm << (sal_Int32)aSize.Width(); + rStm << (sal_Int32)aSize.Height(); + sal_uLong nPos = rStm.Tell(); + rStm << (sal_Int32)0; if( GetFormat() == FORMAT_GDIMETAFILE && pMtf ) { @@ -377,9 +377,9 @@ void LwpOlePres::Write( SvStream & rStm ) { OSL_FAIL( "unknown format" ); } - ULONG nEndPos = rStm.Tell(); + sal_uLong nEndPos = rStm.Tell(); rStm.Seek( nPos ); - rStm << (UINT32)(nEndPos - nPos - 4); + rStm << (sal_uInt32)(nEndPos - nPos - 4); rStm.Seek( nEndPos ); } //End by diff --git a/lotuswordpro/source/filter/lwpoleobject.hxx b/lotuswordpro/source/filter/lwpoleobject.hxx index d330cd3fbd9a..7e40d43f6c94 100644 --- a/lotuswordpro/source/filter/lwpoleobject.hxx +++ b/lotuswordpro/source/filter/lwpoleobject.hxx @@ -146,17 +146,17 @@ private: #include <vcl/outdev.hxx> class LwpOlePres { - ULONG nFormat; - USHORT nAspect; + sal_uLong nFormat; + sal_uInt16 nAspect; Bitmap * pBmp; GDIMetaFile * pMtf; - UINT32 nAdvFlags; - INT32 nJobLen; - BYTE * pJob; + sal_uInt32 nAdvFlags; + sal_Int32 nJobLen; + sal_uInt8 * pJob; Size aSize; // Groesse in 100TH_MM public: - LwpOlePres( ULONG nF ) + LwpOlePres( sal_uLong nF ) : nFormat( nF ) , pBmp( NULL ) , pMtf( NULL ) @@ -178,14 +178,14 @@ public: } Bitmap *GetBitmap() const { return pBmp; } GDIMetaFile *GetMetaFile() const { return pMtf; } - ULONG GetFormat() const { return nFormat; } - void SetAspect( USHORT nAsp ) { nAspect = nAsp; } - ULONG GetAdviseFlags() const { return nAdvFlags; } - void SetAdviseFlags( ULONG nAdv ) { nAdvFlags = nAdv; } + sal_uLong GetFormat() const { return nFormat; } + void SetAspect( sal_uInt16 nAsp ) { nAspect = nAsp; } + sal_uLong GetAdviseFlags() const { return nAdvFlags; } + void SetAdviseFlags( sal_uLong nAdv ) { nAdvFlags = nAdv; } void SetSize( const Size & rSize ) { aSize = rSize; } Size GetSize() const { return aSize; } //Add by , 10/26/2005 /// return FALSE => unknown format - BOOL Read( SvStream & rStm ); + sal_Bool Read( SvStream & rStm ); void Write( SvStream & rStm ); }; //End by diff --git a/lotuswordpro/source/filter/lwppara.hxx b/lotuswordpro/source/filter/lwppara.hxx index 6e19ce4e0838..3f8897339ca4 100644 --- a/lotuswordpro/source/filter/lwppara.hxx +++ b/lotuswordpro/source/filter/lwppara.hxx @@ -292,7 +292,7 @@ private: void OverrideParaBullet(LwpParaProperty* pProps); void OverrideParaNumbering(LwpParaProperty* pProps); void OverrideTab(LwpTabOverride* base,LwpTabOverride* over,XFParaStyle* pOverStyle); - BOOL IsBadHintsInFile(); + sal_Bool IsBadHintsInFile(); //void OutPutSectionTail(IXFStream* pOutputStream); //void OutPutBulletTail(LwpBulletStyleMgr* pBulletStyleMgr,IXFStream* pOutputStream); @@ -410,9 +410,9 @@ inline void LwpPara::SetDropcapLayout(LwpDropcapLayout* pLayout) { m_pDropcapLayout = pLayout; } -inline BOOL LwpPara::IsBadHintsInFile() +inline sal_Bool LwpPara::IsBadHintsInFile() { - return (BOOL) ((m_nFlags & DOC_BADFILEPARAHINTS) != 0); + return (sal_Bool) ((m_nFlags & DOC_BADFILEPARAHINTS) != 0); } inline double LwpPara::GetBelowSpacing() { diff --git a/lotuswordpro/source/filter/lwpsdwrect.cxx b/lotuswordpro/source/filter/lwpsdwrect.cxx index d2732057e297..b84b2520e77a 100644 --- a/lotuswordpro/source/filter/lwpsdwrect.cxx +++ b/lotuswordpro/source/filter/lwpsdwrect.cxx @@ -70,7 +70,7 @@ **************************************************************************/ SdwRectangle::SdwRectangle() : m_bRotated(sal_False) { - for (UINT16 i = 0; i < 4; i++) + for (sal_uInt16 i = 0; i < 4; i++) { m_nRectCorner[0] = Point(0, 0); } diff --git a/lotuswordpro/source/filter/lwptblcell.hxx b/lotuswordpro/source/filter/lwptblcell.hxx index bf6fd8c5207d..1ae5b67c7def 100644 --- a/lotuswordpro/source/filter/lwptblcell.hxx +++ b/lotuswordpro/source/filter/lwptblcell.hxx @@ -311,10 +311,10 @@ public: ~LwpRowSpecifier(){} void QuickRead(LwpObjectStream *pStrm); - String ToString(USHORT nFormulaRow); + String ToString(sal_uInt16 nFormulaRow); - USHORT RowID(USHORT FormulaRow); - USHORT &Row(void); + sal_uInt16 RowID(sal_uInt16 FormulaRow); + sal_uInt16 &Row(void); void SetAbsolute(void); void ClearAbsolute(void); @@ -326,15 +326,15 @@ public: void SetBad(sal_Bool Bad); sal_Bool IsBad(void); - void SetRowDelta(USHORT ReferenceRowID, USHORT FormulaRowID); + void SetRowDelta(sal_uInt16 ReferenceRowID, sal_uInt16 FormulaRowID); private: sal_uInt16 cRow; LwpRowColumnQualifier cQualifier; }; -inline USHORT -LwpRowSpecifier::RowID(USHORT FormulaRow) +inline sal_uInt16 +LwpRowSpecifier::RowID(sal_uInt16 FormulaRow) { if (cQualifier.IsBad()) { @@ -348,7 +348,7 @@ LwpRowSpecifier::RowID(USHORT FormulaRow) return FormulaRow - cRow; } -inline USHORT & +inline sal_uInt16 & LwpRowSpecifier::Row() { return cRow; diff --git a/lotuswordpro/source/filter/lwptblformula.cxx b/lotuswordpro/source/filter/lwptblformula.cxx index 13cf6c8c8bac..e7ef40a48df3 100644 --- a/lotuswordpro/source/filter/lwptblformula.cxx +++ b/lotuswordpro/source/filter/lwptblformula.cxx @@ -212,7 +212,7 @@ sal_Bool LwpFormulaInfo::ReadExpression() case TK_CELLID: if (!ReadCellID()) - readSucceeded = FALSE; + readSucceeded = sal_False; break; case TK_CELLRANGE: @@ -228,7 +228,7 @@ sal_Bool LwpFormulaInfo::ReadExpression() { LwpFormulaFunc* pFunc = new LwpFormulaFunc(TokenType); if (!ReadArguments(*pFunc)) - readSucceeded = FALSE; + readSucceeded = sal_False; m_aStack.push_back(pFunc); } break; @@ -265,7 +265,7 @@ sal_Bool LwpFormulaInfo::ReadExpression() default: // We don't know what to do with this token, so eat it. m_pObjStrm->SeekRel(DiskLength); - readSucceeded = FALSE; + readSucceeded = sal_False; break; } MarkUnsupported(TokenType); diff --git a/lotuswordpro/source/filter/lwptblformula.hxx b/lotuswordpro/source/filter/lwptblformula.hxx index d41e2feb27a0..7901e83d939b 100644 --- a/lotuswordpro/source/filter/lwptblformula.hxx +++ b/lotuswordpro/source/filter/lwptblformula.hxx @@ -202,7 +202,7 @@ public: LwpFormulaInfo(LwpObjectHeader &objHdr, LwpSvStream* pStrm); ~LwpFormulaInfo(); sal_Bool IsFormula(){return sal_True;} - void SetRow(USHORT nRow){ m_nFormulaRow = nRow;} + void SetRow(sal_uInt16 nRow){ m_nFormulaRow = nRow;} String Convert(LwpTableLayout* pCellsMap); void Convert(XFCell * pCell, LwpTableLayout* pCellsMap); protected: @@ -218,7 +218,7 @@ private: sal_Bool ReadConst(); void MarkUnsupported(sal_uInt16 TokenType); - USHORT m_nFormulaRow; + sal_uInt16 m_nFormulaRow; }; #endif diff --git a/lotuswordpro/source/filter/lwptools.cxx b/lotuswordpro/source/filter/lwptools.cxx index 3d3755ed8594..421095463bb4 100644 --- a/lotuswordpro/source/filter/lwptools.cxx +++ b/lotuswordpro/source/filter/lwptools.cxx @@ -118,7 +118,7 @@ sal_uInt16 LwpTools::QuickReadUnicode(LwpObjectStream* pObjStrm, sal_uInt8 readbyte; sal_uInt16 readword; - BOOL flag = sal_False; //switch if unicode part reached + sal_Bool flag = sal_False; //switch if unicode part reached sal_uInt16 sublen = 0; while(readLen<strlen) @@ -190,7 +190,7 @@ sal_uInt16 LwpTools::QuickReadUnicode(LwpObjectStream* pObjStrm, /** * @descr Judge if the data (len) in object stream is lwp unicode packed */ -BOOL LwpTools::IsUnicodePacked(LwpObjectStream* pObjStrm, sal_uInt16 len) +sal_Bool LwpTools::IsUnicodePacked(LwpObjectStream* pObjStrm, sal_uInt16 len) { sal_uInt8 byte; sal_uInt16 oldpos = pObjStrm->GetPos(); diff --git a/lotuswordpro/source/filter/lwptools.hxx b/lotuswordpro/source/filter/lwptools.hxx index 0bf51b7357d1..913cc31b5232 100644 --- a/lotuswordpro/source/filter/lwptools.hxx +++ b/lotuswordpro/source/filter/lwptools.hxx @@ -91,7 +91,7 @@ class LwpTools public: static sal_uInt16 QuickReadUnicode( LwpObjectStream* pObjStrm, OUString& str, sal_uInt16 strlen, rtl_TextEncoding aEncoding ); - static BOOL IsUnicodePacked(LwpObjectStream* pObjStrm, sal_uInt16 len); + static sal_Bool IsUnicodePacked(LwpObjectStream* pObjStrm, sal_uInt16 len); inline static double ConvertFromUnits(const sal_Int32& nUnits); inline static double ConvertToMetric(const double& fInch); diff --git a/lotuswordpro/source/filter/tocread.cxx b/lotuswordpro/source/filter/tocread.cxx index d65c7b695a49..14489c5a1858 100644 --- a/lotuswordpro/source/filter/tocread.cxx +++ b/lotuswordpro/source/filter/tocread.cxx @@ -132,7 +132,7 @@ CBenTOCReader::SearchForLabel(BenByte * pLabel) { BenError Err; - ULONG Length; + sal_uLong Length; if ((Err = cpContainer->GetSize(&Length)) != BenErr_OK) return Err; diff --git a/lotuswordpro/source/filter/utbenvs.cxx b/lotuswordpro/source/filter/utbenvs.cxx index 7cd37efa8058..6fdb838f2bdb 100644 --- a/lotuswordpro/source/filter/utbenvs.cxx +++ b/lotuswordpro/source/filter/utbenvs.cxx @@ -59,7 +59,7 @@ namespace OpenStormBento { /* * useless in SODC -void LtcUtBenValueStream::GetAmountLeft(ULONG * pAmtLeft) +void LtcUtBenValueStream::GetAmountLeft(sal_uLong * pAmtLeft) { if (cCurrentPosition >= m_ulValueLength) { @@ -78,7 +78,7 @@ void LtcUtBenValueStream::GetAmountLeft(ULONG * pAmtLeft) * @param number of bytes to be read * @return number of bytes read */ -ULONG LtcUtBenValueStream::GetData( void* pData, ULONG nSize ) +sal_uLong LtcUtBenValueStream::GetData( void* pData, sal_uLong nSize ) { //unsigned long AmtLeft; unsigned long AmtRead; @@ -98,7 +98,7 @@ ULONG LtcUtBenValueStream::GetData( void* pData, ULONG nSize ) * @param size of buffer to be written * @return number of bytes written into value stream */ -ULONG LtcUtBenValueStream::PutData( const void* /*pData*/, ULONG nSize ) +sal_uLong LtcUtBenValueStream::PutData( const void* /*pData*/, sal_uLong nSize ) { /* Because we only support IMPORT filter, PutData implementation is ignored It won't bring negative influence to read-only stream object */ @@ -111,7 +111,7 @@ ULONG LtcUtBenValueStream::PutData( const void* /*pData*/, ULONG nSize ) * @param position in value stream * @return current position in value stream */ - ULONG LtcUtBenValueStream::SeekPos( ULONG nPos ) + sal_uLong LtcUtBenValueStream::SeekPos( sal_uLong nPos ) { if (nPos <= m_ulValueLength) cCurrentPosition = nPos; @@ -125,7 +125,7 @@ ULONG LtcUtBenValueStream::PutData( const void* /*pData*/, ULONG nSize ) * @param size of buffer * @return */ - void LtcUtBenValueStream::SetSize( ULONG /*nSize*/ ) + void LtcUtBenValueStream::SetSize( sal_uLong /*nSize*/ ) { //pLtcBenContainer pContainer = cpValue->GetContainer(); //pContainer->GetStream()->SetStreamSize(nSize); |