mirror of
https://github.com/liberatedsystems/Sideband_CE.git
synced 2024-09-03 04:13:27 +02:00
Theme tweaks
This commit is contained in:
parent
7cd250fda7
commit
c6df8b851b
@ -17,7 +17,8 @@ color_delivered = "Indigo"
|
|||||||
color_propagated = "Blue"
|
color_propagated = "Blue"
|
||||||
color_failed = "Red"
|
color_failed = "Red"
|
||||||
color_unknown = "Gray"
|
color_unknown = "Gray"
|
||||||
intensity_msgs = "600"
|
intensity_msgs_dark = "600"
|
||||||
|
intensity_msgs_light = "500"
|
||||||
|
|
||||||
class ContentNavigationDrawer(Screen):
|
class ContentNavigationDrawer(Screen):
|
||||||
pass
|
pass
|
||||||
|
@ -859,11 +859,13 @@ MDNavigationLayout:
|
|||||||
|
|
||||||
MDRelativeLayout:
|
MDRelativeLayout:
|
||||||
size_hint: 1.0, None
|
size_hint: 1.0, None
|
||||||
# size: root.size
|
theme_text_color: "ContrastParentBackground"
|
||||||
|
|
||||||
MDIconButton:
|
MDIconButton:
|
||||||
id: msg_submenu
|
id: msg_submenu
|
||||||
icon: "dots-vertical"
|
icon: "dots-vertical"
|
||||||
|
theme_text_color: 'Custom'
|
||||||
|
text_color: rgba(255,255,255,230)
|
||||||
pos:
|
pos:
|
||||||
root.width - (self.width + root.padding[0] + dp(4)), root.height - (self.height + root.padding[0] + dp(4))
|
root.width - (self.width + root.padding[0] + dp(4)), root.height - (self.height + root.padding[0] + dp(4))
|
||||||
|
|
||||||
@ -872,6 +874,8 @@ MDNavigationLayout:
|
|||||||
markup: True
|
markup: True
|
||||||
text: root.heading
|
text: root.heading
|
||||||
adaptive_size: True
|
adaptive_size: True
|
||||||
|
theme_text_color: 'Custom'
|
||||||
|
text_color: rgba(255,255,255,230)
|
||||||
pos: 0, root.height - (self.height + root.padding[0] + dp(8))
|
pos: 0, root.height - (self.height + root.padding[0] + dp(8))
|
||||||
|
|
||||||
MDLabel:
|
MDLabel:
|
||||||
@ -880,6 +884,8 @@ MDNavigationLayout:
|
|||||||
# adaptive_size: True
|
# adaptive_size: True
|
||||||
size_hint_y: None
|
size_hint_y: None
|
||||||
text_size: self.width, None
|
text_size: self.width, None
|
||||||
|
theme_text_color: 'Custom'
|
||||||
|
text_color: rgba(255,255,255,230)
|
||||||
height: self.texture_size[1]
|
height: self.texture_size[1]
|
||||||
|
|
||||||
<MsgSync>
|
<MsgSync>
|
||||||
|
@ -16,10 +16,10 @@ from kivymd.uix.dialog import MDDialog
|
|||||||
|
|
||||||
if RNS.vendor.platformutils.get_platform() == "android":
|
if RNS.vendor.platformutils.get_platform() == "android":
|
||||||
from ui.helpers import ts_format, mdc
|
from ui.helpers import ts_format, mdc
|
||||||
from ui.helpers import color_received, color_delivered, color_propagated, color_failed, color_unknown, intensity_msgs
|
from ui.helpers import color_received, color_delivered, color_propagated, color_failed, color_unknown, intensity_msgs_dark, intensity_msgs_light
|
||||||
else:
|
else:
|
||||||
from .helpers import ts_format, mdc
|
from .helpers import ts_format, mdc
|
||||||
from .helpers import color_received, color_delivered, color_propagated, color_failed, color_unknown, intensity_msgs
|
from .helpers import color_received, color_delivered, color_propagated, color_failed, color_unknown, intensity_msgs_dark, intensity_msgs_light
|
||||||
|
|
||||||
class ListLXMessageCard(MDCard, RoundedRectangularElevationBehavior):
|
class ListLXMessageCard(MDCard, RoundedRectangularElevationBehavior):
|
||||||
text = StringProperty()
|
text = StringProperty()
|
||||||
@ -58,6 +58,11 @@ class Messages():
|
|||||||
if len(self.messages) > 0:
|
if len(self.messages) > 0:
|
||||||
self.update_widget()
|
self.update_widget()
|
||||||
|
|
||||||
|
if self.app.sideband.config["dark_ui"]:
|
||||||
|
intensity_msgs = intensity_msgs_dark
|
||||||
|
else:
|
||||||
|
intensity_msgs = intensity_msgs_light
|
||||||
|
|
||||||
for w in self.widgets:
|
for w in self.widgets:
|
||||||
m = w.m
|
m = w.m
|
||||||
if m["state"] == LXMF.LXMessage.SENDING or m["state"] == LXMF.LXMessage.OUTBOUND:
|
if m["state"] == LXMF.LXMessage.SENDING or m["state"] == LXMF.LXMessage.OUTBOUND:
|
||||||
@ -91,6 +96,11 @@ class Messages():
|
|||||||
|
|
||||||
|
|
||||||
def update_widget(self):
|
def update_widget(self):
|
||||||
|
if self.app.sideband.config["dark_ui"]:
|
||||||
|
intensity_msgs = intensity_msgs_dark
|
||||||
|
else:
|
||||||
|
intensity_msgs = intensity_msgs_light
|
||||||
|
|
||||||
for m in self.messages:
|
for m in self.messages:
|
||||||
if not m["hash"] in self.added_item_hashes:
|
if not m["hash"] in self.added_item_hashes:
|
||||||
txstr = time.strftime(ts_format, time.localtime(m["sent"]))
|
txstr = time.strftime(ts_format, time.localtime(m["sent"]))
|
||||||
|
Loading…
Reference in New Issue
Block a user