~aleteoryx/muditaos

ref: 46f9cc7e100b471afef4efc4449880eb480ac7fa muditaos/module-apps/application-calendar/widgets/CalendarStyle.hpp -rw-r--r-- 6.4 KiB
46f9cc7e — Lucjan Bryndza [EGD-5737] Merge master into experimental 5 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
// Copyright (c) 2017-2020, Mudita Sp. z.o.o. All rights reserved.
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md

#pragma once
#include <Style.hpp>
#include <string>

namespace style
{
    namespace window
    {
        namespace calendar
        {
            namespace imageCircleTop
            {
                inline constexpr auto x    = 116U;
                inline constexpr auto y    = 59U;
                inline constexpr auto name = "circle_top";
            } // namespace imageCircleTop
            namespace imageCircleBottom
            {
                inline constexpr auto x    = 106U;
                inline constexpr auto y    = 240U;
                inline constexpr auto name = "circle_bottom";
            } // namespace imageCircleBottom

            namespace name
            {
                inline constexpr auto day_events_window     = "DayEventsWindow";
                inline constexpr auto no_events_window      = "NoEventsWindow";
                inline constexpr auto events_options        = "Options";
                inline constexpr auto dialog_yes_no         = "DialogYesNo";
                inline constexpr auto all_events_window     = "AllEventsWindow";
                inline constexpr auto details_window        = "DetailsWindow";
                inline constexpr auto new_edit_event        = "NewEditEvent";
                inline constexpr auto custom_repeat_window  = "CustomRepeat";
                inline constexpr auto event_reminder_window = "EventReminderWindow";
            } // namespace name

            inline constexpr auto new_event         = "New";
            inline constexpr auto edit_event        = "Edit";
            inline constexpr auto day_cell_width    = 60;
            inline constexpr auto day_cell_height   = 55;
            inline constexpr auto month_year_height = 60;
            inline constexpr auto week_days_number  = 7;
            inline constexpr auto max_weeks_number  = 6;

            inline constexpr auto cross_x    = 48;
            inline constexpr auto cross_y    = 55;
            inline constexpr auto arrow_x    = 30;
            inline constexpr auto arrow_y    = 62;
            inline constexpr auto listView_x = style::window::default_left_margin;
            inline constexpr auto listView_y = style::header::height;
            inline constexpr auto listView_w = style::listview::body_width_with_scroll;
            inline constexpr auto listView_h = style::window_height - listView_y - style::footer::height;

            namespace test
            {
                inline constexpr auto prev_month_id = 1;
                inline constexpr auto month_id      = 2;
                inline constexpr auto next_month_id = 3;
                inline constexpr auto date_text_1   = "January 2019";
                inline constexpr auto date_text_2   = "February 2019";
                inline constexpr auto date_text_3   = "March 2019";
            } // namespace test

            namespace time
            {
                inline constexpr auto max_time_length   = 2;
                inline constexpr auto max_hour_24H_mode = 23;
                inline constexpr auto max_hour_12H_mode = 12;
                inline constexpr auto max_minutes       = 59;
                inline constexpr auto max_years         = 2038;
                inline constexpr auto min_years         = 1970;
            } // namespace time

            namespace item
            {
                namespace dayEvents
                {
                    inline constexpr auto title_w    = 255;
                    inline constexpr auto box_height = style::window::label::small_h;
                    inline constexpr auto height     = 100;
                } // namespace dayEvents

                namespace allEvents
                {
                    inline constexpr auto description_w    = 310;
                    inline constexpr auto start_time_min_w = 60;
                } // namespace allEvents

                namespace repeatAndReminder
                {
                    inline constexpr auto height             = 150;
                    inline constexpr auto title_label_h      = 45;
                    inline constexpr auto title_label_margin = 15;
                    inline constexpr auto description_w      = style::window::default_body_width / 2 - title_label_h;
                    inline constexpr auto description_h      = 30;
                } // namespace repeatAndReminder

                namespace eventDetail
                {
                    inline constexpr auto height_min        = 90;
                    inline constexpr auto height_max        = 155;
                    inline constexpr auto margin_top        = 2 * style::margins::big;
                    inline constexpr auto event_time_margin = 25;
                    inline constexpr auto title_h           = 20;
                    inline constexpr auto label_h           = 35;
                } // namespace eventDetail

                namespace eventTime
                {
                    inline constexpr auto height           = 106;
                    inline constexpr auto margin           = 21;
                    inline constexpr auto separator        = 30;
                    inline constexpr auto time_input_12h_w = 120;
                    inline constexpr auto time_input_24h_w = 195;
                } // namespace eventTime

                namespace checkBox
                {
                    inline constexpr auto height              = 44;
                    inline constexpr auto margin_top          = 18;
                    inline constexpr auto input_box_label_w   = style::window::label::big_h;
                    inline constexpr auto description_label_w = 280;
                } // namespace checkBox

                namespace severalOptions
                {
                    inline constexpr auto height    = 63;
                    inline constexpr auto label_h   = 30;
                    inline constexpr auto arrow_w_h = 20;
                } // namespace severalOptions

                namespace textWithLabel
                {
                    inline constexpr auto height        = 80;
                    inline constexpr auto description_h = 30;
                    inline constexpr auto text_input_h  = 40;
                } // namespace textWithLabel
            }     // namespace item
        };        // namespace calendar
    }             // namespace window
} // namespace style