Mercurial > libervia-backend
comparison frontends/src/primitivus/constants.py @ 736:6246eb6d64a0
frontends: define the constants with classes and inheritance instance of using __builtin__
author | souliane <souliane@mailoo.org> |
---|---|
date | Sat, 23 Nov 2013 10:21:40 +0100 |
parents | 84a6e83157c2 |
children | f100fd8d279f |
comparison
equal
deleted
inserted
replaced
735:682933ca304c | 736:6246eb6d64a0 |
---|---|
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
15 # GNU Affero General Public License for more details. | 15 # GNU Affero General Public License for more details. |
16 | 16 |
17 # You should have received a copy of the GNU Affero General Public License | 17 # You should have received a copy of the GNU Affero General Public License |
18 # along with this program. If not, see <http://www.gnu.org/licenses/>. | 18 # along with this program. If not, see <http://www.gnu.org/licenses/>. |
19 import __builtin__ | |
20 | 19 |
21 __builtin__.__dict__['const_APP_NAME'] = "Primitivus" | 20 from sat_frontends.quick_frontend import constants |
22 __builtin__.__dict__['const_PALETTE'] = [ | 21 |
23 ('title', 'black', 'light gray', 'standout,underline'), | 22 |
24 ('title_focus', 'white,bold', 'light gray', 'standout,underline'), | 23 class Const(constants.Const): |
25 ('selected', 'default', 'dark red'), | 24 |
26 ('selected_focus', 'default,bold', 'dark red'), | 25 APP_NAME = "Primitivus" |
27 ('default', 'default', 'default'), | 26 PALETTE = [ |
28 ('default_focus', 'default,bold', 'default'), | 27 ('title', 'black', 'light gray', 'standout,underline'), |
29 ('alert', 'default,underline', 'default'), | 28 ('title_focus', 'white,bold', 'light gray', 'standout,underline'), |
30 ('alert_focus', 'default,bold,underline', 'default'), | 29 ('selected', 'default', 'dark red'), |
31 ('date', 'light gray', 'default'), | 30 ('selected_focus', 'default,bold', 'dark red'), |
32 ('my_nick', 'dark red,bold', 'default'), | 31 ('default', 'default', 'default'), |
33 ('other_nick', 'dark cyan,bold', 'default'), | 32 ('default_focus', 'default,bold', 'default'), |
34 ('menubar', 'light gray,bold', 'dark red'), | 33 ('alert', 'default,underline', 'default'), |
35 ('menubar_focus', 'light gray,bold', 'dark green'), | 34 ('alert_focus', 'default,bold,underline', 'default'), |
36 ('selected_menu', 'light gray,bold', 'dark green'), | 35 ('date', 'light gray', 'default'), |
37 ('menuitem', 'light gray,bold', 'dark red'), | 36 ('my_nick', 'dark red,bold', 'default'), |
38 ('menuitem_focus', 'light gray,bold', 'dark green'), | 37 ('other_nick', 'dark cyan,bold', 'default'), |
39 ('notifs', 'black,bold', 'yellow'), | 38 ('menubar', 'light gray,bold', 'dark red'), |
40 ('notifs_focus', 'dark red', 'yellow'), | 39 ('menubar_focus', 'light gray,bold', 'dark green'), |
41 ('card_neutral', 'dark gray', 'white', 'standout,underline'), | 40 ('selected_menu', 'light gray,bold', 'dark green'), |
42 ('card_neutral_selected', 'dark gray', 'dark green', 'standout,underline'), | 41 ('menuitem', 'light gray,bold', 'dark red'), |
43 ('card_special', 'brown', 'white', 'standout,underline'), | 42 ('menuitem_focus', 'light gray,bold', 'dark green'), |
44 ('card_special_selected', 'brown', 'dark green', 'standout,underline'), | 43 ('notifs', 'black,bold', 'yellow'), |
45 ('card_red', 'dark red', 'white', 'standout,underline'), | 44 ('notifs_focus', 'dark red', 'yellow'), |
46 ('card_red_selected', 'dark red', 'dark green', 'standout,underline'), | 45 ('card_neutral', 'dark gray', 'white', 'standout,underline'), |
47 ('card_black', 'black', 'white', 'standout,underline'), | 46 ('card_neutral_selected', 'dark gray', 'dark green', 'standout,underline'), |
48 ('card_black_selected', 'black', 'dark green', 'standout,underline'), | 47 ('card_special', 'brown', 'white', 'standout,underline'), |
49 ('directory', 'dark cyan, bold', 'default'), | 48 ('card_special_selected', 'brown', 'dark green', 'standout,underline'), |
50 ('directory_focus', 'dark cyan, bold', 'dark green'), | 49 ('card_red', 'dark red', 'white', 'standout,underline'), |
51 ('separator', 'brown', 'default'), | 50 ('card_red_selected', 'dark red', 'dark green', 'standout,underline'), |
52 ('warning', 'light red', 'default'), | 51 ('card_black', 'black', 'white', 'standout,underline'), |
53 ('progress_normal', 'default', 'black'), | 52 ('card_black_selected', 'black', 'dark green', 'standout,underline'), |
54 ('progress_complete', 'default', 'light red'), | 53 ('directory', 'dark cyan, bold', 'default'), |
55 ('show_disconnected', 'dark gray', 'default'), | 54 ('directory_focus', 'dark cyan, bold', 'dark green'), |
56 ('show_normal', 'default', 'default'), | 55 ('separator', 'brown', 'default'), |
57 ('show_normal_focus', 'default, bold', 'default'), | 56 ('warning', 'light red', 'default'), |
58 ('show_chat', 'dark green', 'default'), | 57 ('progress_normal', 'default', 'black'), |
59 ('show_chat_focus', 'dark green, bold', 'default'), | 58 ('progress_complete', 'default', 'light red'), |
60 ('show_away', 'brown', 'default'), | 59 ('show_disconnected', 'dark gray', 'default'), |
61 ('show_away_focus', 'brown, bold', 'default'), | 60 ('show_normal', 'default', 'default'), |
62 ('show_dnd', 'dark red', 'default'), | 61 ('show_normal_focus', 'default, bold', 'default'), |
63 ('show_dnd_focus', 'dark red, bold', 'default'), | 62 ('show_chat', 'dark green', 'default'), |
64 ('show_xa', 'dark red', 'default'), | 63 ('show_chat_focus', 'dark green, bold', 'default'), |
65 ('show_xa_focus', 'dark red, bold', 'default'), | 64 ('show_away', 'brown', 'default'), |
66 ('status', 'yellow', 'default'), | 65 ('show_away_focus', 'brown, bold', 'default'), |
67 ('status_focus', 'yellow, bold', 'default'), | 66 ('show_dnd', 'dark red', 'default'), |
68 ] | 67 ('show_dnd_focus', 'dark red, bold', 'default'), |
69 __builtin__.__dict__['const_SHOW_ICON'] = {"unavailable": (u'⨯', "show_disconnected"), | 68 ('show_xa', 'dark red', 'default'), |
70 "": (u'✔', "show_normal"), | 69 ('show_xa_focus', 'dark red, bold', 'default'), |
71 "chat": (u'✆', "show_chat"), | 70 ('status', 'yellow', 'default'), |
72 "away": (u'✈', "show_away"), | 71 ('status_focus', 'yellow, bold', 'default'), |
73 "dnd": (u'✖', "show_dnd"), | 72 ] |
74 "xa": (u'☄', "show_xa")} | 73 PRESENCE = {"unavailable": (u'⨯', "show_disconnected"), |
74 "": (u'✔', "show_normal"), | |
75 "chat": (u'✆', "show_chat"), | |
76 "away": (u'✈', "show_away"), | |
77 "dnd": (u'✖', "show_dnd"), | |
78 "xa": (u'☄', "show_xa") | |
79 } | |
80 |