fix window title visibility and elision, document weather.interval
This commit is contained in:
parent
e1565bdd59
commit
25bc3954cb
3 changed files with 9 additions and 3 deletions
|
|
@ -87,7 +87,8 @@ programs.nova-shell.modules = {
|
||||||
|
|
||||||
# modules with extra config
|
# modules with extra config
|
||||||
backlight.step = 2; # brightness adjustment %
|
backlight.step = 2; # brightness adjustment %
|
||||||
weather.args = [ "--nerd" "--location" "Berlin" ]; # wttrbar arguments
|
weather.args = [ "--nerd" "--location" "Berlin" ]; # wttrbar arguments
|
||||||
|
weather.interval = 3600000; # refresh interval in ms (default 1h)
|
||||||
temperature.warm = 55; # °C threshold for warm color
|
temperature.warm = 55; # °C threshold for warm color
|
||||||
temperature.hot = 75; # °C threshold for hot color
|
temperature.hot = 75; # °C threshold for hot color
|
||||||
battery.warning = 30; # % for warning notification
|
battery.warning = 30; # % for warning notification
|
||||||
|
|
|
||||||
|
|
@ -142,9 +142,12 @@ PanelWindow {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
M.BarGroup {
|
M.BarGroup {
|
||||||
|
id: _windowTitleGroup
|
||||||
Layout.minimumWidth: 0
|
Layout.minimumWidth: 0
|
||||||
clip: true
|
clip: true
|
||||||
M.WindowTitle {}
|
M.WindowTitle {
|
||||||
|
width: Math.max(0, centerSection.x - _windowTitleGroup.x - 2 * M.Theme.groupPadding - M.Theme.groupSpacing)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ import "." as M
|
||||||
M.BarSection {
|
M.BarSection {
|
||||||
id: root
|
id: root
|
||||||
spacing: M.Theme.moduleSpacing
|
spacing: M.Theme.moduleSpacing
|
||||||
visible: M.Modules.windowTitle.enable && M.NiriIpc.available && M.NiriIpc.focusedTitle !== ""
|
visible: M.Modules.windowTitle.enable && M.NiriIpc.focusedTitle !== ""
|
||||||
|
|
||||||
tooltip: M.NiriIpc.focusedAppId ? M.NiriIpc.focusedAppId + "\n" + M.NiriIpc.focusedTitle : M.NiriIpc.focusedTitle
|
tooltip: M.NiriIpc.focusedAppId ? M.NiriIpc.focusedAppId + "\n" + M.NiriIpc.focusedTitle : M.NiriIpc.focusedTitle
|
||||||
|
|
||||||
|
|
@ -19,6 +19,7 @@ M.BarSection {
|
||||||
}
|
}
|
||||||
|
|
||||||
IconImage {
|
IconImage {
|
||||||
|
id: _icon
|
||||||
visible: root._iconSource !== ""
|
visible: root._iconSource !== ""
|
||||||
source: root._iconSource
|
source: root._iconSource
|
||||||
implicitSize: M.Theme.fontSize + 2
|
implicitSize: M.Theme.fontSize + 2
|
||||||
|
|
@ -35,5 +36,6 @@ M.BarSection {
|
||||||
color: root.accentColor
|
color: root.accentColor
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
width: root.width - (_icon.visible ? _icon.width + root.spacing : 0)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue