From 887bc4dd3e62fe6dd19dc9d1c3ba273a5b21b5ec Mon Sep 17 00:00:00 2001 From: Muthu Subramanian Date: Mon, 27 Jan 2014 16:23:44 +0530 Subject: cp#1000025: Import casemaps from pptx. Note: This only imports it and it may not be even possible to export (even to othe formats). Change-Id: I8e104f1bc3a95c42ac932b6ab58365dc113fb2e0 --- svx/source/svdraw/svdotextdecomposition.cxx | 5 +++-- svx/source/tbxctrls/tbcontrl.cxx | 6 ++++++ svx/source/unodraw/unoprov.cxx | 1 + 3 files changed, 10 insertions(+), 2 deletions(-) (limited to 'svx') diff --git a/svx/source/svdraw/svdotextdecomposition.cxx b/svx/source/svdraw/svdotextdecomposition.cxx index b01aab4052df..4927d8d45b21 100644 --- a/svx/source/svdraw/svdotextdecomposition.cxx +++ b/svx/source/svdraw/svdotextdecomposition.cxx @@ -178,6 +178,7 @@ namespace { if(!rInfo.maText.isEmpty() && rInfo.mnTextLen) { + OUString caseMappedText = rInfo.mrFont.CalcCaseMap( rInfo.maText ); basegfx::B2DVector aFontScaling; drawinglayer::attribute::FontAttribute aFontAttribute( drawinglayer::primitive2d::getFontAttributeFromVclFont( @@ -329,7 +330,7 @@ namespace // attributes for TextSimplePortionPrimitive2D aNewTransform, - rInfo.maText, + caseMappedText, rInfo.mnTextStart, rInfo.mnTextLen, aDXArray, @@ -356,7 +357,7 @@ namespace // TextSimplePortionPrimitive2D is enough pNewPrimitive = new drawinglayer::primitive2d::TextSimplePortionPrimitive2D( aNewTransform, - rInfo.maText, + caseMappedText, rInfo.mnTextStart, rInfo.mnTextLen, aDXArray, diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx index a2369dc9a87a..68998469994b 100644 --- a/svx/source/tbxctrls/tbcontrl.cxx +++ b/svx/source/tbxctrls/tbcontrl.cxx @@ -73,6 +73,8 @@ #include #include #include +#include +#include #include "svx/drawitem.hxx" #include #include "svx/dlgutil.hxx" @@ -628,6 +630,10 @@ void SvxStyleBox_Impl::UserDraw( const UserDrawEvent& rUDEvt ) if ( pItem ) aFont.SetStrikeout( static_cast< const SvxCrossedOutItem* >( pItem )->GetStrikeout() ); + pItem = aItemSet.GetItem( SID_ATTR_CHAR_CASEMAP ); + if ( pItem ) + ((SvxFont &)aFont).SetCaseMap( static_cast< const SvxCaseMapItem* >( pItem )->GetCaseMap() ); + pItem = aItemSet.GetItem( SID_ATTR_CHAR_EMPHASISMARK ); if ( pItem ) aFont.SetEmphasisMark( static_cast< const SvxEmphasisMarkItem* >( pItem )->GetEmphasisMark() ); diff --git a/svx/source/unodraw/unoprov.cxx b/svx/source/unodraw/unoprov.cxx index 4972b49a5337..7a7abf07057d 100644 --- a/svx/source/unodraw/unoprov.cxx +++ b/svx/source/unodraw/unoprov.cxx @@ -585,6 +585,7 @@ SfxItemPropertyMapEntry const * ImplGetSvxControlShapePropertyMap() { OUString(UNO_NAME_EDIT_CHAR_WEIGHT), 0, ::getCppuType((const float*)0), 0, 0 }, { OUString(UNO_NAME_EDIT_CHAR_UNDERLINE), 0, ::getCppuType((const sal_Int16*)0), 0, 0 }, { OUString(UNO_NAME_EDIT_CHAR_STRIKEOUT), 0, ::getCppuType((const sal_Int16*)0), 0, 0}, + { OUString(UNO_NAME_EDIT_CHAR_CASEMAP), 0, ::getCppuType((const sal_Int16*)0), 0, 0 }, { OUString(UNO_NAME_EDIT_CHAR_COLOR), 0, ::getCppuType((const sal_Int32*)0), 0, 0 }, { OUString("CharRelief"), 0, ::getCppuType((const sal_Int16*)0), 0, 0 }, { OUString("CharUnderlineColor"), 0, ::getCppuType((const sal_Int32*)0), 0, 0 }, -- cgit