Rework chat line templates and logic

- Extract chat line templates and logic so they can be reused across widgets
- Make text notification styling entirely template driven (by removing chat color configuration and making color optional for `TextNotification`)
- Add a new TextNotificationsDisplay widget (based on and replacing ChatDisplayWidget)
- Add timestamp support to text notifications
This commit is contained in:
Ivaylo Draganov
2021-06-15 17:32:21 +03:00
committed by Matthias Mailänder
parent 8416dc3f2d
commit 9e92340ea7
20 changed files with 330 additions and 363 deletions

View File

@@ -0,0 +1,39 @@
Container@CHAT_LINE_TEMPLATE:
Width: PARENT_RIGHT
Height: 16
Children:
Label@TIME:
X: 5
Width: 37
Height: 16
Shadow: True
Label@PREFIX:
X: 5
Height: 16
Shadow: True
Label@TEXT:
X: 5
Height: 16
WordWrap: True
Shadow: True
Container@SYSTEM_LINE_TEMPLATE:
Width: PARENT_RIGHT
Height: 16
Children:
Label@TIME:
X: 5
Width: 37
Height: 16
Shadow: True
Label@PREFIX:
X: 5
Height: 16
Shadow: True
TextColor: FFFF00
Label@TEXT:
X: 5
Height: 16
WordWrap: True
Shadow: True
TextColor: FFFF00