diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-07-31 23:49:35 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-07-31 23:49:35 +0100 |
commit | ef6add9a7e0bcba1fb039afb75d62e753fa37949 (patch) | |
tree | 2f4bcee1cbcb97e6015995b7edd0d9087289a54e /tools/source | |
parent | d4d26018402aaa75fcb6524f5c7d99fcd9c5be45 (diff) |
callcatcher: remove unused code
Diffstat (limited to 'tools/source')
-rw-r--r-- | tools/source/generic/color.cxx | 49 | ||||
-rw-r--r-- | tools/source/stream/stream.cxx | 7 |
2 files changed, 0 insertions, 56 deletions
diff --git a/tools/source/generic/color.cxx b/tools/source/generic/color.cxx index 5560e631767a..114f395e7786 100644 --- a/tools/source/generic/color.cxx +++ b/tools/source/generic/color.cxx @@ -259,55 +259,6 @@ ColorData Color::HSBtoRGB( sal_uInt16 nHue, sal_uInt16 nSat, sal_uInt16 nBri ) return RGB_COLORDATA( cR, cG, cB ); } -// ----------------------------------------------------------------------- - -// CMYK values from 0 to 1 -ColorData Color::CMYKtoRGB( double fCyan, double fMagenta, double fYellow, double fKey ) -{ - fCyan = (fCyan * ( 1.0 - fKey )) + fKey; - fMagenta = (fMagenta * ( 1.0 - fKey )) + fKey; - fYellow = (fYellow * ( 1.0 - fKey )) + fKey; - - sal_uInt8 nRed = static_cast< sal_uInt8 >( std::max( std::min( ( 1.0 - fCyan ) * 255.0, 255.0), 0.0 ) ); - sal_uInt8 nGreen = static_cast< sal_uInt8 >( std::max( std::min( ( 1.0 - fMagenta ) * 255.0, 255.0), 0.0 ) ); - sal_uInt8 nBlue = static_cast< sal_uInt8 >( std::max( std::min( ( 1.0 - fYellow ) * 255.0, 255.0), 0.0 ) ); - - return RGB_COLORDATA( nRed, nGreen, nBlue ); -} - -// ----------------------------------------------------------------------- - -// RGB values from 0 to 255 -// CMY results from 0 to 1 -void Color::RGBtoCMYK( double& fCyan, double& fMagenta, double& fYellow, double& fKey ) -{ - fCyan = 1 - ( GetRed() / 255.0 ); - fMagenta = 1 - ( GetGreen() / 255.0 ); - fYellow = 1 - ( GetBlue() / 255.0 ); - - //CMYK and CMY values from 0 to 1 - fKey = 1.0; - if( fCyan < fKey ) fKey = fCyan; - if( fMagenta < fKey ) fKey = fMagenta; - if( fYellow < fKey ) fKey = fYellow; - - if ( fKey == 1.0 ) - { - //Black - fCyan = 0.0; - fMagenta = 0.0; - fYellow = 0.0; - } - else - { - fCyan = ( fCyan - fKey ) / ( 1.0 - fKey ); - fMagenta = ( fMagenta - fKey ) / ( 1.0 - fKey ); - fYellow = ( fYellow - fKey ) / ( 1.0 - fKey ); - } -} - -// ----------------------------------------------------------------------- - SvStream& Color::Read( SvStream& rIStm, sal_Bool bNewFormat ) { if ( bNewFormat ) diff --git a/tools/source/stream/stream.cxx b/tools/source/stream/stream.cxx index 84ae7bfb72ee..db7820e838c1 100644 --- a/tools/source/stream/stream.cxx +++ b/tools/source/stream/stream.cxx @@ -920,13 +920,6 @@ sal_Bool SvStream::WriteLine( const ByteString& rStr ) return nError == SVSTREAM_OK; } -sal_Bool SvStream::WriteUniStringLine( const String& rStr ) -{ - WriteUnicodeText( rStr ); - endlu(*this); - return nError == SVSTREAM_OK; -} - /************************************************************************* |* |* Stream::WriteLines() |