[NUI] Add dark theme for Text components (#2908)
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Theme / ThemeDark.cs
1 /*
2  * Copyright(c) 2021 Samsung Electronics Co., Ltd.
3  *
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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  *
16  */
17 #if false
18
19 using System.Diagnostics.CodeAnalysis;
20 using Tizen.NUI.BaseComponents;
21
22 namespace Tizen.NUI
23 {
24     internal partial class DefaultThemeCreator
25     {
26         [SuppressMessage("Microsoft.Reliability", "CA2000: Dispose objects before losing scope", Justification = "The responsibility to dispose the object is transferred to the theme object.")]
27         public Theme Create()
28         {
29             Theme theme = new Theme()
30             {
31                 Id = DefaultId,
32                 Version = DefaultVersion,
33             };
34
35             // TextLabel style.
36             theme.AddStyleWithoutClone("Tizen.NUI.BaseComponents.TextLabel", new TextLabelStyle()
37             {
38                 FontFamily = "BreezeSans",
39                 PixelSize = 32,
40                 TextColor = new Color(1.00f, 1.00f, 1.00f, 1),
41                 FontStyle = new PropertyMap().Add("weight", new PropertyValue("light")),
42             });
43
44             // TextField style.
45             theme.AddStyleWithoutClone("Tizen.NUI.BaseComponents.TextField", new TextFieldStyle()
46             {
47                 FontFamily = "BreezeSans",
48                 PixelSize = 32,
49                 TextColor = new Color(1.00f, 1.00f, 1.00f, 1),
50                 FontStyle = new PropertyMap().Add("weight", new PropertyValue("regular")),
51                 PrimaryCursorColor = new Vector4(0.08f, 0.45f, 0.90f, 1),
52                 SecondaryCursorColor = new Vector4(0.08f, 0.45f, 0.90f, 1),
53                 CursorWidth = 3,
54                 SelectionHighlightColor = new Vector4(1.00f, 1.00f, 1.00f, 0.20f),
55                 GrabHandleColor = new Color(0.08f, 0.45f, 0.90f, 1),
56                 GrabHandleImage = FrameworkInformation.ResourcePath + "IoT_handler_center_downW.png",
57                 SelectionHandleImageLeft = new PropertyMap().Add("filename", new PropertyValue(FrameworkInformation.ResourcePath + "IoT_handler_downleftW.png")),
58                 SelectionHandleImageRight = new PropertyMap().Add("filename", new PropertyValue(FrameworkInformation.ResourcePath + "IoT_handler_downrightW.png")),
59             });
60
61             // TextEditor style.
62             theme.AddStyleWithoutClone("Tizen.NUI.BaseComponents.TextEditor", new TextEditorStyle()
63             {
64                 FontFamily = "BreezeSans",
65                 PixelSize = 32,
66                 TextColor = new Color(1.00f, 1.00f, 1.00f, 1),
67                 FontStyle = new PropertyMap().Add("weight", new PropertyValue("regular")),
68                 PrimaryCursorColor = new Vector4(0.08f, 0.45f, 0.90f, 1),
69                 SecondaryCursorColor = new Vector4(0.08f, 0.45f, 0.90f, 1),
70                 CursorWidth = 3,
71                 SelectionHighlightColor = new Vector4(1.00f, 1.00f, 1.00f, 0.20f),
72                 GrabHandleColor = new Color(0.08f, 0.45f, 0.90f, 1),
73                 GrabHandleImage = FrameworkInformation.ResourcePath + "IoT_handler_center_downW.png",
74                 SelectionHandleImageLeft = new PropertyMap().Add("filename", new PropertyValue(FrameworkInformation.ResourcePath + "IoT_handler_downleftW.png")),
75                 SelectionHandleImageRight = new PropertyMap().Add("filename", new PropertyValue(FrameworkInformation.ResourcePath + "IoT_handler_downrightW.png")),
76             });
77
78             return theme;
79         }
80     }
81 }
82 #endif