summaryrefslogtreecommitdiff
path: root/editeng/source/rtf
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-02-26 09:42:43 +0200
committerNoel Grandin <noel@peralex.com>2014-02-27 12:30:28 +0200
commit706fee2fa732d15ed60d83b82cd6de89b8f3e531 (patch)
treea446af5236c28dafb588811cd6212a495540cfd8 /editeng/source/rtf
parent2a4a74a49913ffd42315e2e34c8d58594cebbb95 (diff)
editeng: sal_Bool->bool
Change-Id: I69c210b79f4d1b64863ac0ab2b012f033f40fe10
Diffstat (limited to 'editeng/source/rtf')
-rw-r--r--editeng/source/rtf/rtfitem.cxx16
-rw-r--r--editeng/source/rtf/svxrtf.cxx56
2 files changed, 36 insertions, 36 deletions
diff --git a/editeng/source/rtf/rtfitem.cxx b/editeng/source/rtf/rtfitem.cxx
index 69c273437806..37a5b5b5bd3f 100644
--- a/editeng/source/rtf/rtfitem.cxx
+++ b/editeng/source/rtf/rtfitem.cxx
@@ -213,7 +213,7 @@ void SvxRTFParser::ReadAttr( int nToken, SfxItemSet* pSet )
FontUnderline eUnderline;
FontUnderline eOverline;
FontEmphasisMark eEmphasis;
- bPardTokenRead = sal_False;
+ bPardTokenRead = false;
RTF_CharTypeDef eCharType = NOTDEF_CHARTYPE;
sal_uInt16 nFontAlign;
@@ -227,7 +227,7 @@ void SvxRTFParser::ReadAttr( int nToken, SfxItemSet* pSet )
RTFPardPlain( sal_True, &pSet );
ResetPard();
nStyleNo = 0;
- bPardTokenRead = sal_True;
+ bPardTokenRead = true;
break;
case RTF_PLAIN:
@@ -987,10 +987,10 @@ ATTR_SETOVERLINE:
break;
case RTF_RTLCH:
- bIsLeftToRightDef = sal_False;
+ bIsLeftToRightDef = false;
break;
case RTF_LTRCH:
- bIsLeftToRightDef = sal_True;
+ bIsLeftToRightDef = true;
break;
case RTF_RTLPAR:
if (PARDID->nDirection)
@@ -1821,10 +1821,10 @@ void SvxRTFParser::SetDefault( int nToken, int nValue )
SfxItemSet aTmp( *pAttrPool, &aWhichMap[0] );
sal_Bool bOldFlag = bIsLeftToRightDef;
- bIsLeftToRightDef = sal_True;
+ bIsLeftToRightDef = true;
switch( nToken )
{
- case RTF_ADEFF: bIsLeftToRightDef = sal_False; // no break!
+ case RTF_ADEFF: bIsLeftToRightDef = false; // no break!
case RTF_DEFF:
{
if( -1 == nValue )
@@ -1838,7 +1838,7 @@ void SvxRTFParser::SetDefault( int nToken, int nValue )
}
break;
- case RTF_ADEFLANG: bIsLeftToRightDef = sal_False; // no break!
+ case RTF_ADEFLANG: bIsLeftToRightDef = false; // no break!
case RTF_DEFLANG:
// store default Language
if( -1 != nValue )
@@ -1853,7 +1853,7 @@ void SvxRTFParser::SetDefault( int nToken, int nValue )
if( PARDID->nTabStop )
{
// RTF defines 720 twips as default
- bIsSetDfltTab = sal_True;
+ bIsSetDfltTab = true;
if( -1 == nValue || !nValue )
nValue = 720;
diff --git a/editeng/source/rtf/svxrtf.cxx b/editeng/source/rtf/svxrtf.cxx
index 88ac6ba958ca..f1c6310261c2 100644
--- a/editeng/source/rtf/svxrtf.cxx
+++ b/editeng/source/rtf/svxrtf.cxx
@@ -70,14 +70,14 @@ SvxRTFParser::SvxRTFParser( SfxItemPool& rPool, SvStream& rIn,
, nVersionNo( 0 )
, nDfltFont( 0)
, bNewDoc( bReadNewDoc )
- , bNewGroup( sal_False)
- , bIsSetDfltTab( sal_False)
- , bChkStyleAttr( sal_False )
- , bCalcValue( sal_False )
- , bPardTokenRead( sal_False)
- , bReadDocInfo( sal_False )
- , bIsLeftToRightDef( sal_True)
- , bIsInReadStyleTab( sal_False)
+ , bNewGroup( false)
+ , bIsSetDfltTab( false)
+ , bChkStyleAttr( false )
+ , bCalcValue( false )
+ , bPardTokenRead( false)
+ , bReadDocInfo( false )
+ , bIsLeftToRightDef( true)
+ , bIsInReadStyleTab( false)
{
{
@@ -143,8 +143,8 @@ SvParserState SvxRTFParser::CallParser()
if( !aAttrStack.empty() )
ClearAttrStack();
- bIsSetDfltTab = sal_False;
- bNewGroup = sal_False;
+ bIsSetDfltTab = false;
+ bNewGroup = false;
nDfltFont = 0;
sBaseURL = "";
@@ -321,14 +321,14 @@ INSINGLECHAR:
void SvxRTFParser::ReadStyleTable()
{
- int nToken, bSaveChkStyleAttr = bChkStyleAttr;
+ int nToken, bSaveChkStyleAttr = bChkStyleAttr ? 1 : 0;
sal_uInt16 nStyleNo = 0;
int _nOpenBrakets = 1; // the first was already detected earlier!!
SvxRTFStyleType* pStyle = new SvxRTFStyleType( *pAttrPool, &aWhichMap[0] );
pStyle->aAttrSet.Put( GetRTFDefaults() );
- bIsInReadStyleTab = sal_True;
- bChkStyleAttr = sal_False; // Do not check Attribute against the Styles
+ bIsInReadStyleTab = true;
+ bChkStyleAttr = false; // Do not check Attribute against the Styles
while( _nOpenBrakets && IsParserWorking() )
{
@@ -359,13 +359,13 @@ void SvxRTFParser::ReadStyleTable()
}
break;
- case RTF_SBASEDON: pStyle->nBasedOn = sal_uInt16(nTokenValue); pStyle->bBasedOnIsSet=sal_True; break;
+ case RTF_SBASEDON: pStyle->nBasedOn = sal_uInt16(nTokenValue); pStyle->bBasedOnIsSet=true; break;
case RTF_SNEXT: pStyle->nNext = sal_uInt16(nTokenValue); break;
case RTF_OUTLINELEVEL:
case RTF_SOUTLVL: pStyle->nOutlineNo = sal_uInt8(nTokenValue); break;
case RTF_S: nStyleNo = (short)nTokenValue; break;
case RTF_CS: nStyleNo = (short)nTokenValue;
- pStyle->bIsCharFmt = sal_True;
+ pStyle->bIsCharFmt = true;
break;
case RTF_TEXTTOKEN:
@@ -415,7 +415,7 @@ void SvxRTFParser::ReadStyleTable()
// Flag back to old state
bChkStyleAttr = bSaveChkStyleAttr;
- bIsInReadStyleTab = sal_False;
+ bIsInReadStyleTab = false;
}
void SvxRTFParser::ReadColorTable()
@@ -468,7 +468,7 @@ void SvxRTFParser::ReadFontTable()
Font* pFont = new Font();
short nFontNo(0), nInsFontNo (0);
OUString sAltNm, sFntNm;
- sal_Bool bIsAltFntNm = sal_False, bCheckNewFont;
+ bool bIsAltFntNm = false, bCheckNewFont;
rtl_TextEncoding nSystemChar = lcl_GetDefaultTextEncodingForRTF();
pFont->SetCharSet( nSystemChar );
@@ -476,16 +476,16 @@ void SvxRTFParser::ReadFontTable()
while( _nOpenBrakets && IsParserWorking() )
{
- bCheckNewFont = sal_False;
+ bCheckNewFont = false;
switch( ( nToken = GetNextToken() ))
{
case '}':
- bIsAltFntNm = sal_False;
+ bIsAltFntNm = false;
// Style has been completely read,
// so this is still a stable status
if( --_nOpenBrakets <= 1 && IsParserWorking() )
SaveState( RTF_FONTTBL );
- bCheckNewFont = sal_True;
+ bCheckNewFont = true;
nInsFontNo = nFontNo;
break;
case '{':
@@ -555,12 +555,12 @@ void SvxRTFParser::ReadFontTable()
}
break;
case RTF_F:
- bCheckNewFont = sal_True;
+ bCheckNewFont = true;
nInsFontNo = nFontNo;
nFontNo = (short)nTokenValue;
break;
case RTF_FALT:
- bIsAltFntNm = sal_True;
+ bIsAltFntNm = true;
break;
case RTF_TEXTTOKEN:
DelCharAtEnd( aToken, ';' );
@@ -648,7 +648,7 @@ OUString& SvxRTFParser::GetTextToEndGroup( OUString& rStr )
util::DateTime SvxRTFParser::GetDateTimeStamp( )
{
util::DateTime aDT;
- sal_Bool bContinue = sal_True;
+ bool bContinue = true;
while( bContinue && IsParserWorking() )
{
@@ -661,7 +661,7 @@ util::DateTime SvxRTFParser::GetDateTimeStamp( )
case RTF_HR: aDT.Hours = (sal_uInt16)nTokenValue; break;
case RTF_MIN: aDT.Minutes = (sal_uInt16)nTokenValue; break;
default:
- bContinue = sal_False;
+ bContinue = false;
}
}
SkipToken( -1 ); // the closing brace is evaluated "above"
@@ -844,7 +844,7 @@ SvxRTFItemStackType* SvxRTFParser::_GetAttrSet( int bCopyAttr )
pNew->SetRTFDefaults( GetRTFDefaults() );
aAttrStack.push_back( pNew );
- bNewGroup = sal_False;
+ bNewGroup = false;
return pNew;
}
@@ -1064,7 +1064,7 @@ void SvxRTFParser::AttrGroupEnd() // process the current, delete from Stack
if( pOld )
delete pOld;
- bNewGroup = sal_False;
+ bNewGroup = false;
}
}
@@ -1149,9 +1149,9 @@ SvxRTFStyleType::SvxRTFStyleType( SfxItemPool& rPool, const sal_uInt16* pWhichRa
{
nOutlineNo = sal_uInt8(-1); // not set
nBasedOn = 0;
- bBasedOnIsSet = sal_False; //$flr #117411#
+ bBasedOnIsSet = false; //$flr #117411#
nNext = 0;
- bIsCharFmt = sal_False;
+ bIsCharFmt = false;
}