Begin Slint UI

- Get started with Slint for UI
- Experiment with basic window structure
This commit is contained in:
Candifloss 2025-10-15 22:56:26 +05:30
parent b4162a7fc0
commit d83c5a0aca
2 changed files with 45 additions and 0 deletions

View File

@ -10,3 +10,7 @@ reqwest = {version = "0.12.23", features = ["blocking", "json"] }
toml = "0.9.7"
dirs = "6.0.0"
serde_json = "1.0.145"
slint = "1.13"
[build-dependencies]
slint-build = "1.13.1"

View File

@ -0,0 +1,41 @@
export component MainWindow inherits Window {
always-on-top: true;
height: 100px;
width: 300px;
no-frame: true;
weather_popup := Rectangle {
height: 100%;
width: 100%;
border-radius: 10px;
border-color: #ffffff00;
background: #7e7e7e36;
main_temp := Text {text: "24.4" + "°C";
vertical-alignment: TextVerticalAlignment.center;
x: 10px;
y: 10px;
color: #ffffff;
font-family: "IosevkaTermSlab Nerd Font Mono";
font-size: 40px;
}
weather_summary := Text {
text: "Clear";
x: 10px;
y: 55px;
font-size: 30px;
font-family: "IosevkaTermSlab Nerd Font Mono";
color: #fff;
}
city_name := Text {
text: "England";
x: 150px;
y: 55px;
font-size: 25px;
font-family: "IosevkaTermSlab Nerd Font Mono";
color: #fff;
}
}
}