Files
wayvr/wlx-overlay-s/src/assets/gui/watch.xml
2025-09-21 10:49:44 +09:00

104 lines
5.1 KiB
XML

<layout>
<theme>
<var key="border" value="2" />
<var key="kbd_color" value="#a6da95" />
<var key="set_color" value="#cad3f5" />
<var key="clock0_color" value="#cad3f5" />
<var key="clock0_size" value="46" />
<var key="clock0_date_size" value="14" />
<var key="clock0_dow_size" value="14" />
<var key="clock_alt1_color" value="#8bd5ca" />
<var key="clock_alt2_color" value="#b7bdf8" />
<var key="clock_alt_size" value="24" />
<var key="clock_alt_tz_size" value="14" />
</theme>
<macro name="button_style"
margin="2" overflow="hidden" box_sizing="border_box" align_items="center" justify_content="center"
border_color="#0044CC" border="2" round="8" color="#000A1C" color2="#000002" gradient="vertical" />
<template name="Device">
<sprite color="~device_color" width="${size}" height="${size}" src="${src}" />
</template>
<template name="Set">
<Button macro="button_style" _press="::OverlayToggle ${handle}">
<sprite width="40" height="40" color="~set_color" src="watch/set2.svg" />
<div position="absolute" margin_top="11">
<label text="${display}" size="24" color="#000A1C" weight="bold" />
</div>
</Button>
</template>
<elements>
<div width="400" height="200">
<rectangle width="100%" height="100%" padding="4" box_sizing="content_box" flex_wrap="wrap" flex_direction="column" gap="4" color="~bg_color">
<div width="100%" flex_direction="row">
<Device src="watch/hmd.svg" size="40" />
<Device src="watch/controller_l.svg" size="36" />
<Device src="watch/controller_r.svg" size="36" />
<Device src="watch/track3.svg" size="40" />
<Device src="watch/track3.svg" size="40" />
<Device src="watch/track3.svg" size="40" />
</div>
<div flex_direction="row">
<div flex_direction="column" padding="4">
<label text="23:59" _source="clock" _display="time" color="~clock0_color" size="~clock0_size" weight="bold" />
<label text="22/2/2022" _source="clock" _display="date" color="~clock0_color" size="~clock0_date_size" weight="bold" />
<div width="100%" padding="2" />
<label text="Tuesday" _source="clock" _display="dow" color="~clock0_color" size="~clock0_dow_size" weight="bold" />
</div>
<div width="10" height="100%" />
<div flex_direction="column" padding="4">
<!-- Timezone names here are only placeholders. Set your timezones via ~/.config/wlxoverlay/conf.d -->
<div width="100%" padding="2" />
<label text="Paris" _source="clock" _display="name" _timezone="0" color="~clock_alt1_color" size="~clock_alt_tz_size" weight="bold" />
<label text="23:59" _source="clock" _display="time" _timezone="0" color="~clock_alt1_color" size="~clock_alt_size" weight="bold" />
<div width="100%" padding="2" />
<label text="New York" _source="clock" _display="name" _timezone="1" color="~clock_alt2_color" size="~clock_alt_tz_size" weight="bold" />
<label text="23:59" _source="clock" _display="time" _timezone="1" color="~clock_alt2_color" size="~clock_alt_size" weight="bold" />
</div>
</div>
<div width="100%" flex_direction="row">
<Button macro="button_style" _press="::DashToggle">
<sprite color="~set_color" width="40" height="40" src="watch/home.svg" />
</Button>
<div>
<Button macro="button_style" _press="::OverlayToggle HDMI-A-1">
<sprite width="40" height="40" color="~set_color" src="watch/set2.svg" />
<div position="absolute" margin_top="11" >
<label text="1" size="24" color="#000A1C" weight="bold" />
</div>
</Button>
<Button macro="button_style" _press="::OverlayToggle HDMI-A-2">
<sprite width="40" height="40" color="~set_color" src="watch/set2.svg" />
<div position="absolute" margin_top="11" >
<label text="2" size="24" color="#000A1C" weight="bold" />
</div>
</Button>
<Button macro="button_style" _press="::OverlayToggle DP-2">
<sprite width="40" height="40" color="~set_color" src="watch/set2.svg" />
<div position="absolute" margin_top="11" >
<label text="3" size="24" color="#000A1C" weight="bold" />
</div>
</Button>
<Button macro="button_style" _press="::OverlayToggle DP-3">
<sprite width="40" height="40" color="~set_color" src="watch/set2.svg" />
<div position="absolute" margin_top="11" >
<label text="4" size="24" color="#000A1C" weight="bold" />
</div>
</Button>
</div>
<!--div id="ts" -->
<!-- Will populate <Set> tags at runtime -->
<!--/div -->
<Button macro="button_style" _press="::EditToggle">
<sprite color="~set_color" width="40" height="40" src="watch/edit.svg" />
</Button>
</div>
</rectangle>
</div>
</elements>
</layout>