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

Unified Diff: chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm

Issue 15553008: Instant Extended: Reduce clipping in omnibox (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm
diff --git a/chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm b/chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm
index 0d41fb108a938cb2140730f2ee7025cfd6bb0a2f..720aa681be8bcf7f7644172c1fa82ed6b18a3990 100644
--- a/chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm
+++ b/chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm
@@ -155,6 +155,12 @@ OmniboxViewMac::OmniboxViewMac(OmniboxEditController* controller,
layoutManager([[NSLayoutManager alloc] init]);
[layoutManager setUsesScreenFonts:YES];
line_height_ = [layoutManager defaultLineHeightForFont:GetFieldFont()];
+
+ // Extended instant uses a larger font so increase line height to reduce
+ // clipping.
Scott Hess - ex-Googler 2013/05/22 19:56:37 No, it's getting the line height from the font. I
sail 2013/05/22 20:23:55 The line height doesn't account for accents and st
Scott Hess - ex-Googler 2013/05/22 21:02:36 Yeah, but fields are doing this stuff somehow.
sail 2013/05/22 21:10:35 I'm not sure what this comment means.
+ if (chrome::IsInstantExtendedAPIEnabled())
+ line_height_ += 1;
+
DCHECK_GT(line_height_, 0);
}

Powered by Google App Engine
This is Rietveld 408576698