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

Unified Diff: ash/common/ash_typography.h

Issue 2801583002: Use views::style for buttons, bootstrap ash_typography to do so. (Closed)
Patch Set: More self review Created 3 years, 8 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: ash/common/ash_typography.h
diff --git a/ash/common/ash_typography.h b/ash/common/ash_typography.h
new file mode 100644
index 0000000000000000000000000000000000000000..3f42fcae40c94ccf79d9c68fbc6b987bb4117ba2
--- /dev/null
+++ b/ash/common/ash_typography.h
@@ -0,0 +1,40 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef ASH_COMMON_ASH_TYPOGRAPHY_H_
+#define ASH_COMMON_ASH_TYPOGRAPHY_H_
+
+#include "ash/ash_export.h"
+#include "ui/gfx/font.h"
+#include "ui/views/style/typography.h"
+
+namespace ash {
+
+enum AshTextContext {
+ ASH_TEXT_CONTEXT_START = views::style::VIEWS_TEXT_CONTEXT_END,
+
+ // A button that appears in the launcher's status area.
+ CONTEXT_LAUNCHER_BUTTON = ASH_TEXT_CONTEXT_START,
+
+ // Buttons and labels that appear in the fullscreen toast overlay UI.
+ CONTEXT_TOAST_OVERLAY,
+
+ ASH_TEXT_CONTEXT_END
+};
+
+enum AshTextStyle {
Peter Kasting 2017/04/08 01:38:54 Do you need to add this enum at all? It seems lik
tapted 2017/04/10 12:27:33 removed.
+ ASH_TEXT_STYLE_START = views::style::VIEWS_TEXT_STYLE_END,
+ ASH_TEXT_STYLE_END
+};
+
+// Sets the |size_delta| and |font_weight| for ash-specific text contexts.
+// Values are only set for contexts specific to ash.
+void ASH_EXPORT GetDefaultAshFont(int context,
+ int style,
+ int* size_delta,
+ gfx::Font::Weight* font_weight);
+
+} // namespace ash
+
+#endif // ASH_COMMON_ASH_TYPOGRAPHY_H_

Powered by Google App Engine
This is Rietveld 408576698