Update path of checkdeps to buildtools checkout
[chromium-blink-merge.git] / ui / message_center / message_center_style.h
blob738464ccffc5075148b74db15daf467afe9c3a51
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_
6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_
8 #include "base/basictypes.h"
9 #include "third_party/skia/include/core/SkColor.h"
10 #include "ui/gfx/size.h"
11 #include "ui/message_center/message_center_export.h"
13 namespace message_center {
15 // Exported values /////////////////////////////////////////////////////////////
17 // Square image sizes in DIPs.
18 const int kNotificationButtonIconSize = 16;
19 const int kNotificationIconSize = 80;
20 // A border is applied to images that have a non-preferred aspect ratio.
21 const int kNotificationImageBorderSize = 10;
22 const int kNotificationPreferredImageWidth = 360;
23 const int kNotificationPreferredImageHeight = 240;
24 const int kSettingsIconSize = 16;
25 const int kSmallImageSize = 16;
26 const int kSmallImagePadding = 4;
28 // Limits.
29 const size_t kMaxVisibleMessageCenterNotifications = 100;
30 const size_t kMaxVisiblePopupNotifications = 3;
32 // DIP dimension; H size of the whole card.
33 const int kNotificationWidth = 360;
34 const int kMinScrollViewHeight = 100;
36 // Colors.
37 MESSAGE_CENTER_EXPORT extern const SkColor kMessageCenterBorderColor;
38 MESSAGE_CENTER_EXPORT extern const SkColor kMessageCenterShadowColor;
40 // Settings dialog constants.
41 namespace settings {
43 const SkColor kEntrySeparatorColor = SkColorSetARGB(0.1 * 255, 0, 0, 0);
44 const int kEntryHeight = 45;
45 const int kEntrySeparatorHeight = 1;
46 const int kHorizontalMargin = 10;
47 const int kTopMargin = 20;
48 const int kTitleToDescriptionSpace = 20;
49 const int kEntryIconSize = 16;
50 const int kDescriptionToSwitcherSpace = 15;
51 const int kInternalHorizontalSpacing = 10;
52 const int kCheckboxSizeWithPadding = 24;
54 } // namespace settings
56 // Within a notification ///////////////////////////////////////////////////////
58 // DIP dimensions (H = horizontal, V = vertical).
60 const int kControlButtonSize = 29; // Square size of close & expand buttons.
61 const int kIconToTextPadding = 16; // H space between icon & title/message.
62 const int kTextTopPadding = 12; // V space between text elements.
63 const int kIconBottomPadding = 16; // Minimum non-zero V space between icon
64 // and frame.
66 // Text sizes.
67 const int kTitleFontSize = 14; // For title only.
68 const int kEmptyCenterFontSize = 13; // For empty message only.
69 const int kTitleLineHeight = 20; // In DIPs.
70 const int kMessageFontSize = 12; // For everything but title.
71 const int kMessageLineHeight = 18; // In DIPs.
73 // Colors.
74 extern const SkColor kNotificationBackgroundColor; // Background of the card.
75 extern const SkColor kImageBackgroundColor; // Background of the image.
76 extern const SkColor kIconBackgroundColor; // Used behind icons smaller
77 // than the icon view.
78 extern const SkColor kRegularTextColor; // Title, message, ...
79 extern const SkColor kDimTextColor;
80 extern const SkColor kFocusBorderColor; // The focus border.
82 // Limits.
84 // Given the size of an image, returns the size of the properly scaled-up image
85 // which fits into |container_size|.
86 gfx::Size GetImageSizeForContainerSize(const gfx::Size& container_size,
87 const gfx::Size& image_size);
89 extern const int kNotificationMaximumImageHeight; // For image notifications.
90 extern const size_t kNotificationMaximumItems; // For list notifications.
92 // Timing.
93 extern const int kAutocloseDefaultDelaySeconds;
94 extern const int kAutocloseHighPriorityDelaySeconds;
96 // Buttons.
97 const int kButtonHeight = 38; // In DIPs.
98 const int kButtonHorizontalPadding = 16; // In DIPs.
99 const int kButtonIconTopPadding = 11; // In DIPs.
100 const int kButtonIconToTitlePadding = 16; // In DIPs.
102 #if !defined(OS_LINUX) || defined(USE_AURA)
103 const SkColor kButtonSeparatorColor = SkColorSetRGB(234, 234, 234);
104 const SkColor kHoveredButtonBackgroundColor = SkColorSetRGB(243, 243, 243);
105 #endif
107 // Progress bar.
108 const int kProgressBarThickness = 5;
109 const int kProgressBarTopPadding = 16;
110 const int kProgressBarCornerRadius = 3;
111 const SkColor kProgressBarBackgroundColor = SkColorSetRGB(216, 216, 216);
112 const SkColor kProgressBarSliceColor = SkColorSetRGB(120, 120, 120);
114 // Line limits.
115 const int kMaxTitleLines = 2;
116 const int kMessageCollapsedLineLimit = 2;
117 const int kMessageExpandedLineLimit = 5;
118 const int kContextMessageLineLimit = 1;
120 // Around notifications ////////////////////////////////////////////////////////
122 // DIP dimensions (H = horizontal, V = vertical).
123 const int kMarginBetweenItems = 10; // H & V space around & between
124 // notifications.
126 // Colors.
127 extern const SkColor kBackgroundLightColor; // Behind notifications, gradient
128 extern const SkColor kBackgroundDarkColor; // from light to dark.
130 extern const SkColor kShadowColor; // Shadow in the tray.
132 extern const SkColor kMessageCenterBackgroundColor;
133 extern const SkColor kFooterDelimiterColor; // Separator color for the tray.
134 extern const SkColor kFooterTextColor; // Text color for tray labels.
136 } // namespace message_center
138 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_