Mercurial > libervia-desktop-kivy
comparison libervia/desktop_kivy/core/constants.py @ 493:b3cedbee561d
refactoring: rename `cagou` to `libervia.desktop_kivy` + update imports and names following backend changes
author | Goffi <goffi@goffi.org> |
---|---|
date | Fri, 02 Jun 2023 18:26:16 +0200 |
parents | cagou/core/constants.py@f0d497b8f57c |
children | 956f5db30223 |
comparison
equal
deleted
inserted
replaced
492:5114bbb5daa3 | 493:b3cedbee561d |
---|---|
1 #!/usr/bin/env python3 | |
2 | |
3 # Libervia Desktop-Kivy | |
4 # Copyright (C) 2016-2021 Jérôme Poisson (goffi@goffi.org) | |
5 | |
6 # This program is free software: you can redistribute it and/or modify | |
7 # it under the terms of the GNU Affero General Public License as published by | |
8 # the Free Software Foundation, either version 3 of the License, or | |
9 # (at your option) any later version. | |
10 | |
11 # This program is distributed in the hope that it will be useful, | |
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 # GNU Affero General Public License for more details. | |
15 | |
16 # You should have received a copy of the GNU Affero General Public License | |
17 # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
18 | |
19 from libervia.frontends.quick_frontend import constants | |
20 from libervia import desktop_kivy | |
21 | |
22 # Kivy must not be imported here due to log hijacking see core/kivy_hack.py | |
23 | |
24 | |
25 class Const(constants.Const): | |
26 APP_NAME = "Libervia Desktop" | |
27 APP_COMPONENT = "desktop/mobile" | |
28 APP_NAME_ALT = "LiberviaDesktopKivy" | |
29 APP_NAME_FILE = "libervia_desktop" | |
30 APP_VERSION = desktop_kivy.__version__ | |
31 LOG_OPT_SECTION = APP_NAME.lower() | |
32 CONFIG_SECTION = "desktop" | |
33 WID_SELECTOR = 'selector' | |
34 ICON_SIZES = ('small', 'medium') # small = 32, medium = 44 | |
35 DEFAULT_WIDGET_ICON = '{media}/misc/black.png' | |
36 | |
37 BTN_HEIGHT = '35dp' | |
38 | |
39 PLUG_TYPE_WID = 'wid' | |
40 PLUG_TYPE_TRANSFER = 'transfer' | |
41 | |
42 TRANSFER_UPLOAD = "upload" | |
43 TRANSFER_SEND = "send" | |
44 | |
45 COLOR_PRIM = (0.98, 0.98, 0.98, 1) | |
46 COLOR_PRIM_LIGHT = (1, 1, 1, 1) | |
47 COLOR_PRIM_DARK = (0.78, 0.78, 0.78, 1) | |
48 COLOR_SEC = (0.27, 0.54, 1.0, 1) | |
49 COLOR_SEC_LIGHT = (0.51, 0.73, 1.0, 1) | |
50 COLOR_SEC_DARK = (0.0, 0.37, 0.8, 1) | |
51 | |
52 COLOR_INFO = COLOR_PRIM_LIGHT | |
53 COLOR_WARNING = (1.0, 1.0, 0.0, 1) | |
54 COLOR_ERROR = (1.0, 0.0, 0.0, 1) | |
55 | |
56 COLOR_BTN_LIGHT = (0.4, 0.4, 0.4, 1) | |
57 | |
58 # values are in dp | |
59 IMG_MAX_WIDTH = 400 | |
60 IMG_MAX_HEIGHT = 400 | |
61 | |
62 # files | |
63 FILE_DEST_DOWNLOAD = "DOWNLOAD" | |
64 FILE_DEST_CACHE = "CACHE" |