slint/examples/bash
2024-09-16 09:15:39 +02:00
..
laptop.svg Add an icon to the general tab 2021-10-08 09:33:09 +02:00
laptop.svg.license janitor: Go over our spell checking setup 2023-10-16 09:01:51 +02:00
README.md Update example readmes 2024-08-13 11:35:39 +02:00
simple_input.sh Examples: port simple_input.sh to the new syntax 2024-06-11 09:06:07 +02:00
sysinfo.slint Use AccessibleRole::ListItem inside examples 2024-09-16 09:15:39 +02:00
sysinfo_linux.sh Domain: slint-ui.com -> slint.dev 2023-06-16 10:55:08 +02:00
sysinfo_macos.sh Domain: slint-ui.com -> slint.dev 2023-06-16 10:55:08 +02:00

Slint Bash example

This shows how to use slint-viewer to display dialog from a bash script.

This assume that the slint-viewer tool is in path. This can be achieved with cargo install. (use the --path tools/viewer option to install it from the current repository.)

cargo install slint-viewer

The examples also assume that jq is in the path

  • simple_input.sh: shows how to query a few parameter with bash
  • sysinfo_linux.sh/sysinfo_macos.sh: show how to display the result of bash commands.

Attributions

The laptop.svg icon is emoji_u1f4bb.svg from the Noto Emoji font from https://github.com/googlefonts/noto-emoji and licensed under the terms of the SIL Open Font License, version 1.1; copyright Google Inc.

Screenshot of the bash example