Letter spacing / Kerning discrepancy in Title text |
|||||
Issue descriptionActual: Bookmarks Title uses a 0 kerning Payments Title uses a -0.6 kerning (smaller) Expected: All title text should use the same kerning. Preferably it's the default setting that OSX provides with the given text-size. Avoid customized kerning.
,
May 15 2017
Yah, the system font on Mac comes with some custom kerning I think. There's some logic in PlatformFontMac that tries to preserve it.
The payments dialog is using
views::Label* title_label = new views::Label(title);
title_label->SetHorizontalAlignment(gfx::ALIGN_LEFT);
title_label->SetFontList(
title_label->GetDefaultFontList().DeriveWithSizeDelta(
ui::kTitleFontSizeDelta));
layout->AddView(title_label);
No dialog code should be invoking FontList::Derive* (it's slow) -- they should all use ResourceBundle (in the past) or, now, views::style::GetFont(CONTEXT_DIALOG_TITLE). I think this will fix it.. although I also don't immediately see a reason why they should differ :/
(Of course... ideally, the payments stuff also uses the title provided by DialogClientView)
,
May 22 2017
https://codereview.chromium.org/2899653002
,
May 23 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f commit 424d27cceaba0271bc21e9c9b48a39e4d5a2b21f Author: tapted <tapted@chromium.org> Date: Tue May 23 00:39:02 2017 Remove uses of FontList::Derive*(..) in views payments dialogs. FontList::Derive(..) is slow (typically requiring IPC with the font server), has unpredictable results with special UI fonts on Mac, and encourages use of magic numbers like "-1". Instead, use context and style constants from the Chrome typography spec, where available. When an equivalent font is not available, use ResourceBundle to avoid a behavior change in this CL. BUG= 721834 Review-Url: https://codereview.chromium.org/2899653002 Cr-Commit-Position: refs/heads/master@{#473764} [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/test/test_browser_dialog.cc [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/test/test_browser_dialog.h [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/editor_view_controller.cc [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/order_summary_view_controller.cc [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/payment_method_view_controller.cc [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/payment_request_browsertest.cc [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/payment_request_views_util.cc [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/payment_request_views_util.h [modify] https://crrev.com/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
,
May 23 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b commit ddc5e16ef9191ecf5f74c039ed8cebaf9390765b Author: cfroussios <cfroussios@chromium.org> Date: Tue May 23 08:36:56 2017 Revert of Remove uses of FontList::Derive*(..) in views payments dialogs. (patchset #4 id:60001 of https://codereview.chromium.org/2899653002/ ) Reason for revert: Breaks compilation see crbug.com/725407 Original issue's description: > Remove uses of FontList::Derive*(..) in views payments dialogs. > > FontList::Derive(..) is slow (typically requiring IPC with the font > server), has unpredictable results with special UI fonts on Mac, and > encourages use of magic numbers like "-1". > > Instead, use context and style constants from the Chrome typography > spec, where available. When an equivalent font is not available, use > ResourceBundle to avoid a behavior change in this CL. > > BUG= 721834 > > Review-Url: https://codereview.chromium.org/2899653002 > Cr-Commit-Position: refs/heads/master@{#473764} > Committed: https://chromium.googlesource.com/chromium/src/+/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f TBR=anthonyvd@chromium.org,pkasting@chromium.org,tapted@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG= 721834 Review-Url: https://codereview.chromium.org/2901763002 Cr-Commit-Position: refs/heads/master@{#473839} [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/test/test_browser_dialog.cc [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/test/test_browser_dialog.h [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/editor_view_controller.cc [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/order_summary_view_controller.cc [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/payment_method_view_controller.cc [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/payment_request_browsertest.cc [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/payment_request_views_util.cc [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/payment_request_views_util.h [modify] https://crrev.com/ddc5e16ef9191ecf5f74c039ed8cebaf9390765b/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
,
May 23 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a commit 17d6248cb822cf06ae06fccd65fbeebfa7b4af2a Author: tapted <tapted@chromium.org> Date: Tue May 23 11:35:49 2017 Remove uses of FontList::Derive*(..) in views payments dialogs. FontList::Derive(..) is slow (typically requiring IPC with the font server), has unpredictable results with special UI fonts on Mac, and encourages use of magic numbers like "-1". Instead, use context and style constants from the Chrome typography spec, where available. When an equivalent font is not available, use ResourceBundle to avoid a behavior change in this CL. BUG= 721834 Review-Url: https://codereview.chromium.org/2899653002 Cr-Original-Commit-Position: refs/heads/master@{#473764} Committed: https://chromium.googlesource.com/chromium/src/+/424d27cceaba0271bc21e9c9b48a39e4d5a2b21f Review-Url: https://codereview.chromium.org/2899653002 Cr-Commit-Position: refs/heads/master@{#473859} [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/test/test_browser_dialog.cc [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/test/test_browser_dialog.h [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/editor_view_controller.cc [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/order_summary_view_controller.cc [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/payment_method_view_controller.cc [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/payment_request_browsertest.cc [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/payment_request_views_util.cc [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/payment_request_views_util.h [modify] https://crrev.com/17d6248cb822cf06ae06fccd65fbeebfa7b4af2a/chrome/browser/ui/views/payments/payment_sheet_view_controller.cc
,
May 26 2017
Fixed. But the dialogs use bold/medium fonts in a variety of places. 10.9 and 10.11 only have a fully-bold system UI font installed by default. Also there is no bold or medium font in the harmony typography spec except for buttons - we should add one (and define what it should be on <10.12) if we want to keep this style for payments dialogs.
,
Jun 27 2017
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by pkasting@chromium.org
, May 12 2017