summaryrefslogtreecommitdiffstats
path: root/filter
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-09-25 06:07:13 +0200
committerNoel Grandin <noel@peralex.com>2014-09-26 15:26:19 +0200
commitbec72dd34f8aa7419c6159bdf02c5ba34a6228a8 (patch)
tree32ebd14ed7c8d0dcfeebda1040dd785183f912ef /filter
parentremove pointless comments (diff)
downloadcore-bec72dd34f8aa7419c6159bdf02c5ba34a6228a8.tar.gz
core-bec72dd34f8aa7419c6159bdf02c5ba34a6228a8.zip
remove unnecessary casts in calls to SvStream.WriteUChar
left over from our conversion of the SvStream output operators to more specific methods Change-Id: I2ea4c7d97e745b3e6a3834f41ac7bfefa4883c7a
Diffstat (limited to 'filter')
-rw-r--r--filter/source/flash/swfwriter2.cxx18
-rw-r--r--filter/source/graphicfilter/egif/egif.cxx42
-rw-r--r--filter/source/graphicfilter/egif/giflzwc.cxx4
-rw-r--r--filter/source/graphicfilter/eos2met/eos2met.cxx250
-rw-r--r--filter/source/graphicfilter/epbm/epbm.cxx12
-rw-r--r--filter/source/graphicfilter/epgm/epgm.cxx24
-rw-r--r--filter/source/graphicfilter/epict/epict.cxx26
-rw-r--r--filter/source/graphicfilter/eppm/eppm.cxx24
-rw-r--r--filter/source/graphicfilter/eps/eps.cxx36
-rw-r--r--filter/source/graphicfilter/eras/eras.cxx10
-rw-r--r--filter/source/graphicfilter/etiff/etiff.cxx4
-rw-r--r--filter/source/graphicfilter/expm/expm.cxx16
-rw-r--r--filter/source/msfilter/escherex.cxx8
13 files changed, 237 insertions, 237 deletions
diff --git a/filter/source/flash/swfwriter2.cxx b/filter/source/flash/swfwriter2.cxx
index b11512aacaa0..0e6110c96a60 100644
--- a/filter/source/flash/swfwriter2.cxx
+++ b/filter/source/flash/swfwriter2.cxx
@@ -153,20 +153,20 @@ void Tag::write( SvStream &out )
sal_uInt16 nCode = ( mnTagId << 6 ) | ( bLarge ? 0x3f : _uInt16(nSz) );
- out.WriteUChar( (sal_uInt8)nCode );
- out.WriteUChar( (sal_uInt8)(nCode >> 8) );
+ out.WriteUChar( nCode );
+ out.WriteUChar( (nCode >> 8) );
if( bLarge )
{
sal_uInt32 nTmp = nSz;
- out.WriteUChar( (sal_uInt8)nTmp );
+ out.WriteUChar( nTmp );
nTmp >>= 8;
- out.WriteUChar( (sal_uInt8)nTmp );
+ out.WriteUChar( nTmp );
nTmp >>= 8;
- out.WriteUChar( (sal_uInt8)nTmp );
+ out.WriteUChar( nTmp );
nTmp >>= 8;
- out.WriteUChar( (sal_uInt8)nTmp );
+ out.WriteUChar( nTmp );
}
}
@@ -198,15 +198,15 @@ void Tag::addI16( sal_Int16 nValue )
void Tag::addUI16( sal_uInt16 nValue )
{
- WriteUChar( (sal_uInt8)nValue );
- WriteUChar( (sal_uInt8)(nValue >> 8) );
+ WriteUChar( nValue );
+ WriteUChar( (nValue >> 8) );
}
void Tag::addUI8( sal_uInt8 nValue )
{
- WriteUChar( (sal_uInt8)nValue );
+ WriteUChar( nValue );
}
diff --git a/filter/source/graphicfilter/egif/egif.cxx b/filter/source/graphicfilter/egif/egif.cxx
index fff040548a79..0dd214800265 100644
--- a/filter/source/graphicfilter/egif/egif.cxx
+++ b/filter/source/graphicfilter/egif/egif.cxx
@@ -316,8 +316,8 @@ void GIFWriter::WriteGlobalHeader( const Size& rSize )
m_rGIF.WriteUInt16( nWidth );
m_rGIF.WriteUInt16( nHeight );
m_rGIF.WriteUChar( cFlags );
- m_rGIF.WriteUChar( (sal_uInt8) 0x00 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x00 );
+ m_rGIF.WriteUChar( 0x00 );
+ m_rGIF.WriteUChar( 0x00 );
// write dummy palette with two entries (black/white);
// we do this only because of a bug in Photoshop, since those can't
@@ -352,15 +352,15 @@ void GIFWriter::WriteLoopExtension( const Animation& rAnimation )
const sal_uInt8 cLoByte = (const sal_uInt8) nLoopCount;
const sal_uInt8 cHiByte = (const sal_uInt8) ( nLoopCount >> 8 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x21 );
- m_rGIF.WriteUChar( (sal_uInt8) 0xff );
- m_rGIF.WriteUChar( (sal_uInt8) 0x0b );
+ m_rGIF.WriteUChar( 0x21 );
+ m_rGIF.WriteUChar( 0xff );
+ m_rGIF.WriteUChar( 0x0b );
m_rGIF.Write( "NETSCAPE2.0", 11 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x03 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x01 );
+ m_rGIF.WriteUChar( 0x03 );
+ m_rGIF.WriteUChar( 0x01 );
m_rGIF.WriteUChar( cLoByte );
m_rGIF.WriteUChar( cHiByte );
- m_rGIF.WriteUChar( (sal_uInt8) 0x00 );
+ m_rGIF.WriteUChar( 0x00 );
}
}
@@ -371,15 +371,15 @@ void GIFWriter::WriteLogSizeExtension( const Size& rSize100 )
// writer PrefSize in 100th-mm as ApplicationExtension
if( rSize100.Width() && rSize100.Height() )
{
- m_rGIF.WriteUChar( (sal_uInt8) 0x21 );
- m_rGIF.WriteUChar( (sal_uInt8) 0xff );
- m_rGIF.WriteUChar( (sal_uInt8) 0x0b );
+ m_rGIF.WriteUChar( 0x21 );
+ m_rGIF.WriteUChar( 0xff );
+ m_rGIF.WriteUChar( 0x0b );
m_rGIF.Write( "STARDIV 5.0", 11 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x09 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x01 );
+ m_rGIF.WriteUChar( 0x09 );
+ m_rGIF.WriteUChar( 0x01 );
m_rGIF.WriteUInt32( (sal_uInt32) rSize100.Width() );
m_rGIF.WriteUInt32( (sal_uInt32) rSize100.Height() );
- m_rGIF.WriteUChar( (sal_uInt8) 0x00 );
+ m_rGIF.WriteUChar( 0x00 );
}
}
@@ -402,13 +402,13 @@ void GIFWriter::WriteImageExtension( long nTimer, Disposal eDisposal )
else if( eDisposal == DISPOSE_PREVIOUS )
cFlags |= ( 3 << 2 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x21 );
- m_rGIF.WriteUChar( (sal_uInt8) 0xf9 );
- m_rGIF.WriteUChar( (sal_uInt8) 0x04 );
+ m_rGIF.WriteUChar( 0x21 );
+ m_rGIF.WriteUChar( 0xf9 );
+ m_rGIF.WriteUChar( 0x04 );
m_rGIF.WriteUChar( cFlags );
m_rGIF.WriteUInt16( nDelay );
- m_rGIF.WriteUChar( (sal_uInt8) m_pAcc->GetBestPaletteIndex( BMP_COL_TRANS ) );
- m_rGIF.WriteUChar( (sal_uInt8) 0x00 );
+ m_rGIF.WriteUChar( m_pAcc->GetBestPaletteIndex( BMP_COL_TRANS ) );
+ m_rGIF.WriteUChar( 0x00 );
if( m_rGIF.GetError() )
bStatus = false;
@@ -435,7 +435,7 @@ void GIFWriter::WriteLocalHeader()
cFlags |= 0x80;
// alles rausschreiben
- m_rGIF.WriteUChar( (sal_uInt8) 0x2c );
+ m_rGIF.WriteUChar( 0x2c );
m_rGIF.WriteUInt16( nPosX );
m_rGIF.WriteUInt16( nPosY );
m_rGIF.WriteUInt16( nWidth );
@@ -553,7 +553,7 @@ void GIFWriter::WriteTerminator()
{
if( bStatus )
{
- m_rGIF.WriteUChar( (sal_uInt8) 0x3b );
+ m_rGIF.WriteUChar( 0x3b );
if( m_rGIF.GetError() )
bStatus = false;
diff --git a/filter/source/graphicfilter/egif/giflzwc.cxx b/filter/source/graphicfilter/egif/giflzwc.cxx
index c686a6dfe91e..49d996a61fdb 100644
--- a/filter/source/graphicfilter/egif/giflzwc.cxx
+++ b/filter/source/graphicfilter/egif/giflzwc.cxx
@@ -92,7 +92,7 @@ GIFImageDataOutputStream::~GIFImageDataOutputStream()
WriteBits(0,7);
FlushBitsBufsFullBytes();
FlushBlockBuf();
- rStream.WriteUChar( (sal_uInt8)0 );
+ rStream.WriteUChar( 0 );
delete[] pBlockBuf;
}
@@ -102,7 +102,7 @@ void GIFImageDataOutputStream::FlushBlockBuf()
{
if( nBlockBufSize )
{
- rStream.WriteUChar( (sal_uInt8) nBlockBufSize );
+ rStream.WriteUChar( nBlockBufSize );
rStream.Write( pBlockBuf,nBlockBufSize );
nBlockBufSize = 0;
}
diff --git a/filter/source/graphicfilter/eos2met/eos2met.cxx b/filter/source/graphicfilter/eos2met/eos2met.cxx
index dac8c3176b82..a0d91f8b490e 100644
--- a/filter/source/graphicfilter/eos2met/eos2met.cxx
+++ b/filter/source/graphicfilter/eos2met/eos2met.cxx
@@ -302,8 +302,8 @@ void METWriter::WriteClipRect( const Rectangle& rRect )
METEndPath();
}
WillWriteOrder(8);
- pMET->WriteUChar( (sal_uInt8)0xb4 ).WriteUChar( (sal_uInt8)6 )
- .WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0 ).WriteUInt32( nPathId );
+ pMET->WriteUChar( 0xb4 ).WriteUChar( 6 )
+ .WriteUChar( 0x00 ).WriteUChar( 0 ).WriteUInt32( nPathId );
}
void METWriter::CountActionsAndBitmaps(const GDIMetaFile * pMTF)
@@ -343,7 +343,7 @@ void METWriter::CountActionsAndBitmaps(const GDIMetaFile * pMTF)
void METWriter::WriteBigEndianShort(sal_uInt16 nWord)
{
- pMET->WriteUChar( (sal_uInt8)(nWord>>8) ).WriteUChar( (sal_uInt8)(nWord&0x00ff) );
+ pMET->WriteUChar( (nWord>>8) ).WriteUChar( (nWord&0x00ff) );
}
@@ -368,7 +368,7 @@ void METWriter::WriteFieldIntroducer(sal_uInt16 nFieldSize, sal_uInt16 nFieldTyp
{
nActualFieldStartPos=pMET->Tell();
WriteBigEndianShort(nFieldSize);
- pMET->WriteUChar( (sal_uInt8)0xd3 ).WriteUInt16( nFieldType ).WriteUChar( nFlags ).WriteUInt16( nSegSeqNum );
+ pMET->WriteUChar( 0xd3 ).WriteUInt16( nFieldType ).WriteUChar( nFlags ).WriteUInt16( nSegSeqNum );
}
@@ -465,13 +465,13 @@ void METWriter::WriteChrSets()
WriteBigEndianShort(0x0050);
- pMET->WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x84 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0xa4 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x01 );
- pMET->WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x0c ).WriteUChar( 0x02 ).WriteUChar( 0x84 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0xa4 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x01 );
+ pMET->WriteUChar( 0x01 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
- pMET->WriteUChar( (sal_uInt8)0x04 ).WriteUChar( (sal_uInt8)0x24 ).WriteUChar( (sal_uInt8)0x05 ).WriteUChar( (sal_uInt8)pCS->nSet );
+ pMET->WriteUChar( 0x04 ).WriteUChar( 0x24 ).WriteUChar( 0x05 ).WriteUChar( pCS->nSet );
- pMET->WriteUChar( (sal_uInt8)0x14 ).WriteUChar( (sal_uInt8)0x1f );
+ pMET->WriteUChar( 0x14 ).WriteUChar( 0x1f );
switch (pCS->eWeight)
{
case WEIGHT_THIN: nbyte=1; break;
@@ -486,16 +486,16 @@ void METWriter::WriteChrSets()
default: nbyte=5;
}
pMET->WriteUChar( nbyte );
- pMET->WriteUChar( (sal_uInt8)0x05 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x0c );
+ pMET->WriteUChar( 0x05 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x0c );
- pMET->WriteUChar( (sal_uInt8)0x06 ).WriteUChar( (sal_uInt8)0x20 ).WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0xd4 );
- pMET->WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x52 );
+ pMET->WriteUChar( 0x06 ).WriteUChar( 0x20 ).WriteUChar( 0x03 ).WriteUChar( 0xd4 );
+ pMET->WriteUChar( 0x03 ).WriteUChar( 0x52 );
- pMET->WriteUChar( (sal_uInt8)0x24 ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x08 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x24 ).WriteUChar( 0x02 ).WriteUChar( 0x08 ).WriteUChar( 0x00 );
OString n(OUStringToOString(pCS->aName,
osl_getThreadTextEncoding()));
for (i=0; i<32; i++)
@@ -520,7 +520,7 @@ void METWriter::WriteColorAttributeTable(sal_uInt32 nFieldId, BitmapPalette* pPa
//--- The Field 'Color Attribute Table':
WriteFieldIntroducer(0,BlkColAtrMagic,0,0);
- pMET->WriteUChar( nBasePartFlags ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( nBasePartLCTID ); // 'Base Part'
+ pMET->WriteUChar( nBasePartFlags ).WriteUChar( 0x00 ).WriteUChar( nBasePartLCTID ); // 'Base Part'
if (pPalette!=NULL)
{
nIndex=0;
@@ -528,18 +528,18 @@ void METWriter::WriteColorAttributeTable(sal_uInt32 nFieldId, BitmapPalette* pPa
{
nNumI=pPalette->GetEntryCount()-nIndex;
if (nNumI>81) nNumI=81;
- pMET->WriteUChar( (sal_uInt8)(11+nNumI*3) ); // length of the parameter
- pMET->WriteUChar( (sal_uInt8)1 ).WriteUChar( (sal_uInt8)0 ).WriteUChar( (sal_uInt8)1 ); // typ: element list, Reserved, Format: RGB
- pMET->WriteUChar( (sal_uInt8)0 ); WriteBigEndianShort(nIndex); // start-Index (3 Bytes)
- pMET->WriteUChar( (sal_uInt8)8 ).WriteUChar( (sal_uInt8)8 ).WriteUChar( (sal_uInt8)8 ); // Bits per component R,G,B
- pMET->WriteUChar( (sal_uInt8)3 ); // number of bytes per entry
+ pMET->WriteUChar( (11+nNumI*3) ); // length of the parameter
+ pMET->WriteUChar( 1 ).WriteUChar( 0 ).WriteUChar( 1 ); // typ: element list, Reserved, Format: RGB
+ pMET->WriteUChar( 0 ); WriteBigEndianShort(nIndex); // start-Index (3 Bytes)
+ pMET->WriteUChar( 8 ).WriteUChar( 8 ).WriteUChar( 8 ); // Bits per component R,G,B
+ pMET->WriteUChar( 3 ); // number of bytes per entry
for (i=0; i<nNumI; i++)
{
const BitmapColor& rCol = (*pPalette)[ nIndex ];
- pMET->WriteUChar( (sal_uInt8) rCol.GetRed() );
- pMET->WriteUChar( (sal_uInt8) rCol.GetGreen() );
- pMET->WriteUChar( (sal_uInt8) rCol.GetBlue() );
+ pMET->WriteUChar( rCol.GetRed() );
+ pMET->WriteUChar( rCol.GetGreen() );
+ pMET->WriteUChar( rCol.GetBlue() );
nIndex++;
}
}
@@ -547,8 +547,8 @@ void METWriter::WriteColorAttributeTable(sal_uInt32 nFieldId, BitmapPalette* pPa
else
{
// 'Trible Generating'
- pMET->WriteUChar( (sal_uInt8)0x0a ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x08 ).WriteUChar( (sal_uInt8)0x08 ).WriteUChar( (sal_uInt8)0x08 );
+ pMET->WriteUChar( 0x0a ).WriteUChar( 0x02 ).WriteUChar( 0x00 ).WriteUChar( 0x01 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x08 ).WriteUChar( 0x08 ).WriteUChar( 0x08 );
}
UpdateFieldSize();
@@ -626,9 +626,9 @@ void METWriter::WriteImageObject(const Bitmap & rBitmap)
//--- The Field 'Map Color Attribute Table':
WriteFieldIntroducer(26,MapColAtrMagic,0,0);
WriteBigEndianShort(0x0012);
- pMET->WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x84 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x0c ).WriteUChar( 0x02 ).WriteUChar( 0x84 ).WriteUChar( 0x00 );
WriteFieldId(nActColMapId);
- pMET->WriteUChar( (sal_uInt8)0x04 ).WriteUChar( (sal_uInt8)0x24 ).WriteUChar( (sal_uInt8)0x07 ).WriteUChar( (sal_uInt8)0x01 );
+ pMET->WriteUChar( 0x04 ).WriteUChar( 0x24 ).WriteUChar( 0x07 ).WriteUChar( 0x01 );
//--- The Field 'End Object Environment Group':
WriteFieldIntroducer(16,EndObjEnvMagic,0,0);
@@ -637,7 +637,7 @@ void METWriter::WriteImageObject(const Bitmap & rBitmap)
//--- The Field 'Image Data Descriptor':
WriteFieldIntroducer(17,DscImgObjMagic,0,0);
- pMET->WriteUChar( (sal_uInt8)0x01 ); // Unit of measure: tens of centimeters
+ pMET->WriteUChar( 0x01 ); // Unit of measure: tens of centimeters
WriteBigEndianShort((sal_uInt16)nResX);
WriteBigEndianShort((sal_uInt16)nResY);
WriteBigEndianShort((sal_uInt16)nWidth);
@@ -647,32 +647,32 @@ void METWriter::WriteImageObject(const Bitmap & rBitmap)
WriteFieldIntroducer(0,DatImgObjMagic,0,0);
// Begin Segment:
- pMET->WriteUChar( (sal_uInt8)0x70 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x70 ).WriteUChar( 0x00 );
// Begin Image Content:
- pMET->WriteUChar( (sal_uInt8)0x91 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0xff );
+ pMET->WriteUChar( 0x91 ).WriteUChar( 0x01 ).WriteUChar( 0xff );
// Image Size:
- pMET->WriteUChar( (sal_uInt8)0x94 ).WriteUChar( (sal_uInt8)0x09 ).WriteUChar( (sal_uInt8)0x02 );
+ pMET->WriteUChar( 0x94 ).WriteUChar( 0x09 ).WriteUChar( 0x02 );
pMET->WriteUInt16( (sal_uInt16) 0 ).WriteUInt16( (sal_uInt16) 0 );
WriteBigEndianShort((sal_uInt16)nHeight);
WriteBigEndianShort((sal_uInt16)nWidth);
// Image Encoding:
- pMET->WriteUChar( (sal_uInt8)0x95 ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x03 );
+ pMET->WriteUChar( 0x95 ).WriteUChar( 0x02 ).WriteUChar( 0x03 ).WriteUChar( 0x03 );
// Image IDE-Size:
- pMET->WriteUChar( (sal_uInt8)0x96 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)nBitsPerPixel );
+ pMET->WriteUChar( 0x96 ).WriteUChar( 0x01 ).WriteUChar( nBitsPerPixel );
if (nBitsPerPixel<=8) {
// Image LUT-ID
- pMET->WriteUChar( (sal_uInt8)0x97 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0x01 );
+ pMET->WriteUChar( 0x97 ).WriteUChar( 0x01 ).WriteUChar( 0x01 );
}
else {
// IDE Structure
- pMET->WriteUChar( (sal_uInt8)0x9b ).WriteUChar( (sal_uInt8)0x08 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x01 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x08 );
- pMET->WriteUChar( (sal_uInt8)0x08 ).WriteUChar( (sal_uInt8)0x08 );
+ pMET->WriteUChar( 0x9b ).WriteUChar( 0x08 ).WriteUChar( 0x00 ).WriteUChar( 0x01 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x08 );
+ pMET->WriteUChar( 0x08 ).WriteUChar( 0x08 );
}
boost::scoped_array<sal_uInt8> pBuf(new sal_uInt8[nBytesPerLine]);
@@ -709,10 +709,10 @@ void METWriter::WriteImageObject(const Bitmap & rBitmap)
pBuf.reset();
// End Image Content:
- pMET->WriteUChar( (sal_uInt8)0x93 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x93 ).WriteUChar( 0x00 );
// End Segment:
- pMET->WriteUChar( (sal_uInt8)0x71 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x71 ).WriteUChar( 0x00 );
// finalize the last field 'Image Picture Data':
UpdateFieldSize();
@@ -839,9 +839,9 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// 8 Coordinate types in data
// 0x04Intel16
// 0x05Intel32
- pMET->WriteUChar( (sal_uInt8)0xf7 ).WriteUChar( (sal_uInt8)0x07 ).WriteUChar( (sal_uInt8)0xb0 ).WriteUChar( (sal_uInt8)0x00 )
- .WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x23 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0x01 )
- .WriteUChar( (sal_uInt8)0x05 );
+ pMET->WriteUChar( 0xf7 ).WriteUChar( 0x07 ).WriteUChar( 0xb0 ).WriteUChar( 0x00 )
+ .WriteUChar( 0x00 ).WriteUChar( 0x23 ).WriteUChar( 0x01 ).WriteUChar( 0x01 )
+ .WriteUChar( 0x05 );
// 0 0xF6 Set Picture Descriptor
// 1 Length of following data
@@ -871,8 +871,8 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// GPS Y bottom, Y top
// GPS Z near, Z far
Size aUnitsPerDecimeter=OutputDevice::LogicToLogic(Size(10,10),MapMode(MAP_CM),aPictureMapMode);
- pMET->WriteUChar( (sal_uInt8)0xf6 ).WriteUChar( (sal_uInt8)0x28 ).WriteUChar( (sal_uInt8)0x40 ).WriteUChar( (sal_uInt8)0x00 )
- .WriteUChar( (sal_uInt8)0x05 ).WriteUChar( (sal_uInt8)0x01 )
+ pMET->WriteUChar( 0xf6 ).WriteUChar( 0x28 ).WriteUChar( 0x40 ).WriteUChar( 0x00 )
+ .WriteUChar( 0x05 ).WriteUChar( 0x01 )
.WriteUInt32( (sal_uInt32)(aUnitsPerDecimeter.Width()) )
.WriteUInt32( (sal_uInt32)(aUnitsPerDecimeter.Height()) )
.WriteUInt32( (sal_uInt32)0 )
@@ -893,9 +893,9 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// 8 Geometrics
// 0x04 Intel16
// 0x05 Intel32
- pMET->WriteUChar( (sal_uInt8)0x21 ).WriteUChar( (sal_uInt8)0x07 ).WriteUChar( (sal_uInt8)0x08 ).WriteUChar( (sal_uInt8)0xe0 )
- .WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x8f ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x05 )
- .WriteUChar( (sal_uInt8)0x05 );
+ pMET->WriteUChar( 0x21 ).WriteUChar( 0x07 ).WriteUChar( 0x08 ).WriteUChar( 0xe0 )
+ .WriteUChar( 0x00 ).WriteUChar( 0x8f ).WriteUChar( 0x00 ).WriteUChar( 0x05 )
+ .WriteUChar( 0x05 );
// 0 0x21 Set Current Defaults
// 1 Length of following data
@@ -903,8 +903,8 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// 3-4 Mask 0xCC0C
// 5 Names 0x8F
// 6-n M11, M12, M21, M22, M41, M42 Matrix elements
- pMET->WriteUChar( (sal_uInt8)0x21 ).WriteUChar( (sal_uInt8)0x1c ).WriteUChar( (sal_uInt8)0x07 ).WriteUChar( (sal_uInt8)0xcc )
- .WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x8f )
+ pMET->WriteUChar( 0x21 ).WriteUChar( 0x1c ).WriteUChar( 0x07 ).WriteUChar( 0xcc )
+ .WriteUChar( 0x0c ).WriteUChar( 0x8f )
.WriteUInt32( (sal_uInt32)0x00010000 ).WriteUInt32( (sal_uInt32)0x00000000 ).WriteUInt32( (sal_uInt32)0x00000000 )
.WriteUInt32( (sal_uInt32)0x00010000 ).WriteUInt32( (sal_uInt32)0x00000000 ).WriteUInt32( (sal_uInt32)0x00000000 );
@@ -975,11 +975,11 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// (1 byte) - Character mix
// (1 byte) - Character background mix (G=2 or 4 depending on the Geometrics
// parameter of Set Default Parameter Format)
- pMET->WriteUChar( (sal_uInt8)0x21 ).WriteUChar( (sal_uInt8)0x10 ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x40 )
- .WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x8f )
- .WriteUChar( (sal_uInt8)0xaa ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 )
- .WriteUChar( (sal_uInt8)0x44 ).WriteUChar( (sal_uInt8)0x04 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 )
- .WriteUChar( (sal_uInt8)0xa8 ).WriteUChar( (sal_uInt8)0xaa ).WriteUChar( (sal_uInt8)0x40 ).WriteUChar( (sal_uInt8)0x44 );
+ pMET->WriteUChar( 0x21 ).WriteUChar( 0x10 ).WriteUChar( 0x02 ).WriteUChar( 0x40 )
+ .WriteUChar( 0x00 ).WriteUChar( 0x8f )
+ .WriteUChar( 0xaa ).WriteUChar( 0x02 ).WriteUChar( 0x00 ).WriteUChar( 0x00 )
+ .WriteUChar( 0x44 ).WriteUChar( 0x04 ).WriteUChar( 0x00 ).WriteUChar( 0x00 )
+ .WriteUChar( 0xa8 ).WriteUChar( 0xaa ).WriteUChar( 0x40 ).WriteUChar( 0x44 );
// 0 0x21 Set Current Defaults
// 1 Length of following data
@@ -1009,10 +1009,10 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// (1 byte) - Marker mix
// (1 byte) - Marker background mix (G=2 or 4 depending on the Geometrics
// parameter of Set Default Parameter Format)
- pMET->WriteUChar( (sal_uInt8)0x21 ).WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x40 )
- .WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x8f )
- .WriteUChar( (sal_uInt8)0x66 ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 )
- .WriteUChar( (sal_uInt8)0x66 ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x21 ).WriteUChar( 0x0c ).WriteUChar( 0x03 ).WriteUChar( 0x40 )
+ .WriteUChar( 0x00 ).WriteUChar( 0x8f )
+ .WriteUChar( 0x66 ).WriteUChar( 0x02 ).WriteUChar( 0x00 ).WriteUChar( 0x00 )
+ .WriteUChar( 0x66 ).WriteUChar( 0x02 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
// 0 0x21 Set Current Defaults
// 1 Length of following data
@@ -1121,9 +1121,9 @@ void METWriter::WriteDataDescriptor(const GDIMetaFile *)
// 4-7 Bit-map handle
// 8 Lcid
if (nNumberOfBitmaps>0) {
- pMET->WriteUChar( (sal_uInt8)0xe7 ).WriteUChar( (sal_uInt8)0x07 ).WriteUChar( (sal_uInt8)0x80 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0xe7 ).WriteUChar( 0x07 ).WriteUChar( 0x80 ).WriteUChar( 0x00 );
WriteBigEndianLong(nActBitmapId);
- pMET->WriteUChar( (sal_uInt8)0xfe );
+ pMET->WriteUChar( 0xfe );
}
UpdateFieldSize();
@@ -1152,9 +1152,9 @@ void METWriter::WillWriteOrder(sal_uInt32 nNextOrderMaximumLength)
void METWriter::METBitBlt(Point aPt, Size aSize, const Size& rBmpSizePixel)
{
WillWriteOrder(46);
- pMET->WriteUChar( (sal_uInt8)0xd6 ).WriteUChar( (sal_uInt8)44 ).WriteUInt16( (sal_uInt16)0 ).WriteUInt16( (sal_uInt16) 0x00cc );
+ pMET->WriteUChar( 0xd6 ).WriteUChar( 44 ).WriteUInt16( (sal_uInt16)0 ).WriteUInt16( (sal_uInt16) 0x00cc );
WriteBigEndianLong(nActBitmapId++);
- pMET->WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x02 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
WritePoint(Point(aPt.X(),aPt.Y()+aSize.Height()));
WritePoint(Point(aPt.X()+aSize.Width(),aPt.Y()));
pMET->WriteUInt32( (sal_uInt32)0 ).WriteUInt32( (sal_uInt32)0 )
@@ -1167,10 +1167,10 @@ void METWriter::METSetAndPushLineInfo( const LineInfo& rLineInfo )
sal_Int32 nWidth = OutputDevice::LogicToLogic( Size( rLineInfo.GetWidth(),0 ), aPictureMapMode, aTargetMapMode ).Width();
WillWriteOrder( 8 ); // set stroke linewidth
- pMET ->WriteUChar( (sal_uInt8)0x15 )
- .WriteUChar( (sal_uInt8)6 )
- .WriteUChar( (sal_uInt8)0 ) // Flags
- .WriteUChar( (sal_uInt8)0 )
+ pMET ->WriteUChar( 0x15 )
+ .WriteUChar( 6 )
+ .WriteUChar( 0 ) // Flags
+ .WriteUChar( 0 )
.WriteInt32( nWidth );
if ( rLineInfo.GetStyle() != LINE_SOLID )
@@ -1201,83 +1201,83 @@ void METWriter::METSetAndPushLineInfo( const LineInfo& rLineInfo )
break; // not handled -Wall
}
WillWriteOrder( 2 );
- pMET->WriteUChar( (sal_uInt8)0x18 ).WriteUChar( nStyle ); // set LineType
+ pMET->WriteUChar( 0x18 ).WriteUChar( nStyle ); // set LineType
}
}
void METWriter::METPopLineInfo( const LineInfo& rLineInfo )
{
WillWriteOrder( 8 ); // set stroke linewidth
- pMET ->WriteUChar( (sal_uInt8)0x15 )
- .WriteUChar( (sal_uInt8)6 )
- .WriteUChar( (sal_uInt8)0 ) // Flags
- .WriteUChar( (sal_uInt8)0 )
+ pMET ->WriteUChar( 0x15 )
+ .WriteUChar( 6 )
+ .WriteUChar( 0 ) // Flags
+ .WriteUChar( 0 )
.WriteUInt32( (sal_uInt32)1 );
if ( rLineInfo.GetStyle() != LINE_SOLID )
{
WillWriteOrder( 2 );
- pMET->WriteUChar( (sal_uInt8)0x18 ).WriteUChar( (sal_uInt8)0 ); // set LineType
+ pMET->WriteUChar( 0x18 ).WriteUChar( 0 ); // set LineType
}
}
void METWriter::METBeginArea(bool bBoundaryLine)
{
WillWriteOrder(2);
- pMET->WriteUChar( (sal_uInt8)0x68 );
- if (bBoundaryLine) pMET->WriteUChar( (sal_uInt8)0xc0 );
- else pMET->WriteUChar( (sal_uInt8)0x80 );
+ pMET->WriteUChar( 0x68 );
+ if (bBoundaryLine) pMET->WriteUChar( 0xc0 );
+ else pMET->WriteUChar( 0x80 );
}
void METWriter::METEndArea()
{
WillWriteOrder(2);
- pMET->WriteUChar( (sal_uInt8)0x60 ).WriteUChar( (sal_uInt8)0 );
+ pMET->WriteUChar( 0x60 ).WriteUChar( 0 );
}
void METWriter::METBeginPath(sal_uInt32 nPathId)
{
WillWriteOrder(8);
- pMET->WriteUChar( (sal_uInt8)0xd0 ).WriteUChar( (sal_uInt8)6 ).WriteUInt16( (sal_uInt16) 0 ).WriteUInt32( nPathId );
+ pMET->WriteUChar( 0xd0 ).WriteUChar( 6 ).WriteUInt16( (sal_uInt16) 0 ).WriteUInt32( nPathId );
}
void METWriter::METEndPath()
{
WillWriteOrder(2);
- pMET->WriteUChar( (sal_uInt8)0x7f ).WriteUChar( (sal_uInt8)0 );
+ pMET->WriteUChar( 0x7f ).WriteUChar( 0 );
}
void METWriter::METFillPath(sal_uInt32 nPathId)
{
WillWriteOrder(8);
- pMET->WriteUChar( (sal_uInt8)0xd7 ).WriteUChar( (sal_uInt8)6 )
- .WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0 ).WriteUInt32( nPathId );
+ pMET->WriteUChar( 0xd7 ).WriteUChar( 6 )
+ .WriteUChar( 0x00 ).WriteUChar( 0 ).WriteUInt32( nPathId );
}
void METWriter::METOutlinePath(sal_uInt32 nPathId)
{
WillWriteOrder(8);
- pMET->WriteUChar( (sal_uInt8)0xd4 ).WriteUChar( (sal_uInt8)6 )
- .WriteUChar( (sal_uInt8)0 ).WriteUChar( (sal_uInt8)0 ).WriteUInt32( nPathId );
+ pMET->WriteUChar( 0xd4 ).WriteUChar( 6 )
+ .WriteUChar( 0 ).WriteUChar( 0 ).WriteUInt32( nPathId );
}
void METWriter::METCloseFigure()
{
WillWriteOrder(2);
- pMET->WriteUChar( (sal_uInt8)0x7d ).WriteUChar( (sal_uInt8)0 );
+ pMET->WriteUChar( 0x7d ).WriteUChar( 0 );
}
void METWriter::METMove(Point aPt)
{
WillWriteOrder(10);
- pMET->WriteUChar( (sal_uInt8)0x21 ).WriteUChar( (sal_uInt8)8 );
+ pMET->WriteUChar( 0x21 ).WriteUChar( 8 );
WritePoint(aPt);
}
@@ -1285,7 +1285,7 @@ void METWriter::METMove(Point aPt)
void METWriter::METLine(Point aPt1, Point aPt2)
{
WillWriteOrder(18);
- pMET->WriteUChar( (sal_uInt8)0xc1 ).WriteUChar( (sal_uInt8)16 );
+ pMET->WriteUChar( 0xc1 ).WriteUChar( 16 );
WritePoint(aPt1); WritePoint(aPt2);
}
@@ -1302,13 +1302,13 @@ void METWriter::METLine(const Polygon & rPolygon)
if (nOrderPoints>30) nOrderPoints=30;
WillWriteOrder(nOrderPoints*8+2);
if (bFirstOrder) {
- pMET->WriteUChar( (sal_uInt8)0xc1 ); // Line at given pos
+ pMET->WriteUChar( 0xc1 ); // Line at given pos
bFirstOrder=false;
}
else {
- pMET->WriteUChar( (sal_uInt8)0x81 ); // Line at current pos
+ pMET->WriteUChar( 0x81 ); // Line at current pos
}
- pMET->WriteUChar( (sal_uInt8)(nOrderPoints*8) );
+ pMET->WriteUChar( (nOrderPoints*8) );
for (j=0; j<nOrderPoints; j++) WritePoint(rPolygon.GetPoint(i++));
}
}
@@ -1328,7 +1328,7 @@ void METWriter::METLine(const PolyPolygon & rPolyPolygon)
void METWriter::METLineAtCurPos(Point aPt)
{
WillWriteOrder(10);
- pMET->WriteUChar( (sal_uInt8)0x81 ).WriteUChar( (sal_uInt8)8 );
+ pMET->WriteUChar( 0x81 ).WriteUChar( 8 );
WritePoint(aPt);
}
@@ -1341,7 +1341,7 @@ void METWriter::METBox(bool bFill, bool bBoundary,
if (bBoundary) nFlags|=0x20;
WillWriteOrder(28);
- pMET->WriteUChar( (sal_uInt8)0xc0 ).WriteUChar( (sal_uInt8)26 ).WriteUChar( nFlags ).WriteUChar( (sal_uInt8)0 );
+ pMET->WriteUChar( 0xc0 ).WriteUChar( 26 ).WriteUChar( nFlags ).WriteUChar( 0 );
WritePoint(aRect.BottomLeft());
WritePoint(aRect.TopRight());
pMET->WriteUInt32( nHAxis ).WriteUInt32( nVAxis );
@@ -1351,7 +1351,7 @@ void METWriter::METBox(bool bFill, bool bBoundary,
void METWriter::METFullArc(Point aCenter, double fMultiplier)
{
WillWriteOrder(14);
- pMET->WriteUChar( (sal_uInt8)0xc7 ).WriteUChar( (sal_uInt8)12 );
+ pMET->WriteUChar( 0xc7 ).WriteUChar( 12 );
WritePoint(aCenter);
pMET->WriteInt32( (sal_Int32)(fMultiplier*65536.0+0.5) );
}
@@ -1367,7 +1367,7 @@ void METWriter::METPartialArcAtCurPos(Point aCenter, double fMultiplier,
while (fSweepAngle>360.0) fSweepAngle-=360.0;
while (fSweepAngle<.00) fSweepAngle+=360.0;
WillWriteOrder(22);
- pMET->WriteUChar( (sal_uInt8)0xa3 ).WriteUChar( (sal_uInt8)20 );
+ pMET->WriteUChar( 0xa3 ).WriteUChar( 20 );
WritePoint(aCenter);
pMET->WriteInt32( (sal_Int32)(fMultiplier*65536.0+0.5) );
pMET->WriteInt32( (sal_Int32)(fStartAngle*65536.0+0.5) );
@@ -1381,18 +1381,18 @@ void METWriter::METChrStr( Point aPt, const OUString& aUniStr )
osl_getThreadTextEncoding()));
sal_uInt16 nLen = aStr.getLength();
WillWriteOrder( 11 + nLen );
- pMET->WriteUChar( (sal_uInt8)0xc3 ).WriteUChar( (sal_uInt8)( 9 + nLen ) );
+ pMET->WriteUChar( 0xc3 ).WriteUChar( ( 9 + nLen ) );
WritePoint(aPt);
for (sal_uInt16 i = 0; i < nLen; ++i)
pMET->WriteChar( aStr[i] );
- pMET->WriteUChar( (sal_uInt8)0 );
+ pMET->WriteUChar( 0 );
}
void METWriter::METSetArcParams(sal_Int32 nP, sal_Int32 nQ, sal_Int32 nR, sal_Int32 nS)
{
WillWriteOrder(18);
- pMET->WriteUChar( (sal_uInt8)0x22 ).WriteUChar( (sal_uInt8)16 ).WriteInt32( nP ).WriteInt32( nQ ).WriteInt32( nR ).WriteInt32( nS );
+ pMET->WriteUChar( 0x22 ).WriteUChar( 16 ).WriteInt32( nP ).WriteInt32( nQ ).WriteInt32( nR ).WriteInt32( nS );
}
@@ -1402,10 +1402,10 @@ void METWriter::METSetColor(Color aColor)
aMETColor=aColor;
WillWriteOrder(6);
- pMET->WriteUChar( (sal_uInt8)0xa6 ).WriteUChar( (sal_uInt8)4 ).WriteUChar( (sal_uInt8)0 )
- .WriteUChar( (sal_uInt8)(aColor.GetBlue()) )
- .WriteUChar( (sal_uInt8)(aColor.GetGreen()) )
- .WriteUChar( (sal_uInt8)(aColor.GetRed()) );
+ pMET->WriteUChar( 0xa6 ).WriteUChar( 4 ).WriteUChar( 0 )
+ .WriteUChar( (aColor.GetBlue()) )
+ .WriteUChar( (aColor.GetGreen()) )
+ .WriteUChar( (aColor.GetRed()) );
}
@@ -1415,10 +1415,10 @@ void METWriter::METSetBackgroundColor(Color aColor)
aMETBackgroundColor=aColor;
WillWriteOrder(6);
- pMET->WriteUChar( (sal_uInt8)0xa7 ).WriteUChar( (sal_uInt8)4 ).WriteUChar( (sal_uInt8)0 )
- .WriteUChar( (sal_uInt8)(aColor.GetBlue()) )
- .WriteUChar( (sal_uInt8)(aColor.GetGreen()) )
- .WriteUChar( (sal_uInt8)(aColor.GetRed()) );
+ pMET->WriteUChar( 0xa7 ).WriteUChar( 4 ).WriteUChar( 0 )
+ .WriteUChar( (aColor.GetBlue()) )
+ .WriteUChar( (aColor.GetGreen()) )
+ .WriteUChar( (aColor.GetRed()) );
}
void METWriter::METSetMix(RasterOp eROP)
@@ -1438,7 +1438,7 @@ void METWriter::METSetMix(RasterOp eROP)
}
WillWriteOrder(2);
- pMET->WriteUChar( (sal_uInt8)0x0c ).WriteUChar( nMix );
+ pMET->WriteUChar( 0x0c ).WriteUChar( nMix );
}
@@ -1450,7 +1450,7 @@ void METWriter::METSetChrCellSize(Size aSize)
aMETChrCellSize=aSize;
WillWriteOrder(10);
if (aSize.Width()==0) aSize.Width()=aSize.Height();
- pMET->WriteUChar( (sal_uInt8)0x33 ).WriteUChar( (sal_uInt8)8 ).WriteInt32( (sal_Int32)aSize.Width() ).WriteInt32( (sal_Int32)aSize.Height() );
+ pMET->WriteUChar( 0x33 ).WriteUChar( 8 ).WriteInt32( (sal_Int32)aSize.Width() ).WriteInt32( (sal_Int32)aSize.Height() );
}
@@ -1474,7 +1474,7 @@ void METWriter::METSetChrAngle(short nAngle)
}
WillWriteOrder(10);
- pMET->WriteUChar( (sal_uInt8)0x34 ).WriteUChar( (sal_uInt8)8 ).WriteInt32( nax ).WriteInt32( nay );
+ pMET->WriteUChar( 0x34 ).WriteUChar( 8 ).WriteInt32( nax ).WriteInt32( nay );
}
@@ -1485,7 +1485,7 @@ void METWriter::METSetChrSet(sal_uInt8 nSet)
nMETChrSet=nSet;
WillWriteOrder(2);
- pMET->WriteUChar( (sal_uInt8)0x38 ).WriteUChar( nSet );
+ pMET->WriteUChar( 0x38 ).WriteUChar( nSet );
}
@@ -2348,18 +2348,18 @@ void METWriter::WriteObjectEnvironmentGroup(const GDIMetaFile * pMTF)
//--- The Field 'Map Color Attribute Table':
WriteFieldIntroducer(22,MapColAtrMagic,0,0);
WriteBigEndianShort(0x000e);
- pMET->WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x84 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x0c ).WriteUChar( 0x02 ).WriteUChar( 0x84 ).WriteUChar( 0x00 );
WriteFieldId(4);
//--- The first Field 'Map Coded Font':
WriteFieldIntroducer(32,MapCodFntMagic,0,0);
WriteBigEndianShort(0x0018);
- pMET->WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x84 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0xff ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x04 ).WriteUChar( (sal_uInt8)0x24 ).WriteUChar( (sal_uInt8)0x05 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x06 ).WriteUChar( (sal_uInt8)0x20 );
- pMET->WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x97 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0xb5 );
+ pMET->WriteUChar( 0x0c ).WriteUChar( 0x02 ).WriteUChar( 0x84 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0xff ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x04 ).WriteUChar( 0x24 ).WriteUChar( 0x05 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x06 ).WriteUChar( 0x20 );
+ pMET->WriteUChar( 0x03 ).WriteUChar( 0x97 ).WriteUChar( 0x01 ).WriteUChar( 0xb5 );
//--- The additional Fields 'Map Coded Font':
CreateChrSets(pMTF);
@@ -2371,9 +2371,9 @@ void METWriter::WriteObjectEnvironmentGroup(const GDIMetaFile * pMTF)
{
WriteFieldIntroducer(29,MapDatResMagic,0,0);
WriteBigEndianShort(0x0015);
- pMET->WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x02 ).WriteUChar( (sal_uInt8)0x84 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x0c ).WriteUChar( 0x02 ).WriteUChar( 0x84 ).WriteUChar( 0x00 );
WriteFieldId(nId);
- pMET->WriteUChar( (sal_uInt8)0x07 ).WriteUChar( (sal_uInt8)0x22 ).WriteUChar( (sal_uInt8)0x10 );
+ pMET->WriteUChar( 0x07 ).WriteUChar( 0x22 ).WriteUChar( 0x10 );
pMET->WriteUInt32( (sal_uInt32)nId );
nId++;
}
@@ -2412,8 +2412,8 @@ void METWriter::WriteGraphicsObject(const GDIMetaFile * pMTF)
nNumberOfDataFields++;
// now at first we write the head of the segment:
- pMET->WriteUChar( (sal_uInt8)0x70 ).WriteUChar( (sal_uInt8)0x0e ).WriteUInt32( (sal_uInt32)0 );
- pMET->WriteUChar( (sal_uInt8)0x70 ).WriteUChar( (sal_uInt8)0x10 ); // Flags
+ pMET->WriteUChar( 0x70 ).WriteUChar( 0x0e ).WriteUInt32( (sal_uInt32)0 );
+ pMET->WriteUChar( 0x70 ).WriteUChar( 0x10 ); // Flags
pMET->WriteUInt16( (sal_uInt16)0 ); // Lo-Word of the length of the segment data (Big Endian)
pMET->WriteUInt32( (sal_uInt32)0 ); // Reserved
pMET->WriteUInt16( (sal_uInt16)0 ); // Hi-Word of the length of the segment (Big Endian) (Ohh Ohh OS2)
@@ -2479,10 +2479,10 @@ void METWriter::WriteDocument(const GDIMetaFile * pMTF)
//--- The Field 'Begin Document':
WriteFieldIntroducer(0,BegDocumnMagic,0,0);
WriteFieldId(1);
- pMET->WriteUChar( (sal_uInt8)0x00 ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x05 ).WriteUChar( (sal_uInt8)0x18 ).WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x0c ).WriteUChar( (sal_uInt8)0x00 );
- pMET->WriteUChar( (sal_uInt8)0x06 ).WriteUChar( (sal_uInt8)0x01 ).WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0xd4 ).WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x52 );
- pMET->WriteUChar( (sal_uInt8)0x03 ).WriteUChar( (sal_uInt8)0x65 ).WriteUChar( (sal_uInt8)0x00 );
+ pMET->WriteUChar( 0x00 ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x05 ).WriteUChar( 0x18 ).WriteUChar( 0x03 ).WriteUChar( 0x0c ).WriteUChar( 0x00 );
+ pMET->WriteUChar( 0x06 ).WriteUChar( 0x01 ).WriteUChar( 0x03 ).WriteUChar( 0xd4 ).WriteUChar( 0x03 ).WriteUChar( 0x52 );
+ pMET->WriteUChar( 0x03 ).WriteUChar( 0x65 ).WriteUChar( 0x00 );
UpdateFieldSize();
//--- The Content:
diff --git a/filter/source/graphicfilter/epbm/epbm.cxx b/filter/source/graphicfilter/epbm/epbm.cxx
index f0b575ecb698..5919b9a18382 100644
--- a/filter/source/graphicfilter/epbm/epbm.cxx
+++ b/filter/source/graphicfilter/epbm/epbm.cxx
@@ -128,9 +128,9 @@ bool PBMWriter::ImplWriteHeader()
m_rOStm.WriteCharPtr( "P1\x0a" );
ImplWriteNumber( mnWidth );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( mnHeight );
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
else mbStatus = false;
return mbStatus;
@@ -155,7 +155,7 @@ void PBMWriter::ImplWriteBody()
m_rOStm.WriteUChar( nBYTE );
}
if ( ( x & 7 ) != 0 )
- m_rOStm.WriteUChar( (sal_uInt8)( nBYTE << ( ( x ^ 7 ) + 1 ) ) );
+ m_rOStm.WriteUChar( ( nBYTE << ( ( x ^ 7 ) + 1 ) ) );
}
}
else
@@ -169,11 +169,11 @@ void PBMWriter::ImplWriteBody()
if (!( --nxCount ) )
{
nxCount = 69;
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
- m_rOStm.WriteUChar( (sal_uInt8)( ( mpAcc->GetPixelIndex( y, x ) ^ 1 ) + '0' ) ) ;
+ m_rOStm.WriteUChar( ( ( mpAcc->GetPixelIndex( y, x ) ^ 1 ) + '0' ) ) ;
}
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
}
}
diff --git a/filter/source/graphicfilter/epgm/epgm.cxx b/filter/source/graphicfilter/epgm/epgm.cxx
index c1d31b401069..fcd65b891ed4 100644
--- a/filter/source/graphicfilter/epgm/epgm.cxx
+++ b/filter/source/graphicfilter/epgm/epgm.cxx
@@ -124,11 +124,11 @@ bool PGMWriter::ImplWriteHeader()
m_rOStm.WriteCharPtr( "P2\x0a" );
ImplWriteNumber( mnWidth );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( mnHeight );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( 255 ); // max. gray value
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
else
mbStatus = false;
@@ -161,18 +161,18 @@ void PGMWriter::ImplWriteBody()
if ( nCount < 0 )
{
nCount = 69;
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
nDat = mpAcc->GetPixelIndex( y, x );
nNumb = nDat / 100;
if ( nNumb )
{
- m_rOStm.WriteUChar( (sal_uInt8)( nNumb + '0' ) );
+ m_rOStm.WriteUChar( ( nNumb + '0' ) );
nDat -= ( nNumb * 100 );
nNumb = nDat / 10;
- m_rOStm.WriteUChar( (sal_uInt8)( nNumb + '0' ) );
+ m_rOStm.WriteUChar( ( nNumb + '0' ) );
nDat -= ( nNumb * 10 );
- m_rOStm.WriteUChar( (sal_uInt8)( nDat + '0' ) );
+ m_rOStm.WriteUChar( ( nDat + '0' ) );
nCount -= 4;
}
else
@@ -180,20 +180,20 @@ void PGMWriter::ImplWriteBody()
nNumb = nDat / 10;
if ( nNumb )
{
- m_rOStm.WriteUChar( (sal_uInt8)( nNumb + '0' ) );
+ m_rOStm.WriteUChar( ( nNumb + '0' ) );
nDat -= ( nNumb * 10 );
- m_rOStm.WriteUChar( (sal_uInt8)( nDat + '0' ) );
+ m_rOStm.WriteUChar( ( nDat + '0' ) );
nCount -= 3;
}
else
{
- m_rOStm.WriteUChar( (sal_uInt8)( nDat + '0' ) );
+ m_rOStm.WriteUChar( ( nDat + '0' ) );
nCount -= 2;
}
}
- m_rOStm.WriteUChar( (sal_uInt8)' ' );
+ m_rOStm.WriteUChar( ' ' );
}
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
}
}
diff --git a/filter/source/graphicfilter/epict/epict.cxx b/filter/source/graphicfilter/epict/epict.cxx
index 9a44f45276be..e3606deaa34a 100644
--- a/filter/source/graphicfilter/epict/epict.cxx
+++ b/filter/source/graphicfilter/epict/epict.cxx
@@ -462,7 +462,7 @@ void PictWriter::WriteOpcode_TxFace(const vcl::Font & rFont)
if (rFont.IsShadow()) nFace|=0x10;
if (bDstTxFaceValid==false || nDstTxFace!=nFace) {
- pPict->WriteUInt16( (sal_uInt16)0x0004 ).WriteUChar( nFace ).WriteUChar( (sal_uInt8)0 );
+ pPict->WriteUInt16( (sal_uInt16)0x0004 ).WriteUChar( nFace ).WriteUChar( 0 );
nDstTxFace=nFace;
bDstTxFaceValid=true;
}
@@ -656,20 +656,20 @@ void PictWriter::WriteOpcode_Text(const Point & rPoint, const OUString& rString,
}
else if (dv==0)
{
- pPict->WriteUInt16( (sal_uInt16)0x0029 ).WriteUChar( (sal_uInt8)dh );
+ pPict->WriteUInt16( (sal_uInt16)0x0029 ).WriteUChar( dh );
}
else if (dh==0)
{
- pPict->WriteUInt16( (sal_uInt16)0x002a ).WriteUChar( (sal_uInt8)dv );
+ pPict->WriteUInt16( (sal_uInt16)0x002a ).WriteUChar( dv );
}
else
{
- pPict->WriteUInt16( (sal_uInt16)0x002b ).WriteUChar( (sal_uInt8)dh ).WriteUChar( (sal_uInt8)dv );
+ pPict->WriteUInt16( (sal_uInt16)0x002b ).WriteUChar( dh ).WriteUChar( dv );
}
WriteString( rString );
if (((pPict->Tell()-nPos)&1)!=0)
- pPict->WriteUChar( (sal_uInt8)0 );
+ pPict->WriteUChar( 0 );
aDstTextPosition = aPoint;
bDstTextPositionValid=true;
@@ -697,7 +697,7 @@ void PictWriter::WriteOpcode_FontName(const vcl::Font & rFont)
pPict->WriteUInt16( (sal_uInt16)0x002c ).WriteUInt16( nDataLen ).WriteUInt16( nFontId );
WriteString( rFont.GetName() );
if ( ( nFontNameLen & 1 ) == 0 )
- pPict->WriteUChar( (sal_uInt8)0 );
+ pPict->WriteUChar( 0 );
}
pPict->WriteUInt16( (sal_uInt16)0x0003 ).WriteUInt16( nFontId );
aDstFontName=rFont.GetName();
@@ -955,10 +955,10 @@ void PictWriter::WriteOpcode_BitsRect(const Point & rPoint, const Size & rSize,
{ // don't pack
for ( ny = 0; ny < nHeight; ny++ )
{
- pPict->WriteUChar( (sal_uInt8)0 );
- pPict->WriteUChar( (sal_uInt8)pAcc->GetPixel( ny, 0 ).GetRed() );
- pPict->WriteUChar( (sal_uInt8)pAcc->GetPixel( ny, 0 ).GetGreen() );
- pPict->WriteUChar( (sal_uInt8)pAcc->GetPixel( ny, 0 ).GetBlue() );
+ pPict->WriteUChar( 0 );
+ pPict->WriteUChar( pAcc->GetPixel( ny, 0 ).GetRed() );
+ pPict->WriteUChar( pAcc->GetPixel( ny, 0 ).GetGreen() );
+ pPict->WriteUChar( pAcc->GetPixel( ny, 0 ).GetBlue() );
// count percentages, Callback, check errors:
nActBitmapPercent = ( ny * 70 / nHeight ) + 30; // (30% already added up to the writing of the Win-BMP file)
MayCallback();
@@ -990,7 +990,7 @@ void PictWriter::WriteOpcode_BitsRect(const Point & rPoint, const Size & rSize,
if ( nDstRowBytes > 250 )
pPict->WriteUInt16( (sal_uInt16)0 );
else
- pPict->WriteUChar( (sal_uInt8)0 );
+ pPict->WriteUChar( 0 );
// loop trough components:
for ( nc = 0; nc < 4; nc++ )
@@ -1185,7 +1185,7 @@ void PictWriter::WriteOpcode_BitsRect(const Point & rPoint, const Size & rSize,
if ( nDstRowBytes > 250 )
pPict->WriteUInt16( (sal_uInt16)0 );
else
- pPict->WriteUChar( (sal_uInt8)0 );
+ pPict->WriteUChar( 0 );
// loop trough bytes of the row:
nx=0;
@@ -1261,7 +1261,7 @@ void PictWriter::WriteOpcode_BitsRect(const Point & rPoint, const Size & rSize,
// Map-Data has to be an even number of bytes:
if ( ( ( pPict->Tell() - nDstMapPos ) & 1 ) != 0 )
- pPict->WriteUChar( (sal_uInt8)0 );
+ pPict->WriteUChar( 0 );
// counting Bitmaps:
nWrittenBitmaps++;
diff --git a/filter/source/graphicfilter/eppm/eppm.cxx b/filter/source/graphicfilter/eppm/eppm.cxx
index 2018a9df4355..7bfde7bdd4b4 100644
--- a/filter/source/graphicfilter/eppm/eppm.cxx
+++ b/filter/source/graphicfilter/eppm/eppm.cxx
@@ -126,11 +126,11 @@ bool PPMWriter::ImplWriteHeader()
m_rOStm.WriteCharPtr( "P3\x0a" );
ImplWriteNumber( mnWidth );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( mnHeight );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( 255 ); // max. col.
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
else
mbStatus = false;
@@ -166,7 +166,7 @@ void PPMWriter::ImplWriteBody()
if ( nCount < 0 )
{
nCount = 69;
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
nDat[0] = mpAcc->GetPixel( y, x ).GetRed();
nDat[1] = mpAcc->GetPixel( y, x ).GetGreen();
@@ -176,12 +176,12 @@ void PPMWriter::ImplWriteBody()
nNumb = nDat[ i ] / 100;
if ( nNumb )
{
- m_rOStm.WriteUChar( (sal_uInt8)( nNumb + '0' ) );
+ m_rOStm.WriteUChar( ( nNumb + '0' ) );
nDat[ i ] -= ( nNumb * 100 );
nNumb = nDat[ i ] / 10;
- m_rOStm.WriteUChar( (sal_uInt8)( nNumb + '0' ) );
+ m_rOStm.WriteUChar( ( nNumb + '0' ) );
nDat[ i ] -= ( nNumb * 10 );
- m_rOStm.WriteUChar( (sal_uInt8)( nDat[ i ] + '0' ) );
+ m_rOStm.WriteUChar( ( nDat[ i ] + '0' ) );
nCount -= 4;
}
else
@@ -189,21 +189,21 @@ void PPMWriter::ImplWriteBody()
nNumb = nDat[ i ] / 10;
if ( nNumb )
{
- m_rOStm.WriteUChar( (sal_uInt8)( nNumb + '0' ) );
+ m_rOStm.WriteUChar( ( nNumb + '0' ) );
nDat[ i ] -= ( nNumb * 10 );
- m_rOStm.WriteUChar( (sal_uInt8)( nDat[ i ] + '0' ) );
+ m_rOStm.WriteUChar( ( nDat[ i ] + '0' ) );
nCount -= 3;
}
else
{
- m_rOStm.WriteUChar( (sal_uInt8)( nDat[ i ] + '0' ) );
+ m_rOStm.WriteUChar( ( nDat[ i ] + '0' ) );
nCount -= 2;
}
}
- m_rOStm.WriteUChar( (sal_uInt8)' ' );
+ m_rOStm.WriteUChar( ' ' );
}
}
- m_rOStm.WriteUChar( (sal_uInt8)10 );
+ m_rOStm.WriteUChar( 10 );
}
}
}
diff --git a/filter/source/graphicfilter/eps/eps.cxx b/filter/source/graphicfilter/eps/eps.cxx
index 28f7fa1afc32..35e5f391242d 100644
--- a/filter/source/graphicfilter/eps/eps.cxx
+++ b/filter/source/graphicfilter/eps/eps.cxx
@@ -1537,7 +1537,7 @@ void PSWriter::ImplRect( const Rectangle & rRect )
mpPS->WriteCharPtr( "neg 0 rl " );
ImplClosePathDraw();
}
- mpPS->WriteUChar( (sal_uInt8)10 );
+ mpPS->WriteUChar( 10 );
mnCursorPos = 0;
}
@@ -1899,7 +1899,7 @@ void PSWriter::ImplBmp( Bitmap* pBitmap, Bitmap* pMaskBitmap, const Point & rPoi
ImplWriteHexByte( pAcc->GetPixelIndex( y, x ) );
}
}
- mpPS->WriteUChar( (sal_uInt8)10 );
+ mpPS->WriteUChar( 10 );
}
else // Level 2
{
@@ -2238,7 +2238,7 @@ void PSWriter::ImplSetAttrForText( const Point& rPoint )
void PSWriter::ImplDefineFont( const char* pOriginalName, const char* pItalic )
{
- mpPS->WriteUChar( (sal_uInt8)'/' ); //convert the font pOriginalName using ISOLatin1Encoding
+ mpPS->WriteUChar( '/' ); //convert the font pOriginalName using ISOLatin1Encoding
mpPS->WriteCharPtr( pOriginalName );
switch ( maFont.GetWeight() )
{
@@ -2391,18 +2391,18 @@ inline void PSWriter::ImplExecMode( sal_uLong nMode )
if ( mnCursorPos >= PS_LINESIZE )
{
mnCursorPos = 0;
- mpPS->WriteUChar( (sal_uInt8)0xa );
+ mpPS->WriteUChar( 0xa );
return;
}
}
if ( nMode & PS_SPACE )
{
- mpPS->WriteUChar( (sal_uInt8)32 );
+ mpPS->WriteUChar( 32 );
mnCursorPos++;
}
if ( nMode & PS_RET )
{
- mpPS->WriteUChar( (sal_uInt8)0xa );
+ mpPS->WriteUChar( 0xa );
mnCursorPos = 0;
}
}
@@ -2414,7 +2414,7 @@ inline void PSWriter::ImplWriteLine( const char* pString, sal_uLong nMode )
sal_uLong i = 0;
while ( pString[ i ] )
{
- mpPS->WriteUChar( (sal_uInt8)pString[ i++ ] );
+ mpPS->WriteUChar( pString[ i++ ] );
}
mnCursorPos += i;
ImplExecMode( nMode );
@@ -2542,7 +2542,7 @@ void PSWriter::ImplWriteDouble( double fNumber, sal_uLong nMode )
if ( nATemp )
{
int zCount = 0;
- mpPS->WriteUChar( (sal_uInt8)'.' );
+ mpPS->WriteUChar( '.' );
mnCursorPos++;
const OString aNumber2(OString::number(nATemp));
@@ -2552,7 +2552,7 @@ void PSWriter::ImplWriteDouble( double fNumber, sal_uLong nMode )
mnCursorPos += 6 - nLen;
for ( n = 0; n < ( 5 - nLen ); n++ )
{
- mpPS->WriteUChar( (sal_uInt8)'0' );
+ mpPS->WriteUChar( '0' );
}
}
mnCursorPos += nLen;
@@ -2577,7 +2577,7 @@ void PSWriter::ImplWriteF( sal_Int32 nNumber, sal_uLong nCount, sal_uLong nMode
{
if ( nNumber < 0 )
{
- mpPS->WriteUChar( (sal_uInt8)'-' );
+ mpPS->WriteUChar( '-' );
nNumber = -nNumber;
mnCursorPos++;
}
@@ -2586,15 +2586,15 @@ void PSWriter::ImplWriteF( sal_Int32 nNumber, sal_uLong nCount, sal_uLong nMode
long nStSize = ( nCount + 1 ) - nLen;
if ( nStSize >= 1 )
{
- mpPS->WriteUChar( (sal_uInt8)'0' );
+ mpPS->WriteUChar( '0' );
mnCursorPos++;
}
if ( nStSize >= 2 )
{
- mpPS->WriteUChar( (sal_uInt8)'.' );
+ mpPS->WriteUChar( '.' );
for ( long i = 1; i < nStSize; i++ )
{
- mpPS->WriteUChar( (sal_uInt8)'0' );
+ mpPS->WriteUChar( '0' );
mnCursorPos++;
}
}
@@ -2603,7 +2603,7 @@ void PSWriter::ImplWriteF( sal_Int32 nNumber, sal_uLong nCount, sal_uLong nMode
{
if ( n == nLen - nCount )
{
- mpPS->WriteUChar( (sal_uInt8)'.' );
+ mpPS->WriteUChar( '.' );
mnCursorPos++;
}
mpPS->WriteChar( aScaleFactor[n] );
@@ -2625,14 +2625,14 @@ void PSWriter::ImplWriteByte( sal_uInt8 nNumb, sal_uLong nMode )
void PSWriter::ImplWriteHexByte( sal_uInt8 nNumb, sal_uLong nMode )
{
if ( ( nNumb >> 4 ) > 9 )
- mpPS->WriteUChar( (sal_uInt8)( ( nNumb >> 4 ) + 'A' - 10 ) );
+ mpPS->WriteUChar( ( ( nNumb >> 4 ) + 'A' - 10 ) );
else
- mpPS->WriteUChar( (sal_uInt8)( ( nNumb >> 4 ) + '0' ) );
+ mpPS->WriteUChar( ( ( nNumb >> 4 ) + '0' ) );
if ( ( nNumb & 0xf ) > 9 )
- mpPS->WriteUChar( (sal_uInt8)( ( nNumb & 0xf ) + 'A' - 10 ) );
+ mpPS->WriteUChar( ( ( nNumb & 0xf ) + 'A' - 10 ) );
else
- mpPS->WriteUChar( (sal_uInt8)( ( nNumb & 0xf ) + '0' ) );
+ mpPS->WriteUChar( ( ( nNumb & 0xf ) + '0' ) );
mnCursorPos += 2;
ImplExecMode( nMode );
}
diff --git a/filter/source/graphicfilter/eras/eras.cxx b/filter/source/graphicfilter/eras/eras.cxx
index d9bf00f4c997..8b230668faf5 100644
--- a/filter/source/graphicfilter/eras/eras.cxx
+++ b/filter/source/graphicfilter/eras/eras.cxx
@@ -249,15 +249,15 @@ void RASWriter::ImplPutByte( sal_uInt8 nPutThis )
{
if ( mnRepCount == 0 )
{
- m_rOStm.WriteUChar( (sal_uInt8)mnRepVal );
+ m_rOStm.WriteUChar( mnRepVal );
if ( mnRepVal == 0x80 )
- m_rOStm.WriteUChar( (sal_uInt8)0 );
+ m_rOStm.WriteUChar( 0 );
}
else
{
- m_rOStm.WriteUChar( (sal_uInt8)0x80 );
- m_rOStm.WriteUChar( (sal_uInt8)mnRepCount );
- m_rOStm.WriteUChar( (sal_uInt8)mnRepVal );
+ m_rOStm.WriteUChar( 0x80 );
+ m_rOStm.WriteUChar( mnRepCount );
+ m_rOStm.WriteUChar( mnRepVal );
}
mnRepVal = nPutThis;
mnRepCount = 0;
diff --git a/filter/source/graphicfilter/etiff/etiff.cxx b/filter/source/graphicfilter/etiff/etiff.cxx
index 5bc8fa1408f0..031918bec64a 100644
--- a/filter/source/graphicfilter/etiff/etiff.cxx
+++ b/filter/source/graphicfilter/etiff/etiff.cxx
@@ -506,13 +506,13 @@ inline void TIFFWriter::WriteBits( sal_uInt16 nCode, sal_uInt16 nCodeLen )
nOffset -= nCodeLen;
while ( nOffset < 24 )
{
- m_rOStm.WriteUChar( (sal_uInt8)( dwShift >> 24 ) );
+ m_rOStm.WriteUChar( ( dwShift >> 24 ) );
dwShift <<= 8;
nOffset += 8;
}
if ( nCode == 257 && nOffset != 32 )
{
- m_rOStm.WriteUChar( (sal_uInt8)( dwShift >> 24 ) );
+ m_rOStm.WriteUChar( ( dwShift >> 24 ) );
}
}
diff --git a/filter/source/graphicfilter/expm/expm.cxx b/filter/source/graphicfilter/expm/expm.cxx
index 3bc25d585329..3b5fd5bd1c33 100644
--- a/filter/source/graphicfilter/expm/expm.cxx
+++ b/filter/source/graphicfilter/expm/expm.cxx
@@ -154,11 +154,11 @@ bool XPMWriter::ImplWriteHeader()
{
m_rOStm.WriteCharPtr( "/* XPM */\x0astatic char * image[] = \x0a{\x0a\x22" );
ImplWriteNumber( mnWidth );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( mnHeight );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( mnColors );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
ImplWriteNumber( ( mnColors > 26 ) ? 2 : 1 );
m_rOStm.WriteCharPtr( "\x22,\x0a" );
}
@@ -178,7 +178,7 @@ void XPMWriter::ImplWritePalette()
{
m_rOStm.WriteCharPtr( "\x22" );
ImplWritePixel( i );
- m_rOStm.WriteUChar( (sal_uInt8)32 );
+ m_rOStm.WriteUChar( 32 );
if ( nTransIndex != i )
{
ImplWriteColor( i );
@@ -196,7 +196,7 @@ void XPMWriter::ImplWriteBody()
for ( sal_uLong y = 0; y < mnHeight; y++ )
{
ImplCallback( (sal_uInt16)( ( 100 * y ) / mnHeight ) ); // processing output in percent
- m_rOStm.WriteUChar( (sal_uInt8)0x22 );
+ m_rOStm.WriteUChar( 0x22 );
for ( sal_uLong x = 0; x < mnWidth; x++ )
{
ImplWritePixel( mpAcc->GetPixelIndex( y, x ) );
@@ -221,11 +221,11 @@ void XPMWriter::ImplWritePixel( sal_uLong nCol ) const
if ( mnColors > 26 )
{
sal_uInt8 nDiff = (sal_uInt8) ( nCol / 26 );
- m_rOStm.WriteUChar( (sal_uInt8)( nDiff + 'A' ) );
- m_rOStm.WriteUChar( (sal_uInt8)( nCol - ( nDiff*26 ) + 'A' ) );
+ m_rOStm.WriteUChar( ( nDiff + 'A' ) );
+ m_rOStm.WriteUChar( ( nCol - ( nDiff*26 ) + 'A' ) );
}
else
- m_rOStm.WriteUChar( (sal_uInt8)( nCol + 'A' ) );
+ m_rOStm.WriteUChar( ( nCol + 'A' ) );
}
diff --git a/filter/source/msfilter/escherex.cxx b/filter/source/msfilter/escherex.cxx
index da4e6aa8026f..e322d7f32d31 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -4166,16 +4166,16 @@ void EscherBlibEntry::WriteBlibEntry( SvStream& rSt, bool bWritePictureOffset, s
rSt.WriteUInt32( (sal_uInt32)( ( ESCHER_BSE << 16 ) | ( ( (sal_uInt16)meBlibType << 4 ) | 2 ) ) )
.WriteUInt32( (sal_uInt32)( 36 + nResize ) )
- .WriteUChar( (sal_uInt8)meBlibType );
+ .WriteUChar( meBlibType );
switch ( meBlibType )
{
case EMF :
case WMF : // converting EMF/WMF on OS2 to Pict
- rSt.WriteUChar( (sal_uInt8)PICT );
+ rSt.WriteUChar( PICT );
break;
default:
- rSt.WriteUChar( (sal_uInt8)meBlibType );
+ rSt.WriteUChar( meBlibType );
}
rSt.Write( &mnIdentifier[ 0 ], 16 );
@@ -4500,7 +4500,7 @@ sal_uInt32 EscherGraphicProvider::GetBlibID( SvStream& rPicOutStrm, const OStrin
rPicOutStrm.WriteUInt32( nInstance ).WriteUInt32( (sal_uInt32)( p_EscherBlibEntry->mnSize + nExtra ) );
rPicOutStrm.Write( p_EscherBlibEntry->mnIdentifier, 16 );
- rPicOutStrm.WriteUChar( (sal_uInt8)0xff );
+ rPicOutStrm.WriteUChar( 0xff );
rPicOutStrm.Write( pGraphicAry, p_EscherBlibEntry->mnSize );
}
else