services.walker: fix paths for walker v2

This commit is contained in:
N4CH723HR3R 2026-02-11 10:03:32 +01:00 committed by Austin Horstman
parent af59809e94
commit d3b4e4b1bd
3 changed files with 86 additions and 36 deletions

View file

@ -1,3 +1,7 @@
{ pkgs, ... }:
let
layout_xml = builtins.readFile ./item_dmenu.xml;
in
{
services.walker = {
enable = true;
@ -17,41 +21,33 @@
theme = {
name = "mytheme";
layout = {
ui = {
anchors = {
bottom = true;
left = true;
right = true;
top = true;
};
window = {
h_align = "fill";
v_align = "fill";
};
};
};
style = ''
* {
color: #dcd7ba;
}
'';
# create 2 identical files, one points into the store the other is a direct text
layout.item_dmenu_two = pkgs.writeText "item_dmenu.xml" layout_xml;
layout.item_dmenu_one = layout_xml;
};
};
nmt.script = ''
assertFileExists home-files/.config/walker/config.toml
assertFileExists home-files/.config/walker/themes/mytheme.toml
assertFileExists home-files/.config/walker/themes/mytheme.css
assertFileExists home-files/.config/walker/themes/mytheme/style.css
assertFileExists home-files/.config/walker/themes/mytheme/item_dmenu_one.xml
assertFileExists home-files/.config/walker/themes/mytheme/item_dmenu_two.xml
assertFileContent home-files/.config/walker/themes/mytheme/item_dmenu_one.xml \
${./item_dmenu.xml}
assertFileContent home-files/.config/walker/themes/mytheme/item_dmenu_two.xml \
${./item_dmenu.xml}
assertFileContent home-files/.config/walker/config.toml \
${./config.toml}
assertFileContent home-files/.config/walker/themes/mytheme.toml \
${./mytheme.toml}
assertFileContent home-files/.config/walker/themes/mytheme.css \
assertFileContent home-files/.config/walker/themes/mytheme/style.css \
${./mytheme.css}
'';
}

View file

@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<requires lib="gtk" version="4.0"></requires>
<object class="GtkBox" id="ItemBox">
<style>
<class name="item-box"></class>
</style>
<property name="orientation">horizontal</property>
<property name="spacing">10</property>
<child>
<object class="GtkBox" id="ItemTextBox">
<style>
<class name="item-text-box"></class>
</style>
<property name="orientation">vertical</property>
<property name="hexpand">true</property>
<property name="vexpand">true</property>
<property name="vexpand-set">true</property>
<property name="spacing">0</property>
<child>
<object class="GtkLabel" id="ItemText">
<style>
<class name="item-text"></class>
</style>
<property name="vexpand">true</property>
<property name="xalign">0</property>
<property name="lines">1</property>
<property name="ellipsize">3</property>
<property name="single-line-mode">true</property>
</object>
</child>
</object>
</child>
<child>
<object class="GtkLabel" id="QuickActivation">
<style>
<class name="item-quick-activation"></class>
</style>
<property name="wrap">false</property>
<property name="valign">center</property>
<property name="xalign">0</property>
<property name="yalign">0.5</property>
</object>
</child>
</object>
</interface>