summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorNorbert Thiebaud <nthiebaud@gmail.com>2013-12-17 05:18:35 -0600
committerNorbert Thiebaud <nthiebaud@gmail.com>2013-12-18 01:54:16 +0000
commit4c539fac018dfd44cd8db52161a8cb930c627da7 (patch)
treed7530d03926971e58584b64ce618984eb47baf74 /svx
parent8272ffb8ed00f211a8fbda71136d695b42249b70 (diff)
vcl get rid of xub_StrLen and STRING_LEN in outdev3
a new log section (sal.rtl.xub) is used to display alert in case of suspicious len == 0xFFFF (aka STRING_LEN) Change-Id: I3ed2aa7896e12592be9e003580dd6c8eda4add5e Reviewed-on: https://gerrit.libreoffice.org/7117 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/customshapes/EnhancedCustomShapeFontWork.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx b/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx
index 4d6cbdfd4213..e7a67faa93ef 100644
--- a/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx
+++ b/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx
@@ -283,9 +283,9 @@ void GetTextAreaOutline( const FWData& rFWData, const SdrObject* pCustomShape, F
{
FWCharacterData aCharacterData;
OUString aCharText( (sal_Unicode)rText[ i ] );
- if ( aVirDev.GetTextOutlines( aCharacterData.vOutlines, aCharText, 0, 0, STRING_LEN, sal_True, nWidth, pDXArry ) )
+ if ( aVirDev.GetTextOutlines( aCharacterData.vOutlines, aCharText, 0, 0, -1, sal_True, nWidth, pDXArry ) )
{
- sal_Int32 nTextWidth = aVirDev.GetTextWidth( aCharText, 0, STRING_LEN );
+ sal_Int32 nTextWidth = aVirDev.GetTextWidth( aCharText);
std::vector< PolyPolygon >::iterator aOutlineIter = aCharacterData.vOutlines.begin();
std::vector< PolyPolygon >::iterator aOutlineIEnd = aCharacterData.vOutlines.end();
if ( aOutlineIter == aOutlineIEnd )
@@ -335,13 +335,13 @@ void GetTextAreaOutline( const FWData& rFWData, const SdrObject* pCustomShape, F
if ( ( nCharScaleWidth != 100 ) && nCharScaleWidth )
{ // applying character spacing
pDXArry = new sal_Int32[ rText.getLength() ];
- aVirDev.GetTextArray( rText, pDXArry, 0, STRING_LEN );
+ aVirDev.GetTextArray( rText, pDXArry);
FontMetric aFontMetric( aVirDev.GetFontMetric() );
aFont.SetWidth( (sal_Int32)( (double)aFontMetric.GetWidth() * ( (double)100 / (double)nCharScaleWidth ) ) );
aVirDev.SetFont( aFont );
}
FWCharacterData aCharacterData;
- if ( aVirDev.GetTextOutlines( aCharacterData.vOutlines, rText, 0, 0, STRING_LEN, sal_True, nWidth, pDXArry ) )
+ if ( aVirDev.GetTextOutlines( aCharacterData.vOutlines, rText, 0, 0, -1, sal_True, nWidth, pDXArry ) )
{
aParagraphIter->vCharacters.push_back( aCharacterData );
}