Skip to content

Commit

Permalink
WebCore uses M_PI_2 instead of piOverTwoDouble
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=143758

Patch by Руслан Ижбулатов <lrn1986@gmail.com> on 2015-04-15
Reviewed by Darin Adler.

Because M_PI_2 is not defined everywhere.
Fixes errors like:
  CXX Source/WebCore/platform/graphics/freetype/libPlatformGtk_la-FontPlatformDataFreeType.lo
../webkitgtk-2.4.8/Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp: In function 'void WebCore::rotateCairoMatrixForVerticalOrientation(cairo_matrix_t*)':
../webkitgtk-2.4.8/Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp:123:34: error: 'M_PI_2' was not declared in this scope
     cairo_matrix_rotate(matrix, -M_PI_2);
                                  ^
GNUmakefile:51663: recipe for target 'Source/WebCore/platform/graphics/freetype/libPlatformGtk_la-FontPlatformDataFreeType.lo' failed

* platform/graphics/freetype/FontPlatformDataFreeType.cpp:
(WebCore::rotateCairoMatrixForVerticalOrientation):
  • Loading branch information
LRN authored and carlosgcampos committed May 19, 2015
1 parent 3d121ee commit 52b3236
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
18 changes: 18 additions & 0 deletions Source/WebCore/ChangeLog
@@ -1,5 +1,23 @@
2015-04-15 Руслан Ижбулатов <lrn1986@gmail.com>

WebCore uses M_PI_2 instead of piOverTwoDouble
https://bugs.webkit.org/show_bug.cgi?id=143758

Reviewed by Darin Adler.

Because M_PI_2 is not defined everywhere.
Fixes errors like:
CXX Source/WebCore/platform/graphics/freetype/libPlatformGtk_la-FontPlatformDataFreeType.lo
../webkitgtk-2.4.8/Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp: In function 'void WebCore::rotateCairoMatrixForVerticalOrientation(cairo_matrix_t*)':
../webkitgtk-2.4.8/Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp:123:34: error: 'M_PI_2' was not declared in this scope
cairo_matrix_rotate(matrix, -M_PI_2);
^
GNUmakefile:51663: recipe for target 'Source/WebCore/platform/graphics/freetype/libPlatformGtk_la-FontPlatformDataFreeType.lo' failed

* platform/graphics/freetype/FontPlatformDataFreeType.cpp:
(WebCore::rotateCairoMatrixForVerticalOrientation):
2015-04-15 Руслан Ижбулатов <lrn1986@gmail.com>

[GTK][W32] FileSystemGtk calls GetModuleHandleExA(), but does not include appropriate header
https://bugs.webkit.org/show_bug.cgi?id=143759

Expand Down
Expand Up @@ -120,7 +120,7 @@ static void rotateCairoMatrixForVerticalOrientation(cairo_matrix_t* matrix)
// combination of rotation (R) and translation (T) applied on the
// horizontal matrix (H). V = H . R . T, where R rotates by -90 degrees
// and T translates by font size towards y axis.
cairo_matrix_rotate(matrix, -M_PI_2);
cairo_matrix_rotate(matrix, -piOverTwoDouble);
cairo_matrix_translate(matrix, 0.0, 1.0);
}

Expand Down

0 comments on commit 52b3236

Please sign in to comment.