From 1f670c3699f259f0a7e4a0cd1e7aa48be3388ee7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Trond=20Kjern=C3=A5sen?= Date: Thu, 11 Jun 2009 17:52:52 +0200 Subject: Fixed the pen dash patterns for Mac. The predefined dash patterns for Mac have always been off, compared to the ones in the raster engine and the GL engine. Task-number: 255292 Reviewed-by: Kim --- src/gui/painting/qpaintengine_mac.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/gui/painting/qpaintengine_mac.cpp b/src/gui/painting/qpaintengine_mac.cpp index 5889388..5a0e84a1 100644 --- a/src/gui/painting/qpaintengine_mac.cpp +++ b/src/gui/painting/qpaintengine_mac.cpp @@ -1496,23 +1496,23 @@ QCoreGraphicsPaintEnginePrivate::setStrokePen(const QPen &pen) for(int i = 0; i < customs.size(); ++i) linedashes.append(customs.at(i)); } else if(pen.style() == Qt::DashLine) { - linedashes.append(3); - linedashes.append(1); + linedashes.append(4); + linedashes.append(2); } else if(pen.style() == Qt::DotLine) { linedashes.append(1); - linedashes.append(1); + linedashes.append(2); } else if(pen.style() == Qt::DashDotLine) { - linedashes.append(3); - linedashes.append(1); - linedashes.append(1); + linedashes.append(4); + linedashes.append(2); linedashes.append(1); + linedashes.append(2); } else if(pen.style() == Qt::DashDotDotLine) { - linedashes.append(3); - linedashes.append(1); - linedashes.append(1); - linedashes.append(1); + linedashes.append(4); + linedashes.append(2); linedashes.append(1); + linedashes.append(2); linedashes.append(1); + linedashes.append(2); } const CGFloat cglinewidth = pen.widthF() <= 0.0f ? 1.0f : float(pen.widthF()); for(int i = 0; i < linedashes.size(); ++i) { -- cgit v0.12