summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-01-13 11:33:58 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-01-13 11:33:58 +0000
commit9407f45186dde4be86ed6f8360098903da79b730 (patch)
treee47681e826b9a92743a14fbbfe496c85d467d69c /vcl
parent77e7702250359f9398737e3a4af1bb9b4cc9c1c9 (diff)
longparas: STRING_LEN here means text len, so expand to just that
Change-Id: Iec55f8976ca180e380c9679c561aae61c0607520
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/control/fixed.cxx2
-rw-r--r--vcl/source/gdi/outdev3.cxx9
-rw-r--r--vcl/source/gdi/pdfwriter_impl.cxx4
3 files changed, 7 insertions, 8 deletions
diff --git a/vcl/source/control/fixed.cxx b/vcl/source/control/fixed.cxx
index 165391654001..76a5dc93182d 100644
--- a/vcl/source/control/fixed.cxx
+++ b/vcl/source/control/fixed.cxx
@@ -622,7 +622,7 @@ void FixedLine::ImplDraw( bool bLayout )
aStartPt.Y() -= (aOutSize.Height() - nWidth)/2;
Point aTextPt( aStartPt );
aTextPt.X() -= GetTextHeight()/2;
- DrawText( aTextPt, aText, 0, STRING_LEN, pVector, pDisplayText );
+ DrawText( aTextPt, aText, 0, aText.getLength(), pVector, pDisplayText );
Pop();
if( aOutSize.Height() - aStartPt.Y() > FIXEDLINE_TEXT_BORDER )
aDecoView.DrawSeparator( Point( aStartPt.X(), aOutSize.Height()-1 ),
diff --git a/vcl/source/gdi/outdev3.cxx b/vcl/source/gdi/outdev3.cxx
index 0ba187bb979a..0509349f076d 100644
--- a/vcl/source/gdi/outdev3.cxx
+++ b/vcl/source/gdi/outdev3.cxx
@@ -3918,7 +3918,7 @@ void OutputDevice::ImplDrawStrikeoutChar( long nBaseX, long nBaseY,
// strikeout text has to be left aligned
sal_uLong nOrigTLM = mnTextLayoutMode;
mnTextLayoutMode = TEXT_LAYOUT_BIDI_STRONG | TEXT_LAYOUT_COMPLEX_DISABLED;
- pLayout = ImplLayout( aStrikeoutText, 0, STRING_LEN );
+ pLayout = ImplLayout( aStrikeoutText, 0, aStrikeoutText.getLength() );
mnTextLayoutMode = nOrigTLM;
if( !pLayout )
@@ -5501,7 +5501,6 @@ void OutputDevice::DrawTextArray( const Point& rStartPt, const OUString& rStr,
long OutputDevice::GetTextArray( const OUString& rStr, sal_Int32* pDXAry,
sal_Int32 nIndex, sal_Int32 nLen ) const
{
- // MEM: default nLen = STRING_LENGTH
if(nLen == 0x0FFFF)
{
SAL_INFO("sal.rtl.xub",
@@ -6247,7 +6246,7 @@ void OutputDevice::ImplDrawText( OutputDevice& rTargetDevice, const Rectangle& r
// If there still is a last line, we output it left-aligned as the line would be clipped
if ( !aLastLine.isEmpty() )
- _rLayout.DrawText( aPos, aLastLine, 0, STRING_LEN, pVector, pDisplayText );
+ _rLayout.DrawText( aPos, aLastLine, 0, aLastLine.getLength(), pVector, pDisplayText );
// Reset clipping
if ( nStyle & TEXT_DRAW_CLIP )
@@ -6312,7 +6311,7 @@ void OutputDevice::ImplDrawText( OutputDevice& rTargetDevice, const Rectangle& r
{
rTargetDevice.Push( PUSH_CLIPREGION );
rTargetDevice.IntersectClipRegion( rRect );
- _rLayout.DrawText( aPos, aStr, 0, STRING_LEN, pVector, pDisplayText );
+ _rLayout.DrawText( aPos, aStr, 0, aStr.getLength(), pVector, pDisplayText );
if ( bDrawMnemonics )
{
if ( nMnemonicPos != -1 )
@@ -6322,7 +6321,7 @@ void OutputDevice::ImplDrawText( OutputDevice& rTargetDevice, const Rectangle& r
}
else
{
- _rLayout.DrawText( aPos, aStr, 0, STRING_LEN, pVector, pDisplayText );
+ _rLayout.DrawText( aPos, aStr, 0, aStr.getLength(), pVector, pDisplayText );
if ( bDrawMnemonics )
{
if ( nMnemonicPos != -1 )
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index 14e92f5a09a1..6e4a42017fd9 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -7969,7 +7969,7 @@ void PDFWriterImpl::drawText( const Rectangle& rRect, const OUString& rOrigStr,
// output last line left adjusted since it was shortened
if (!aLastLine.isEmpty())
- drawText( aPos, aLastLine, 0, STRING_LEN, bTextLines );
+ drawText( aPos, aLastLine, 0, aLastLine.getLength(), bTextLines );
}
}
else
@@ -8002,7 +8002,7 @@ void PDFWriterImpl::drawText( const Rectangle& rRect, const OUString& rOrigStr,
// mnemonics should be inserted here if the need arises
// draw the actual text
- drawText( aPos, aStr, 0, STRING_LEN, bTextLines );
+ drawText( aPos, aStr, 0, aStr.getLength(), bTextLines );
}
// reset clip region to original value