File 0003-gdi32-fix-text-rotation.patch of Package wine

@@ -, +, @@ 
 mode.
---
 dlls/gdi32/font.c | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)
--- a/dlls/gdi32/font.c	
+++ a/dlls/gdi32/font.c	
@@ -1327,6 +1327,22 @@ BOOL WINAPI GetTextExtentExPointW( HDC hdc, LPCWSTR str, INT count, INT max_ext,
         }
     }
 
+    BOOL restore_transform = FALSE;
+    XFORM old;
+
+    if (GetGraphicsMode( hdc ) == GM_ADVANCED)
+    {
+        XFORM xf;
+        GetWorldTransform( hdc, &old );
+        xf = old;
+        if (xform_has_rotate_and_uniform_scale_and_shear( &xf ) &&
+            xform_decompose_rotation_and_translation( &xf, NULL ))
+        {
+            SetWorldTransform( hdc, &xf );
+            restore_transform = TRUE;
+        }
+    }
+
     ret = get_char_positions( dc, str, count, pos, size );
     if (ret)
     {
@@ -1348,6 +1364,11 @@ BOOL WINAPI GetTextExtentExPointW( HDC hdc, LPCWSTR str, INT count, INT max_ext,
     if (pos != buffer && pos != dxs) HeapFree( GetProcessHeap(), 0, pos );
     release_dc_ptr( dc );
 
+    if (restore_transform == TRUE)
+    {
+        SetWorldTransform( hdc, &old );
+    }
+
     TRACE("(%p, %s, %d) returning %dx%d\n", hdc, debugstr_wn(str,count), max_ext, size->cx, size->cy );
     return ret;
 }
--