[Libreoffice-commits] core.git: vcl/quartz
Stephan Bergmann
sbergman at redhat.com
Fri May 9 00:18:01 PDT 2014
vcl/quartz/ctlayout.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 51030a1a5e06cd22de7676715ae65f37e6ad5548
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Fri May 9 09:17:25 2014 +0200
Handle all-space corner case
Change-Id: I07981a63a30ac3d610be03e736188a6539884f01
diff --git a/vcl/quartz/ctlayout.cxx b/vcl/quartz/ctlayout.cxx
index 5c61150..7969991 100644
--- a/vcl/quartz/ctlayout.cxx
+++ b/vcl/quartz/ctlayout.cxx
@@ -175,7 +175,8 @@ void CTLayout::AdjustLayout( ImplLayoutArgs& rArgs )
if(rArgs.mpDXArray)
{
int nFullPixelWidth = nPixelWidth;
- nPixelWidth = rArgs.mpDXArray[ mnCharCount - mnTrailingSpaceCount - 1];
+ nPixelWidth = mnTrailingSpaceCount == mnCharCount
+ ? 0 : rArgs.mpDXArray[ mnCharCount - mnTrailingSpaceCount - 1];
mfTrailingSpaceWidth = nFullPixelWidth - nPixelWidth;
}
else
More information about the Libreoffice-commits
mailing list