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

Issue 152073003: Adding code to calculate Underline Thickness from Font Metrics, this will be useful when Skia is us… (Closed)

Created:
6 years, 10 months ago by h.joshi
Modified:
6 years, 9 months ago
CC:
skia-review_googlegroups.com
Base URL:
https://skia.googlesource.com/skia.git@master
Visibility:
Public.

Description

Adding code to calculate Underline Thickness from Font Metrics, this will be useful when Skia is used with Blink/Chrome. Blink changes are uploaded with code change in patch https://codereview.chromium.org/147703002/ BUG=skia: Committed: http://code.google.com/p/skia/source/detail?r=13635

Patch Set 1 #

Total comments: 2

Patch Set 2 : Comment fix and addition of underline position #

Total comments: 2

Patch Set 3 : Fixing comments, adding bitfield to FontMetrics #

Total comments: 10

Patch Set 4 : Adding Bitfield to Font Metrics Structure #

Total comments: 8

Patch Set 5 : Fixing comments for Underline patch #

Total comments: 18

Patch Set 6 : Fixing comments for Underline patch #

Total comments: 7

Patch Set 7 : Fixing comments for Underline Patch #

Total comments: 8

Patch Set 8 : Fixing comments #

Total comments: 2

Patch Set 9 : Fixing comments, updating comments for Underline position in Header #

Total comments: 6

Patch Set 10 : Fixing comments and making Underline position as per Skia terms #

Patch Set 11 : Updating AUTHORS file #

Patch Set 12 : Updating files as per HEAD #

Unified diffs Side-by-side diffs Delta from patch set Stats (+100 lines, -2 lines) Patch
M AUTHORS View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -0 lines 0 comments Download
M include/core/SkPaint.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +45 lines, -2 lines 0 comments Download
M src/core/SkPaint.cpp View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -0 lines 0 comments Download
M src/ports/SkFontHost_FreeType.cpp View 1 2 3 4 5 6 7 8 9 10 11 5 chunks +27 lines, -0 lines 0 comments Download
M src/ports/SkFontHost_mac.cpp View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M src/ports/SkFontHost_win.cpp View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +10 lines, -0 lines 0 comments Download
M src/ports/SkFontHost_win_dw.cpp View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +10 lines, -0 lines 0 comments Download

Messages

Total messages: 59 (0 generated)
h.joshi
While reading Font metrics Skia is not storing Underline thinkness which is useful while drawing ...
6 years, 10 months ago (2014-02-01 05:50:04 UTC) #1
h.joshi
On 2014/02/01 05:50:04, h.joshi wrote: > While reading Font metrics Skia is not storing Underline ...
6 years, 10 months ago (2014-02-08 05:04:09 UTC) #2
mtklein
lgtm, with the big caveat that I have little knowledge or opinion here. You want ...
6 years, 10 months ago (2014-02-10 18:42:37 UTC) #3
bungeman-skia
https://codereview.chromium.org/152073003/diff/1/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/1/include/core/SkPaint.h#newcode745 include/core/SkPaint.h:745: SkScalar fUnderlineThickness; //!< underline thickness only for scalable fonts ...
6 years, 10 months ago (2014-02-10 19:06:21 UTC) #4
h.joshi
Will work on shared comments. https://codereview.chromium.org/152073003/diff/1/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/1/include/core/SkPaint.h#newcode745 include/core/SkPaint.h:745: SkScalar fUnderlineThickness; //!< underline ...
6 years, 10 months ago (2014-02-11 04:41:59 UTC) #5
h.joshi
On 2014/02/11 04:41:59, h.joshi wrote: > Will work on shared comments. > > https://codereview.chromium.org/152073003/diff/1/include/core/SkPaint.h > ...
6 years, 10 months ago (2014-02-11 06:05:05 UTC) #6
bungeman-skia
lgtm @reed: I think we should get your lgtm on the SkPaint.h changes.
6 years, 10 months ago (2014-02-11 15:23:08 UTC) #7
reed1
https://codereview.chromium.org/152073003/diff/110001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/110001/include/core/SkPaint.h#newcode745 include/core/SkPaint.h:745: SkScalar fUnderlineThickness; //!< underline thickness, or 0 if cannot ...
6 years, 10 months ago (2014-02-11 15:59:52 UTC) #8
h.joshi
https://codereview.chromium.org/152073003/diff/110001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/110001/include/core/SkPaint.h#newcode745 include/core/SkPaint.h:745: SkScalar fUnderlineThickness; //!< underline thickness, or 0 if cannot ...
6 years, 10 months ago (2014-02-12 17:20:59 UTC) #9
h.joshi
Made code changes and added bit field pls check. On 2014/02/11 15:59:52, reed1 wrote: > ...
6 years, 10 months ago (2014-02-12 17:21:45 UTC) #10
reed1
https://codereview.chromium.org/152073003/diff/170001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/170001/include/core/SkPaint.h#newcode736 include/core/SkPaint.h:736: enum FontMetricsBitSet { Skia convention would name this FontMetricsFlags, ...
6 years, 10 months ago (2014-02-12 17:29:07 UTC) #11
h.joshi
Will submit new patch with suggested changes. https://codereview.chromium.org/152073003/diff/170001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/170001/include/core/SkPaint.h#newcode736 include/core/SkPaint.h:736: enum FontMetricsBitSet ...
6 years, 10 months ago (2014-02-13 02:23:52 UTC) #12
h.joshi
https://codereview.chromium.org/152073003/diff/170001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/170001/include/core/SkPaint.h#newcode740 include/core/SkPaint.h:740: kFontMetrics_Bottom = 1 << 4, //!< Bit flag for ...
6 years, 10 months ago (2014-02-13 02:43:19 UTC) #13
h.joshi
Added Bitfield and removed check for other FontMetrics fields. Pls review. On 2014/02/13 02:43:19, h.joshi ...
6 years, 10 months ago (2014-02-14 15:36:52 UTC) #14
bungeman-skia
https://codereview.chromium.org/152073003/diff/370001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/370001/include/core/SkPaint.h#newcode734 include/core/SkPaint.h:734: /** Describes defined to identify which values are unknown, ...
6 years, 10 months ago (2014-02-17 19:10:05 UTC) #15
h.joshi
Thank you, will be working on comments. https://codereview.chromium.org/152073003/diff/370001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/370001/include/core/SkPaint.h#newcode734 include/core/SkPaint.h:734: /** Describes ...
6 years, 10 months ago (2014-02-18 05:48:48 UTC) #16
h.joshi
Added new patch with fixes for comments shared, pls review. On 2014/02/18 05:48:48, h.joshi wrote: ...
6 years, 10 months ago (2014-02-19 07:40:02 UTC) #17
bungeman-skia
At PS5 this is looking much better to me. However, there are still a few ...
6 years, 10 months ago (2014-02-19 15:39:16 UTC) #18
h.joshi
Will make suggested changes. https://codereview.chromium.org/152073003/diff/480001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/480001/include/core/SkPaint.h#newcode758 include/core/SkPaint.h:758: @param fObject Pointer of FontMetrics ...
6 years, 10 months ago (2014-02-19 17:12:03 UTC) #19
h.joshi
Code added with suggested changes, pls review. On 2014/02/19 17:12:03, h.joshi wrote: > Will make ...
6 years, 10 months ago (2014-02-19 17:39:28 UTC) #20
bungeman-skia
PS6 lgtm reed, take another look?
6 years, 10 months ago (2014-02-19 18:09:25 UTC) #21
reed1
much simpler/cleaner, thanks. It seems odd to have a public uint32 and getters/setters. A couple ...
6 years, 10 months ago (2014-02-19 22:42:44 UTC) #22
h.joshi
Hi, I have few doubts: 1. with "just expose the uint32" do you mean to ...
6 years, 10 months ago (2014-02-20 02:08:40 UTC) #23
bungeman-skia
Here's one suggestion for what I might like to see. reed, does this sound good ...
6 years, 10 months ago (2014-02-20 16:52:46 UTC) #24
reed1
I think I'd be fine with... uint32_t fFlags; enum Flags { kUnderlineThicknessValid_Flag = 1 << ...
6 years, 10 months ago (2014-02-21 21:25:03 UTC) #25
h.joshi
New patch is added after fixing suggested changes, pls review. On 2014/02/21 21:25:03, reed1 wrote: ...
6 years, 10 months ago (2014-02-22 05:19:39 UTC) #26
reed1
https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h#newcode738 include/core/SkPaint.h:738: kUnderlineThinknessIsValid_Flag = 0x01, tiny nit: Since we're using 1 ...
6 years, 10 months ago (2014-02-24 13:26:21 UTC) #27
h.joshi
Comments have been fixed, added new patch with comment fixed. If the thickness is 2 ...
6 years, 10 months ago (2014-02-24 18:19:23 UTC) #28
h.joshi
All comments have been fixed, pls review. https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h#newcode738 include/core/SkPaint.h:738: kUnderlineThinknessIsValid_Flag = ...
6 years, 10 months ago (2014-02-24 18:21:44 UTC) #29
h.joshi
https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h#newcode754 include/core/SkPaint.h:754: SkScalar fUnderlineThickness; //!< underline thickness, or 0 if cannot ...
6 years, 10 months ago (2014-02-24 18:22:38 UTC) #30
reed1
On 2014/02/24 18:22:38, h.joshi wrote: > https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h > File include/core/SkPaint.h (right): > > https://codereview.chromium.org/152073003/diff/750001/include/core/SkPaint.h#newcode754 > ...
6 years, 10 months ago (2014-02-24 18:29:56 UTC) #31
reed1
https://codereview.chromium.org/152073003/diff/800001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/800001/include/core/SkPaint.h#newcode767 include/core/SkPaint.h:767: *thickness = 0; don't change thickness if we return ...
6 years, 10 months ago (2014-02-24 18:30:09 UTC) #32
h.joshi
Made changes as per On 2014/02/24 18:30:09, reed1 wrote: > https://codereview.chromium.org/152073003/diff/800001/include/core/SkPaint.h > File include/core/SkPaint.h (right): ...
6 years, 10 months ago (2014-02-25 02:25:49 UTC) #33
h.joshi
Made changes as per suggestion, pls review. On 2014/02/24 18:30:09, reed1 wrote: > https://codereview.chromium.org/152073003/diff/800001/include/core/SkPaint.h > ...
6 years, 10 months ago (2014-02-25 02:26:05 UTC) #34
reed1
much better, thanks. lgtm w/ style nits https://codereview.chromium.org/152073003/diff/880001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/880001/include/core/SkPaint.h#newcode756 include/core/SkPaint.h:756: /** Underline ...
6 years, 10 months ago (2014-02-25 13:16:50 UTC) #35
h.joshi
https://codereview.chromium.org/152073003/diff/880001/include/core/SkPaint.h File include/core/SkPaint.h (right): https://codereview.chromium.org/152073003/diff/880001/include/core/SkPaint.h#newcode756 include/core/SkPaint.h:756: /** Underline Position - position of the top of ...
6 years, 10 months ago (2014-02-25 18:11:10 UTC) #36
h.joshi
New Patch added with suggested changes, pls review. On 2014/02/25 18:11:10, h.joshi wrote: > https://codereview.chromium.org/152073003/diff/880001/include/core/SkPaint.h ...
6 years, 10 months ago (2014-02-25 18:11:40 UTC) #37
h.joshi
In new patch, underline position is made negative of the value we get from font ...
6 years, 10 months ago (2014-02-26 05:18:19 UTC) #38
h.joshi
Hi, Is code good to go, should I start with commit process pls suggest On ...
6 years, 9 months ago (2014-02-28 16:00:33 UTC) #39
reed1
The CQ bit was checked by reed@google.com
6 years, 9 months ago (2014-02-28 16:11:55 UTC) #40
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://skia-tree-status.appspot.com/cq/h.joshi@samsung.com/152073003/900001
6 years, 9 months ago (2014-02-28 16:11:59 UTC) #41
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-02-28 16:12:04 UTC) #42
commit-bot: I haz the power
Presubmit check for 152073003-900001 failed and returned exit status 1. Running presubmit commit checks ...
6 years, 9 months ago (2014-02-28 16:12:05 UTC) #43
reed1
6 years, 9 months ago (2014-02-28 16:13:59 UTC) #44
hcm
On 2014/02/28 16:13:59, reed1 wrote: I verified that h.joshi was listed in the Samsung Corporate ...
6 years, 9 months ago (2014-02-28 16:21:26 UTC) #45
h.joshi
Updated AUTHORS files On 2014/02/28 16:21:26, hcm wrote: > On 2014/02/28 16:13:59, reed1 wrote: > ...
6 years, 9 months ago (2014-03-01 03:02:01 UTC) #46
h.joshi
The CQ bit was checked by h.joshi@samsung.com
6 years, 9 months ago (2014-03-01 03:02:43 UTC) #47
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://skia-tree-status.appspot.com/cq/h.joshi@samsung.com/152073003/920001
6 years, 9 months ago (2014-03-01 03:02:58 UTC) #48
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-01 03:03:00 UTC) #49
commit-bot: I haz the power
Failed to apply patch for AUTHORS: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 9 months ago (2014-03-01 03:03:01 UTC) #50
h.joshi
Hi, I have updated AUTHORS file, when tried to submit patch got error, pls suggest ...
6 years, 9 months ago (2014-03-01 03:10:35 UTC) #51
h.joshi
The CQ bit was checked by h.joshi@samsung.com
6 years, 9 months ago (2014-03-01 19:46:33 UTC) #52
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://skia-tree-status.appspot.com/cq/h.joshi@samsung.com/152073003/840002
6 years, 9 months ago (2014-03-01 19:46:43 UTC) #53
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-01 19:46:46 UTC) #54
commit-bot: I haz the power
Failed to apply patch for AUTHORS: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 9 months ago (2014-03-01 19:46:47 UTC) #55
h.joshi
The CQ bit was checked by h.joshi@samsung.com
6 years, 9 months ago (2014-03-01 19:58:56 UTC) #56
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://skia-tree-status.appspot.com/cq/h.joshi@samsung.com/152073003/950001
6 years, 9 months ago (2014-03-01 19:59:02 UTC) #57
commit-bot: I haz the power
Change committed as 13635
6 years, 9 months ago (2014-03-01 20:12:30 UTC) #58
h.joshi
6 years, 9 months ago (2014-03-02 06:32:52 UTC) #59
Message was sent while issue was closed.
Thank you, made changes to AUTHOR file and code is committed.

On 2014/03/01 20:12:30, I haz the power (commit-bot) wrote:
> Change committed as 13635

Powered by Google App Engine
This is Rietveld 408576698