SkScalerContextRec::computeMatrices to return status.

When computing the matricies for a scaler context, there is a special
case when the matrix is determined to be singular. No port properly
handles zero sized text, so we detect this case and return a 'normal'
text size and a zero matrix for all computed transformations. This
CL causes computeMatricies to return 'false' in this case.

This is used in the constructor of SkScalerContext_Mac in order to
avoid calling CGAffineTransformInvert on non-invertible transformations.
CGAffineTransformInvert documents that if the transform is
non-invertible it will return the passed transform unchanged. It does
so, but then also prints a message to stdout. Since the information is
already available to avoid this chatty behavior, use it to keep things
quiet.

BUG=skia:3231,chromium:630169
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2276583003

Review-Url: https://codereview.chromium.org/2276583003
3 files changed