Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(341)

Issue 666303002: add getBounds to SkTypeface (Closed)

Created:
6 years, 2 months ago by reed2
Modified:
6 years, 2 months ago
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Project:
skia
Visibility:
Public.

Description

add getBounds to SkTypeface This uses SkLazyPtr, but to use it in a public header, I had to do move SkLazyPtr.h and SkThreadPriv.h into public :( To use SkLazyPtr from a const method, I had to change its private ptr to mutable

Patch Set 1 #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+164 lines, -196 lines) Patch
M gm/fontmgr.cpp View 2 chunks +91 lines, -0 lines 2 comments Download
A + include/core/SkLazyPtr.h View 1 chunk +3 lines, -3 lines 0 comments Download
A + include/core/SkThreadPriv.h View 0 chunks +-1 lines, --1 lines 0 comments Download
M include/core/SkTypeface.h View 4 chunks +17 lines, -3 lines 4 comments Download
D src/core/SkLazyPtr.h View 1 chunk +0 lines, -166 lines 0 comments Download
D src/core/SkThreadPriv.h View 1 chunk +0 lines, -23 lines 0 comments Download
M src/core/SkTypeface.cpp View 1 chunk +54 lines, -2 lines 0 comments Download

Messages

Total messages: 8 (4 generated)
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/666303002/1
6 years, 2 months ago (2014-10-22 04:04:12 UTC) #3
commit-bot: I haz the power
Note for Reviewers: The CQ is waiting for an approval. If you believe that the ...
6 years, 2 months ago (2014-10-22 04:04:13 UTC) #4
mtklein
lgtm https://codereview.chromium.org/666303002/diff/1/gm/fontmgr.cpp File gm/fontmgr.cpp (right): https://codereview.chromium.org/666303002/diff/1/gm/fontmgr.cpp#newcode249 gm/fontmgr.cpp:249: p.setColor(SK_ColorRED); Might be nice to alternate red and ...
6 years, 2 months ago (2014-10-22 14:46:19 UTC) #6
reed1
6 years, 2 months ago (2014-10-22 20:09:28 UTC) #8
abandoning in favor of https://codereview.chromium.org/676523002/

https://codereview.chromium.org/666303002/diff/1/gm/fontmgr.cpp
File gm/fontmgr.cpp (right):

https://codereview.chromium.org/666303002/diff/1/gm/fontmgr.cpp#newcode249
gm/fontmgr.cpp:249: p.setColor(SK_ColorRED);
On 2014/10/22 14:46:19, mtklein wrote:
> Might be nice to alternate red and another color so it's clear where the boxes
> land for each font.

Done.

https://codereview.chromium.org/666303002/diff/1/include/core/SkTypeface.h
File include/core/SkTypeface.h (right):

https://codereview.chromium.org/666303002/diff/1/include/core/SkTypeface.h#ne...
include/core/SkTypeface.h:288: *  of the glyphs, each one positioned at (0,).
This may be conservatively large, and
On 2014/10/22 14:46:19, mtklein wrote:
> and -> but?

Done.

https://codereview.chromium.org/666303002/diff/1/include/core/SkTypeface.h#ne...
include/core/SkTypeface.h:373: friend struct BoundsComputer;
On 2014/10/22 14:46:19, mtklein wrote:
> You might be able to get away without this friend declaration?  Can never
> remember how nested classes friend each other.

Done.

Powered by Google App Engine
This is Rietveld 408576698