[GDIPLUS] Sync with Wine Staging 1.9.4. CORE-10912
[reactos.git] / reactos / dll / win32 / gdiplus / pen.c
index 0104d95..3f732eb 100644 (file)
@@ -159,6 +159,7 @@ GpStatus WINGDIPAPI GdipCreatePen2(GpBrush *brush, REAL width, GpUnit unit,
     gp_pen->offset = 0.0;
     gp_pen->customstart = NULL;
     gp_pen->customend = NULL;
+    GdipSetMatrixElements(&gp_pen->transform, 1.0, 0.0, 0.0, 1.0, 0.0, 0.0);
 
     if(!((gp_pen->unit == UnitWorld) || (gp_pen->unit == UnitPixel))) {
         FIXME("UnitWorld, UnitPixel only supported units\n");
@@ -406,17 +407,14 @@ GpStatus WINGDIPAPI GdipGetPenWidth(GpPen *pen, REAL *width)
 
 GpStatus WINGDIPAPI GdipResetPenTransform(GpPen *pen)
 {
-    static int calls;
-
     TRACE("(%p)\n", pen);
 
     if(!pen)
         return InvalidParameter;
 
-    if(!(calls++))
-        FIXME("(%p) stub\n", pen);
+    GdipSetMatrixElements(&pen->transform, 1.0, 0.0, 0.0, 1.0, 0.0, 0.0);
 
-    return NotImplemented;
+    return Ok;
 }
 
 GpStatus WINGDIPAPI GdipSetPenTransform(GpPen *pen, GpMatrix *matrix)
@@ -429,24 +427,23 @@ GpStatus WINGDIPAPI GdipSetPenTransform(GpPen *pen, GpMatrix *matrix)
         return InvalidParameter;
 
     if(!(calls++))
-        FIXME("not implemented\n");
+        FIXME("(%p,%p) Semi-stub\n", pen, matrix);
 
-    return NotImplemented;
+    pen->transform = *matrix;
+
+    return Ok;
 }
 
 GpStatus WINGDIPAPI GdipGetPenTransform(GpPen *pen, GpMatrix *matrix)
 {
-    static int calls;
-
     TRACE("(%p,%p)\n", pen, matrix);
 
     if(!pen || !matrix)
         return InvalidParameter;
 
-    if(!(calls++))
-        FIXME("not implemented\n");
+    *matrix = pen->transform;
 
-    return NotImplemented;
+    return Ok;
 }
 
 GpStatus WINGDIPAPI GdipTranslatePenTransform(GpPen *pen, REAL dx, REAL dy, GpMatrixOrder order)