diff options
author | Jan Holesovsky <kendy@suse.cz> | 2011-03-18 15:55:08 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2011-03-18 15:55:08 +0100 |
commit | 4fdd55226d2972e3a256426db3122ac23b0615c6 (patch) | |
tree | 23f5b3a68382d6d3b8db0cb5e2537ed74a228d7c /cppcanvas | |
parent | c3d5444d84e18fa82235bb9d419861ac5e54f544 (diff) | |
parent | e1028d9225bc47922c387aa462887c7643bc6c40 (diff) |
Merge remote-tracking branch 'origin/integration/dev300_m101'
Conflicts:
comphelper/source/misc/servicedecl.cxx
i18npool/source/breakiterator/breakiteratorImpl.cxx
l10ntools/scripts/localize.pl
svl/source/items/itemset.cxx
svl/source/memtools/svarray.cxx
svl/source/numbers/zformat.cxx
svtools/source/brwbox/brwbox1.cxx
tools/source/stream/strmwnt.cxx
vcl/inc/vcl/graphite_adaptors.hxx
vcl/inc/vcl/graphite_layout.hxx
vcl/inc/vcl/graphite_serverfont.hxx
vcl/source/control/imgctrl.cxx
vcl/source/gdi/outdev.cxx
vcl/source/gdi/outdev3.cxx
vcl/source/glyphs/gcach_ftyp.cxx
vcl/source/glyphs/graphite_adaptors.cxx
vcl/source/glyphs/graphite_layout.cxx
vcl/source/window/winproc.cxx
vcl/unx/source/fontmanager/fontconfig.cxx
Diffstat (limited to 'cppcanvas')
-rw-r--r-- | cppcanvas/inc/cppcanvas/renderer.hxx | 20 | ||||
-rw-r--r-- | cppcanvas/source/inc/implrenderer.hxx | 6 | ||||
-rw-r--r-- | cppcanvas/source/mtfrenderer/emfplus.cxx | 32 | ||||
-rw-r--r-- | cppcanvas/source/mtfrenderer/implrenderer.cxx | 98 | ||||
-rw-r--r-- | cppcanvas/source/mtfrenderer/mtftools.cxx | 4 | ||||
-rw-r--r-- | cppcanvas/source/mtfrenderer/textaction.cxx | 36 | ||||
-rw-r--r-- | cppcanvas/source/uno/exports.dxp | 1 | ||||
-rw-r--r-- | cppcanvas/source/uno/exports.map | 1 | ||||
-rw-r--r-- | cppcanvas/source/wrapper/vclfactory.cxx | 4 |
9 files changed, 100 insertions, 102 deletions
diff --git a/cppcanvas/inc/cppcanvas/renderer.hxx b/cppcanvas/inc/cppcanvas/renderer.hxx index 79f1eb0744f7..a01b438670a8 100644 --- a/cppcanvas/inc/cppcanvas/renderer.hxx +++ b/cppcanvas/inc/cppcanvas/renderer.hxx @@ -33,7 +33,7 @@ #include <rtl/ustring.hxx> #include <boost/shared_ptr.hpp> -#include <comphelper/optionalvalue.hxx> +#include <boost/optional.hpp> #include <basegfx/matrix/b2dhommatrix.hxx> #include <cppcanvas/canvasgraphic.hxx> #include <cppcanvas/color.hxx> @@ -110,16 +110,16 @@ namespace cppcanvas struct Parameters { /// Optionally forces the fill color attribute for all actions - ::comphelper::OptionalValue< Color::IntSRGBA > maFillColor; + ::boost::optional< Color::IntSRGBA > maFillColor; /// Optionally forces the line color attribute for all actions - ::comphelper::OptionalValue< Color::IntSRGBA > maLineColor; + ::boost::optional< Color::IntSRGBA > maLineColor; /// Optionally forces the text color attribute for all actions - ::comphelper::OptionalValue< Color::IntSRGBA > maTextColor; + ::boost::optional< Color::IntSRGBA > maTextColor; /// Optionally forces the given fontname for all text actions - ::comphelper::OptionalValue< ::rtl::OUString > maFontName; + ::boost::optional< ::rtl::OUString > maFontName; /** Optionally transforms all text output actions with the given matrix (in addition to the overall canvas @@ -129,19 +129,19 @@ namespace cppcanvas rect coordinate system, i.e. the metafile is assumed to be contained in the unit rect. */ - ::comphelper::OptionalValue< ::basegfx::B2DHomMatrix > maTextTransformation; + ::boost::optional< ::basegfx::B2DHomMatrix > maTextTransformation; /// Optionally forces the given font weight for all text actions - ::comphelper::OptionalValue< sal_Int8 > maFontWeight; + ::boost::optional< sal_Int8 > maFontWeight; /// Optionally forces the given font letter form (italics etc.) for all text actions - ::comphelper::OptionalValue< sal_Int8 > maFontLetterForm; + ::boost::optional< sal_Int8 > maFontLetterForm; /// Optionally forces the given font proportion (condensed, monospaced etc.) for all text actions - ::comphelper::OptionalValue< sal_Int8 > maFontProportion; + ::boost::optional< sal_Int8 > maFontProportion; /// Optionally forces underlining for all text actions - ::comphelper::OptionalValue< bool > maFontUnderline; + ::boost::optional< bool > maFontUnderline; }; }; diff --git a/cppcanvas/source/inc/implrenderer.hxx b/cppcanvas/source/inc/implrenderer.hxx index 49da12816757..3c1ec6de127f 100644 --- a/cppcanvas/source/inc/implrenderer.hxx +++ b/cppcanvas/source/inc/implrenderer.hxx @@ -245,7 +245,7 @@ static float GetSwapFloat( SvStream& rSt ) bool isActionContained( GDIMetaFile& rMtf, const char* pCommentString, - USHORT nType ) const; + sal_uInt16 nType ) const; void createGradientAction( const ::PolyPolygon& rPoly, const ::Gradient& rGradient, @@ -266,7 +266,7 @@ static float GetSwapFloat( SvStream& rSt ) ActionVector::const_iterator& o_rRangeBegin, ActionVector::const_iterator& o_rRangeEnd ) const; - void processObjectRecord(SvMemoryStream& rObjectStream, UINT16 flags); + void processObjectRecord(SvMemoryStream& rObjectStream, sal_uInt16 flags); void processEMFPlus( MetaCommentAction* pAct, const ActionFactoryParameters& rFactoryParms, OutDevState& rState, const CanvasSharedPtr& rCanvas ); void EMFPPlusFillPolygon (::basegfx::B2DPolyPolygon& polygon, const ActionFactoryParameters& rParms, OutDevState& rState, const CanvasSharedPtr& rCanvas, bool isColor, sal_uInt32 brushIndexOrColor); @@ -293,7 +293,7 @@ static float GetSwapFloat( SvStream& rSt ) sal_Int32 nMmY; /* multipart object data */ bool mbMultipart; - UINT16 mMFlags; + sal_uInt16 mMFlags; SvMemoryStream mMStream; }; diff --git a/cppcanvas/source/mtfrenderer/emfplus.cxx b/cppcanvas/source/mtfrenderer/emfplus.cxx index 2059aaec486b..b2a582b1319d 100644 --- a/cppcanvas/source/mtfrenderer/emfplus.cxx +++ b/cppcanvas/source/mtfrenderer/emfplus.cxx @@ -144,12 +144,12 @@ namespace cppcanvas } // TODO: remove rR argument when debug code is not longer needed - void Read (SvStream& s, UINT32 pathFlags, ImplRenderer& rR) + void Read (SvStream& s, sal_uInt32 pathFlags, ImplRenderer& rR) { for (int i = 0; i < nPoints; i ++) { if (pathFlags & 0x4000) { // points are stored in short 16bit integer format - UINT16 x, y; + sal_uInt16 x, y; s >> x >> y; EMFP_DEBUG (printf ("EMF+\tpoint [x,y]: %hd,%hd\n", x, y)); @@ -341,12 +341,12 @@ namespace cppcanvas } } - UINT32 GetType() const { return type; } + sal_uInt32 GetType() const { return type; } const ::Color& GetColor() const { return solidColor; } void Read (SvStream& s, ImplRenderer& rR) { - UINT32 header; + sal_uInt32 header; s >> header >> type; @@ -355,7 +355,7 @@ namespace cppcanvas switch (type) { case 0: { - UINT32 color; + sal_uInt32 color; s >> color; solidColor = ::Color (0xff - (color >> 24), (color >> 16) & 0xff, (color >> 8) & 0xff, color & 0xff); @@ -370,7 +370,7 @@ namespace cppcanvas EMFP_DEBUG (printf ("EMF+\tpath gradient, additional flags: 0x%02x\n", additionalFlags)); - UINT32 color; + sal_uInt32 color; s >> color; solidColor = ::Color (0xff - (color >> 24), (color >> 16) & 0xff, (color >> 8) & 0xff, color & 0xff); @@ -483,7 +483,7 @@ namespace cppcanvas EMFP_DEBUG (printf ("EMF+\tarea: %f,%f - %fx%f\n", areaX, areaY, areaWidth, areaHeight)); - UINT32 color; + sal_uInt32 color; s >> color; solidColor = ::Color (0xff - (color >> 24), (color >> 16) & 0xff, (color >> 8) & 0xff, color & 0xff); @@ -584,7 +584,7 @@ namespace cppcanvas void Read (SvStream& s, ImplRenderer& rR, sal_Int32, sal_Int32 ) { - UINT32 header, unknown, penFlags, unknown2; + sal_uInt32 header, unknown, penFlags, unknown2; int i; s >> header >> unknown >> penFlags >> unknown2 >> width; @@ -1086,9 +1086,9 @@ namespace cppcanvas } } - void ImplRenderer::processObjectRecord(SvMemoryStream& rObjectStream, UINT16 flags) + void ImplRenderer::processObjectRecord(SvMemoryStream& rObjectStream, sal_uInt16 flags) { - EMFP_DEBUG (UINT32 objectLen); + EMFP_DEBUG (sal_uInt32 objectLen); sal_uInt32 index; EMFP_DEBUG (printf ("EMF+ Object slot: %hd flags: %hx\n", flags & 0xff, flags & 0xff00)); @@ -1169,8 +1169,8 @@ namespace cppcanvas length -= 4; while (length > 0) { - UINT16 type, flags; - UINT32 size, dataSize; + sal_uInt16 type, flags; + sal_uInt32 size, dataSize; sal_uInt32 next; rMF >> type >> flags >> size >> dataSize; @@ -1201,7 +1201,7 @@ namespace cppcanvas if (type != EmfPlusRecordTypeObject || !(flags & 0x8000)) switch (type) { case EmfPlusRecordTypeHeader: - UINT32 header, version; + sal_uInt32 header, version; rMF >> header >> version >> nHDPI >> nVDPI; @@ -1282,8 +1282,8 @@ namespace cppcanvas sal_uInt32 brushIndexOrColor; EMFP_DEBUG (sal_Int32 brushIndex); sal_Int32 points; - EMFP_DEBUG (UINT32 color); - EMFP_DEBUG (USHORT transparency = 0); + EMFP_DEBUG (sal_uInt32 color); + EMFP_DEBUG (sal_uInt16 transparency = 0); rMF >> brushIndexOrColor; rMF >> points; @@ -1343,7 +1343,7 @@ namespace cppcanvas } case EmfPlusRecordTypeDrawPath: { - UINT32 penIndex; + sal_uInt32 penIndex; rMF >> penIndex; diff --git a/cppcanvas/source/mtfrenderer/implrenderer.cxx b/cppcanvas/source/mtfrenderer/implrenderer.cxx index 914a94e5822b..c71c09863234 100644 --- a/cppcanvas/source/mtfrenderer/implrenderer.cxx +++ b/cppcanvas/source/mtfrenderer/implrenderer.cxx @@ -147,7 +147,7 @@ namespace } void pushState( ::cppcanvas::internal::VectorOfOutDevStates& rStates, - USHORT nFlags ) + sal_uInt16 nFlags ) { rStates.push_back( getState( rStates ) ); getState( rStates ).pushFlags = nFlags; @@ -451,7 +451,7 @@ namespace // translate characters to local preference sal_Unicode cChar = getLocalizedChar( *pBegin, eTextLanguage ); if( cChar != *pBegin ) - rStr.SetChar( sal::static_int_cast<USHORT>(pBegin - pBase), cChar ); + rStr.SetChar( sal::static_int_cast<sal_uInt16>(pBegin - pBase), cChar ); } } } @@ -526,7 +526,7 @@ namespace cppcanvas bool ImplRenderer::isActionContained( GDIMetaFile& rMtf, const char* pCommentString, - USHORT nType ) const + sal_uInt16 nType ) const { ENSURE_OR_THROW( pCommentString, "ImplRenderer::isActionContained(): NULL string given" ); @@ -535,7 +535,7 @@ namespace cppcanvas // at least _one_ call to GDIMetaFile::NextAction() is // executed - ULONG nPos( 1 ); + sal_uIntPtr nPos( 1 ); MetaAction* pCurrAct; while( (pCurrAct=rMtf.NextAction()) != NULL ) @@ -586,7 +586,7 @@ namespace cppcanvas // decide, whether this gradient can be rendered natively // by the canvas, or must be emulated via VCL gradient // action extraction. - const USHORT nSteps( rGradient.GetSteps() ); + const sal_uInt16 nSteps( rGradient.GetSteps() ); if( // step count is infinite, can use native canvas // gradients here @@ -611,17 +611,17 @@ namespace cppcanvas // ---------------------------- // scale color coefficients with gradient intensities - const USHORT nStartIntensity( rGradient.GetStartIntensity() ); + const sal_uInt16 nStartIntensity( rGradient.GetStartIntensity() ); ::Color aVCLStartColor( rGradient.GetStartColor() ); - aVCLStartColor.SetRed( (UINT8)(aVCLStartColor.GetRed() * nStartIntensity / 100) ); - aVCLStartColor.SetGreen( (UINT8)(aVCLStartColor.GetGreen() * nStartIntensity / 100) ); - aVCLStartColor.SetBlue( (UINT8)(aVCLStartColor.GetBlue() * nStartIntensity / 100) ); + aVCLStartColor.SetRed( (sal_uInt8)(aVCLStartColor.GetRed() * nStartIntensity / 100) ); + aVCLStartColor.SetGreen( (sal_uInt8)(aVCLStartColor.GetGreen() * nStartIntensity / 100) ); + aVCLStartColor.SetBlue( (sal_uInt8)(aVCLStartColor.GetBlue() * nStartIntensity / 100) ); - const USHORT nEndIntensity( rGradient.GetEndIntensity() ); + const sal_uInt16 nEndIntensity( rGradient.GetEndIntensity() ); ::Color aVCLEndColor( rGradient.GetEndColor() ); - aVCLEndColor.SetRed( (UINT8)(aVCLEndColor.GetRed() * nEndIntensity / 100) ); - aVCLEndColor.SetGreen( (UINT8)(aVCLEndColor.GetGreen() * nEndIntensity / 100) ); - aVCLEndColor.SetBlue( (UINT8)(aVCLEndColor.GetBlue() * nEndIntensity / 100) ); + aVCLEndColor.SetRed( (sal_uInt8)(aVCLEndColor.GetRed() * nEndIntensity / 100) ); + aVCLEndColor.SetGreen( (sal_uInt8)(aVCLEndColor.GetGreen() * nEndIntensity / 100) ); + aVCLEndColor.SetBlue( (sal_uInt8)(aVCLEndColor.GetBlue() * nEndIntensity / 100) ); uno::Reference<rendering::XColorSpace> xColorSpace( rParms.mrCanvas->getUNOCanvas()->getDevice()->getDeviceColorSpace()); @@ -848,8 +848,8 @@ namespace cppcanvas { rendering::FontRequest aFontRequest; - if( rParms.mrParms.maFontName.isValid() ) - aFontRequest.FontDescription.FamilyName = rParms.mrParms.maFontName.getValue(); + if( rParms.mrParms.maFontName.is_initialized() ) + aFontRequest.FontDescription.FamilyName = *rParms.mrParms.maFontName; else aFontRequest.FontDescription.FamilyName = rFont.GetName(); @@ -860,16 +860,16 @@ namespace cppcanvas // TODO(F2): improve vclenum->panose conversion aFontRequest.FontDescription.FontDescription.Weight = - rParms.mrParms.maFontWeight.isValid() ? - rParms.mrParms.maFontWeight.getValue() : + rParms.mrParms.maFontWeight.is_initialized() ? + *rParms.mrParms.maFontWeight : ::canvas::tools::numeric_cast<sal_Int8>( ::basegfx::fround( rFont.GetWeight() ) ); aFontRequest.FontDescription.FontDescription.Letterform = - rParms.mrParms.maFontLetterForm.isValid() ? - rParms.mrParms.maFontLetterForm.getValue() : + rParms.mrParms.maFontLetterForm.is_initialized() ? + *rParms.mrParms.maFontLetterForm : (rFont.GetItalic() == ITALIC_NONE) ? 0 : 9; aFontRequest.FontDescription.FontDescription.Proportion = - rParms.mrParms.maFontProportion.isValid() ? - rParms.mrParms.maFontProportion.getValue() : + rParms.mrParms.maFontProportion.is_initialized() ? + *rParms.mrParms.maFontProportion : (rFont.GetPitch() == PITCH_FIXED) ? rendering::PanoseProportion::MONO_SPACED : rendering::PanoseProportion::ANYTHING; @@ -1468,7 +1468,7 @@ namespace cppcanvas break; case META_LINECOLOR_ACTION: - if( !rParms.maLineColor.isValid() ) + if( !rParms.maLineColor.is_initialized() ) { setStateColor( static_cast<MetaLineColorAction*>(pCurrAct), getState( rStates ).isLineColorSet, @@ -1478,7 +1478,7 @@ namespace cppcanvas break; case META_FILLCOLOR_ACTION: - if( !rParms.maFillColor.isValid() ) + if( !rParms.maFillColor.is_initialized() ) { setStateColor( static_cast<MetaFillColorAction*>(pCurrAct), getState( rStates ).isFillColorSet, @@ -1489,7 +1489,7 @@ namespace cppcanvas case META_TEXTCOLOR_ACTION: { - if( !rParms.maTextColor.isValid() ) + if( !rParms.maTextColor.is_initialized() ) { // Text color is set unconditionally, thus, no // use of setStateColor here @@ -1509,7 +1509,7 @@ namespace cppcanvas break; case META_TEXTFILLCOLOR_ACTION: - if( !rParms.maTextColor.isValid() ) + if( !rParms.maTextColor.is_initialized() ) { setStateColor( static_cast<MetaTextFillColorAction*>(pCurrAct), getState( rStates ).isTextFillColorSet, @@ -1519,7 +1519,7 @@ namespace cppcanvas break; case META_TEXTLINECOLOR_ACTION: - if( !rParms.maTextColor.isValid() ) + if( !rParms.maTextColor.is_initialized() ) { setStateColor( static_cast<MetaTextLineColorAction*>(pCurrAct), getState( rStates ).isTextLineColorSet, @@ -1549,14 +1549,14 @@ namespace cppcanvas // TODO(Q2): define and use appropriate enumeration types rState.textReliefStyle = (sal_Int8)rFont.GetRelief(); rState.textOverlineStyle = (sal_Int8)rFont.GetOverline(); - rState.textUnderlineStyle = rParms.maFontUnderline.isValid() ? - (rParms.maFontUnderline.getValue() ? (sal_Int8)UNDERLINE_SINGLE : (sal_Int8)UNDERLINE_NONE) : + rState.textUnderlineStyle = rParms.maFontUnderline.is_initialized() ? + (*rParms.maFontUnderline ? (sal_Int8)UNDERLINE_SINGLE : (sal_Int8)UNDERLINE_NONE) : (sal_Int8)rFont.GetUnderline(); rState.textStrikeoutStyle = (sal_Int8)rFont.GetStrikeout(); rState.textEmphasisMarkStyle = (sal_Int8)rFont.GetEmphasisMark(); - rState.isTextEffectShadowSet = (rFont.IsShadow() != FALSE); - rState.isTextWordUnderlineSet = (rFont.IsWordLineMode() != FALSE); - rState.isTextOutlineModeSet = (rFont.IsOutline() != FALSE); + rState.isTextEffectShadowSet = (rFont.IsShadow() != sal_False); + rState.isTextWordUnderlineSet = (rFont.IsWordLineMode() != sal_False); + rState.isTextOutlineModeSet = (rFont.IsOutline() != sal_False); } break; @@ -1718,7 +1718,7 @@ namespace cppcanvas // Handle drawing layer fills else if( pAct->GetComment().Equals( "XPATHFILL_SEQ_BEGIN" ) ) { - const BYTE* pData = pAct->GetData(); + const sal_uInt8* pData = pAct->GetData(); if ( pData ) { SvMemoryStream aMemStm( (void*)pData, pAct->GetDataSize(), STREAM_READ ); @@ -2546,7 +2546,7 @@ namespace cppcanvas pAct->GetPoint(), sText, pAct->GetIndex(), - pAct->GetLen() == (USHORT)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen(), + pAct->GetLen() == (sal_uInt16)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen(), NULL, rFactoryParms, bSubsettableActions ); @@ -2565,7 +2565,7 @@ namespace cppcanvas pAct->GetPoint(), sText, pAct->GetIndex(), - pAct->GetLen() == (USHORT)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen(), + pAct->GetLen() == (sal_uInt16)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen(), pAct->GetDXArray(), rFactoryParms, bSubsettableActions ); @@ -2640,7 +2640,7 @@ namespace cppcanvas if( rVDev.GetDigitLanguage()) convertToLocalizedNumerals ( sText,rVDev.GetDigitLanguage() ); - const USHORT nLen( pAct->GetLen() == (USHORT)STRING_LEN ? + const sal_uInt16 nLen( pAct->GetLen() == (sal_uInt16)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen() ); // #i70897# Nothing to do, actually... @@ -2661,7 +2661,7 @@ namespace cppcanvas // Last entry of pDXArray contains total width of the text sal_Int32* p=pDXArray.get(); - for( USHORT i=1; i<=nLen; ++i ) + for( sal_uInt16 i=1; i<=nLen; ++i ) { // calc ratio for every array entry, to // distribute rounding errors 'evenly' @@ -2676,7 +2676,7 @@ namespace cppcanvas pAct->GetPoint(), sText, pAct->GetIndex(), - pAct->GetLen() == (USHORT)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen(), + pAct->GetLen() == (sal_uInt16)STRING_LEN ? pAct->GetText().Len() - pAct->GetIndex() : pAct->GetLen(), pDXArray.get(), rFactoryParms, bSubsettableActions ); @@ -2950,7 +2950,7 @@ namespace cppcanvas VectorOfOutDevStates aStateStack; VirtualDevice aVDev; - aVDev.EnableOutput( FALSE ); + aVDev.EnableOutput( sal_False ); // Setup VDev for state tracking and mapping // ========================================= @@ -2995,29 +2995,29 @@ namespace cppcanvas getState( aStateStack ).textLineColor = pColor->getDeviceColor( 0x000000FF ); // apply overrides from the Parameters struct - if( rParams.maFillColor.isValid() ) + if( rParams.maFillColor.is_initialized() ) { getState( aStateStack ).isFillColorSet = true; - getState( aStateStack ).fillColor = pColor->getDeviceColor( rParams.maFillColor.getValue() ); + getState( aStateStack ).fillColor = pColor->getDeviceColor( *rParams.maFillColor ); } - if( rParams.maLineColor.isValid() ) + if( rParams.maLineColor.is_initialized() ) { getState( aStateStack ).isLineColorSet = true; - getState( aStateStack ).lineColor = pColor->getDeviceColor( rParams.maLineColor.getValue() ); + getState( aStateStack ).lineColor = pColor->getDeviceColor( *rParams.maLineColor ); } - if( rParams.maTextColor.isValid() ) + if( rParams.maTextColor.is_initialized() ) { getState( aStateStack ).isTextFillColorSet = true; getState( aStateStack ).isTextLineColorSet = true; getState( aStateStack ).textColor = getState( aStateStack ).textFillColor = - getState( aStateStack ).textLineColor = pColor->getDeviceColor( rParams.maTextColor.getValue() ); + getState( aStateStack ).textLineColor = pColor->getDeviceColor( *rParams.maTextColor ); } - if( rParams.maFontName.isValid() || - rParams.maFontWeight.isValid() || - rParams.maFontLetterForm.isValid() || - rParams.maFontUnderline.isValid() || - rParams.maFontProportion.isValid() ) + if( rParams.maFontName.is_initialized() || + rParams.maFontWeight.is_initialized() || + rParams.maFontLetterForm.is_initialized() || + rParams.maFontUnderline.is_initialized() || + rParams.maFontProportion.is_initialized() ) { ::cppcanvas::internal::OutDevState& rState = getState( aStateStack ); diff --git a/cppcanvas/source/mtfrenderer/mtftools.cxx b/cppcanvas/source/mtfrenderer/mtftools.cxx index 6633f29ed87d..4810268b7ca7 100644 --- a/cppcanvas/source/mtfrenderer/mtftools.cxx +++ b/cppcanvas/source/mtfrenderer/mtftools.cxx @@ -307,14 +307,14 @@ namespace cppcanvas TextLineInfo createTextLineInfo( const ::VirtualDevice& rVDev, const ::cppcanvas::internal::OutDevState& rState ) { - const BOOL bOldMode( rVDev.IsMapModeEnabled() ); + const sal_Bool bOldMode( rVDev.IsMapModeEnabled() ); // #i68512# Force metric regeneration with mapmode enabled // (prolly OutDev bug) rVDev.GetFontMetric(); // will restore map mode below - const_cast< ::VirtualDevice& >(rVDev).EnableMapMode( FALSE ); + const_cast< ::VirtualDevice& >(rVDev).EnableMapMode( sal_False ); const ::FontMetric aMetric = rVDev.GetFontMetric(); diff --git a/cppcanvas/source/mtfrenderer/textaction.cxx b/cppcanvas/source/mtfrenderer/textaction.cxx index eefa2674b867..a80306df3e05 100644 --- a/cppcanvas/source/mtfrenderer/textaction.cxx +++ b/cppcanvas/source/mtfrenderer/textaction.cxx @@ -213,8 +213,8 @@ namespace cppcanvas ::boost::scoped_array< sal_Int32 > pCharWidths( new sal_Int32[nLen] ); rVDev.GetTextArray( rText, pCharWidths.get(), - static_cast<USHORT>(nStartPos), - static_cast<USHORT>(nLen) ); + static_cast<sal_uInt16>(nStartPos), + static_cast<sal_uInt16>(nLen) ); return setupDXArray( pCharWidths.get(), nLen, rState ); } @@ -288,8 +288,8 @@ namespace cppcanvas { // TODO(F2): use correct scale direction const ::basegfx::B2DSize aSize( rVDev.GetTextWidth( rStringContext.Text, - static_cast<USHORT>(rStringContext.StartPosition), - static_cast<USHORT>(rStringContext.Length) ), + static_cast<sal_uInt16>(rStringContext.StartPosition), + static_cast<sal_uInt16>(rStringContext.Length) ), 0 ); return (rState.mapModeTransform * aSize).getX(); @@ -1976,10 +1976,10 @@ namespace cppcanvas ::basegfx::B2DPolyPolygon aResultingPolyPolygon; PolyPolyVector aVCLPolyPolyVector; const bool bHaveOutlines( rVDev.GetTextOutlines( aVCLPolyPolyVector, rText, - static_cast<USHORT>(nStartPos), - static_cast<USHORT>(nStartPos), - static_cast<USHORT>(nLen), - TRUE, 0, pDXArray ) ); + static_cast<sal_uInt16>(nStartPos), + static_cast<sal_uInt16>(nStartPos), + static_cast<sal_uInt16>(nLen), + sal_True, 0, pDXArray ) ); rVDev.SetFont(aOrigFont); if( !bHaveOutlines ) @@ -2051,7 +2051,7 @@ namespace cppcanvas rCanvas->getUNOCanvas()->getDevice(), aResultingPolyPolygon ) ); - if( rParms.maTextTransformation.isValid() ) + if( rParms.maTextTransformation.is_initialized() ) { return ActionSharedPtr( new OutlineAction( @@ -2067,7 +2067,7 @@ namespace cppcanvas rVDev, rCanvas, rState, - rParms.maTextTransformation.getValue() ) ); + *rParms.maTextTransformation ) ); } else { @@ -2168,7 +2168,7 @@ namespace cppcanvas rShadowColor == aEmptyColor ) { // nope - if( rParms.maTextTransformation.isValid() ) + if( rParms.maTextTransformation.is_initialized() ) { return ActionSharedPtr( new TextAction( aStartPoint, @@ -2177,7 +2177,7 @@ namespace cppcanvas nLen, rCanvas, rState, - rParms.maTextTransformation.getValue() ) ); + *rParms.maTextTransformation ) ); } else { @@ -2193,7 +2193,7 @@ namespace cppcanvas else { // at least one of the effects requested - if( rParms.maTextTransformation.isValid() ) + if( rParms.maTextTransformation.is_initialized() ) return ActionSharedPtr( new EffectTextAction( aStartPoint, aReliefOffset, @@ -2206,7 +2206,7 @@ namespace cppcanvas rVDev, rCanvas, rState, - rParms.maTextTransformation.getValue() ) ); + *rParms.maTextTransformation ) ); else return ActionSharedPtr( new EffectTextAction( aStartPoint, @@ -2232,7 +2232,7 @@ namespace cppcanvas rShadowColor == aEmptyColor ) { // nope - if( rParms.maTextTransformation.isValid() ) + if( rParms.maTextTransformation.is_initialized() ) return ActionSharedPtr( new TextArrayAction( aStartPoint, rText, @@ -2241,7 +2241,7 @@ namespace cppcanvas aCharWidths, rCanvas, rState, - rParms.maTextTransformation.getValue() ) ); + *rParms.maTextTransformation ) ); else return ActionSharedPtr( new TextArrayAction( aStartPoint, @@ -2255,7 +2255,7 @@ namespace cppcanvas else { // at least one of the effects requested - if( rParms.maTextTransformation.isValid() ) + if( rParms.maTextTransformation.is_initialized() ) return ActionSharedPtr( new EffectTextArrayAction( aStartPoint, aReliefOffset, @@ -2269,7 +2269,7 @@ namespace cppcanvas rVDev, rCanvas, rState, - rParms.maTextTransformation.getValue() ) ); + *rParms.maTextTransformation ) ); else return ActionSharedPtr( new EffectTextArrayAction( aStartPoint, diff --git a/cppcanvas/source/uno/exports.dxp b/cppcanvas/source/uno/exports.dxp index 9630d7e06768..f0e1c69934bc 100644 --- a/cppcanvas/source/uno/exports.dxp +++ b/cppcanvas/source/uno/exports.dxp @@ -1,3 +1,2 @@ component_getImplementationEnvironment -component_writeInfo component_getFactory diff --git a/cppcanvas/source/uno/exports.map b/cppcanvas/source/uno/exports.map index 31a8b65a1f93..a488d5d06a43 100644 --- a/cppcanvas/source/uno/exports.map +++ b/cppcanvas/source/uno/exports.map @@ -2,7 +2,6 @@ UDK_3_0_0 { global: _ZTI*; _ZTS*; # weak RTTI symbols for C++ exceptions component_getImplementationEnvironment; - component_writeInfo; component_getFactory; local: *; diff --git a/cppcanvas/source/wrapper/vclfactory.cxx b/cppcanvas/source/wrapper/vclfactory.cxx index 870de321055c..c0646d0fdba5 100644 --- a/cppcanvas/source/wrapper/vclfactory.cxx +++ b/cppcanvas/source/wrapper/vclfactory.cxx @@ -296,7 +296,7 @@ namespace cppcanvas if( !pSpriteCanvas ) return SpriteSharedPtr(); - const USHORT nBitmaps( rAnim.Count() ); + const sal_uInt16 nBitmaps( rAnim.Count() ); uno::Sequence< uno::Reference< rendering::XBitmap > > aBitmapSequence( nBitmaps ); uno::Reference< rendering::XBitmap >* pBitmaps = aBitmapSequence.getArray(); @@ -311,7 +311,7 @@ namespace cppcanvas for( i=0; i<nBitmaps; ++i ) { - const AnimationBitmap& rAnimBmp( rAnim.Get((USHORT)i) ); + const AnimationBitmap& rAnimBmp( rAnim.Get((sal_uInt16)i) ); // Handle dispose according to GIF spec: a // DISPOSE_PREVIOUS does _not_ mean to revert to the |