diff options
author | Chris Craik <ccraik@google.com> | 2012-10-02 16:53:55 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-10-02 16:53:55 -0700 |
commit | e70c8a5ad2ef1ce0804b27608fd96b825fc4ee95 (patch) | |
tree | eb1b7657722eff7f3def50a687872b7b68f0986c /Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp | |
parent | 42326004062d6b846c3050ad03a1e80fa9db425c (diff) | |
parent | 85fb59060a0fdfcff93ae1c70dd49e0f93e55ab6 (diff) | |
download | external_webkit-e70c8a5ad2ef1ce0804b27608fd96b825fc4ee95.zip external_webkit-e70c8a5ad2ef1ce0804b27608fd96b825fc4ee95.tar.gz external_webkit-e70c8a5ad2ef1ce0804b27608fd96b825fc4ee95.tar.bz2 |
Merge "Compensate for canvas-side vertical text translation in bounding box computation" into jb-mr1-dev
Diffstat (limited to 'Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp')
-rw-r--r-- | Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp b/Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp index c865a54..a410ba9 100644 --- a/Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp +++ b/Source/WebCore/platform/graphics/android/context/PlatformGraphicsContextRecording.cpp @@ -917,6 +917,8 @@ void PlatformGraphicsContextRecording::drawPosText(const void* inText, size_t by return; } FloatRect bounds = approximateTextBounds(byteLength / sizeof(uint16_t), inPos, inPaint); + bounds.move(m_textOffset); // compensate font rendering-side translates + const SkPaint* paint = mRecording->recording()->getSkPaint(inPaint); size_t posSize = sizeof(SkPoint) * paint->countText(inText, byteLength); void* text = heap()->alloc(byteLength); |