2 * Copyright(c) 2020 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
20 using Tizen.NUI.BaseComponents;
21 using Tizen.NUI.Components.Extension;
23 namespace Tizen.NUI.Components
25 // It is a C# version of res/Tizen.NUI.Components_Tizen.NUI.Theme.Wearable.xaml
26 internal partial class DefaultThemeCreator : IThemeCreator
30 var theme = new Theme()
32 Id = Tizen.NUI.DefaultThemeCreator.DefaultId,
33 Version = Tizen.NUI.DefaultThemeCreator.DefaultVersion
36 theme.AddStyleWithoutClone("Tizen.NUI.Components.Popup", new PopupStyle()
38 Size = new Size(500, 280),
39 BackgroundColor = new Color(0.9f, 0.9f, 0.9f, 1),
40 ImageShadow = new ImageShadow()
42 Url = FrameworkInformation.ResourcePath + "nui_component_default_popup_shadow.png",
43 Border = new Rectangle(24, 24, 24, 24),
44 Extents = new Vector2(48, 48)
46 Title = new TextLabelStyle()
49 Padding = new Extents(20, 20, 20, 20),
51 Buttons = new ButtonStyle()
53 Size = new Size(0, 80),
54 BackgroundColor = new Selector<Color>()
56 Normal = new Color(1, 1, 1, 1),
57 Pressed = new Color(1, 1, 1, 0.5f),
59 Overlay = new ImageViewStyle()
61 BackgroundColor = new Selector<Color>()
63 Pressed = new Color(0, 0, 0, 0.1f),
64 Other = new Color(1, 1, 1, 1),
67 Text = new TextLabelStyle()
69 TextColor = new Color(0.05f, 0.63f, 0.9f, 1),
74 theme.AddStyleWithoutClone("Tizen.NUI.Components.Progress", new ProgressStyle()
76 Size = new Size(200, 5),
77 Track = new ImageViewStyle()
79 BackgroundColor = new Color(0, 0, 0, 0.1f),
81 Buffer = new ImageViewStyle()
83 BackgroundColor = new Color(0.05f, 0.63f, 0.9f, 0.3f),
85 Progress = new ImageViewStyle()
87 BackgroundColor = new Color(0.05f, 0.63f, 0.9f, 1),
91 theme.AddStyleWithoutClone("Tizen.NUI.Components.Slider", new SliderStyle()
93 Size = new Size(200, 50),
95 Track = new ImageViewStyle()
97 BackgroundColor = new Color(0, 0, 0, 0.1f),
99 Progress = new ImageViewStyle()
101 BackgroundColor = new Color(0.05f, 0.63f, 0.9f, 1),
103 Thumb = new ImageViewStyle()
105 Size = new Size(50, 50),
106 ResourceUrl = FrameworkInformation.ResourcePath + "nui_component_default_slider_thumb_n.png",
107 BackgroundImage = new Selector<string>()
110 Pressed = FrameworkInformation.ResourcePath + "nui_component_default_slider_thumb_bg_p.png",
115 theme.AddStyleWithoutClone("Tizen.NUI.Components.Tab", new TabStyle()
117 Size = new Size(480, 80),
118 BackgroundColor = Color.Yellow,
119 UnderLine = new ViewStyle()
121 Size = new Size(0, 6),
122 BackgroundColor = new Color(0.05f, 0.63f, 0.9f, 1),
124 Text = new TextLabelStyle()
127 TextColor = new Selector<Color>()
129 Normal = Color.Black,
130 Selected = new Color(0.05f, 0.63f, 0.9f, 1),
135 theme.AddStyleWithoutClone("Tizen.NUI.Components.Toast", new ToastStyle()
137 Size = new Size(480, 80),
138 BackgroundColor = new Color(0, 0, 0, 0.8f),
139 Text = new TextLabelStyle()
141 Padding = new Extents(12, 12, 8, 8)
145 theme.AddStyleWithoutClone("Tizen.NUI.Components.Pagination", new PaginationStyle()
147 IndicatorImageUrl = new Selector<string>()
149 Normal = FrameworkInformation.ResourcePath + "nui_component_default_pagination_normal_dot.png",
150 Selected = FrameworkInformation.ResourcePath + "nui_component_default_pagination_focus_dot.png",
154 theme.AddStyleWithoutClone("Tizen.NUI.Components.Scrollbar", new ScrollbarStyle()
158 TrackColor = new Color(1, 1, 1, 0.15f),
159 ThumbColor = new Color(0.6f, 0.6f, 0.6f, 1),
163 theme.AddStyleWithoutClone("Tizen.NUI.Components.Button", new ButtonStyle()
165 Size = new Size(210, 72),
167 BackgroundColor = new Selector<Color>()
169 Normal = new Color(0, 0.1647f, 0.3019f, 0.85f),
170 Pressed = new Color(0, 0.2475f, 0.5019f, 0.85f),
171 Disabled = new Color(0.2392f, 0.2392f, 0.2392f, 0.85f),
173 Opacity = new Selector<float?>()
178 Text = new TextLabelStyle()
180 FontFamily = "SamsungOne 700",
182 Padding = new Extents(20, 20, 0, 0),
183 HorizontalAlignment = HorizontalAlignment.Center,
184 VerticalAlignment = VerticalAlignment.Center,
185 TextColor = new Selector<Color>()
187 Normal = new Color(0.2196f, 0.6131f, 0.9882f, 1),
188 Disabled = new Color(1, 1, 1, 0.35f),
193 theme.AddStyleWithoutClone("Tizen.NUI.Components.CheckBox", new LottieButtonStyle()
195 LottieUrl = FrameworkInformation.ResourcePath + "nui_wearable_checkbox_icon.png",
196 PlayRange = new Selector<LottieFrameInfo>()
198 Selected = new LottieFrameInfo(19, 36),
199 Normal = new LottieFrameInfo(0, 18)
201 Opacity = new Selector<float?>()
209 theme.AddStyleWithoutClone("Tizen.NUI.Components.RadioButton", new LottieButtonStyle()
211 LottieUrl = FrameworkInformation.ResourcePath + "nui_wearable_radiobutton_icon.png",
212 PlayRange = new Selector<LottieFrameInfo>()
214 Selected = new LottieFrameInfo(0, 12),
215 Normal = new LottieFrameInfo(13, 25)
217 Opacity = new Selector<float?>()
225 theme.AddStyleWithoutClone("Tizen.NUI.Components.Switch", new LottieSwitchStyle()
227 LottieUrl = FrameworkInformation.ResourcePath + "nui_wearable_switch_icon.png",
228 PlayRange = new Selector<LottieFrameInfo>()
230 Selected = new LottieFrameInfo(0, 18),
231 Normal = new LottieFrameInfo(19, 36)
233 Opacity = new Selector<float?>()
241 theme.AddStyleWithoutClone("Tizen.NUI.Components.Loading", new LoadingStyle()
243 LoadingSize = new Size(360, 360),