diff options
author | 2014-06-22 22:18:14 -0700 | |
---|---|---|
committer | 2014-06-22 22:18:14 -0700 | |
commit | 196af738027c5e18c3eb792dbcaf90ef27821793 (patch) | |
tree | fed1ded62e61a247554117f3722429dcc63f978d /include/core | |
parent | 1c4d5784f9957143e86a7455e64ea6ac9661bb9e (diff) |
Fix SkPaint::measureText for stroked hairline text
SkPaint::measureText and text drawing used different criteria for
determining whether text should be drawn as paths or not.
Adds tests glyph_pos_(h/n)_(s/f/b) to test the text rendering and the glyph
positioning in the rendering. Mainly added in order to define what is the
expected text rendering when hairline stroke is used with various transform
options.
The testcase also tries to note or highlight the fact that SkPaint::measureText
is not expected to produce intuitively matching results when compared to a
rendering, if the rendering is done so that the device ends up having a device
transform.
This fixes the glyph_pos_h_s (hairline, stroked) test-case.
Ignore shadertext2_pdf-poppler.png gm on
Test-Ubuntu13.10-ShuttleA-NoGPU-x86_64-Debug temporarily, as that fails.
R=jvanverth@google.com, reed@google.com
Author: kkinnunen@nvidia.com
Review URL: https://codereview.chromium.org/335603003
Diffstat (limited to 'include/core')
-rw-r--r-- | include/core/SkPaint.h | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/include/core/SkPaint.h b/include/core/SkPaint.h index f766ca1c7f..a73faec42e 100644 --- a/include/core/SkPaint.h +++ b/include/core/SkPaint.h @@ -1117,9 +1117,6 @@ private: static bool TooBigToUseCache(const SkMatrix& ctm, const SkMatrix& textM); - bool tooBigToUseCache() const; - bool tooBigToUseCache(const SkMatrix& ctm) const; - // Set flags/hinting/textSize up to use for drawing text as paths. // Returns scale factor to restore the original textSize, since will will // have change it to kCanonicalTextSizeForPaths. |