feat: use icon.svg as app icon for Android and Linux (#459)

Closes #451

## What changed

Replaces the default Flutter blue logo with the project's rainbow-rings `icon.svg` on all supported platforms.

**Android** — all five mipmap densities regenerated (`mdpi` 48px through `xxxhdpi` 192px).

**Linux** — `linux/sharedinbox.png` (512×512) added, installed next to the binary via `CMakeLists.txt`, and set as the GTK window icon via `gtk_window_set_icon_from_file` in `my_application.cc`.

**Tooling** — `icon.png` (1024×1024 source raster) committed; `flutter_launcher_icons` added as dev dep with a `flutter_icons` config block; `task generate-icons` added to `Taskfile.yml` for future regeneration; `librsvg` added to `flake.nix` so `rsvg-convert` is available inside `nix develop`.

## How verified

Icons were generated with Inkscape from `icon.svg` and visually confirmed (rainbow-rings design appears correctly at all sizes). The `playstore/icon.png` was already correct and unchanged.

Co-authored-by: Thomas SharedInbox <sharedinbox@thomas-guettler.de>
Reviewed-on: https://codeberg.org/guettli/sharedinbox/pulls/459
This commit was merged in pull request #459.
This commit is contained in:
Bot of Thomas Güttler
2026-06-06 05:32:29 +02:00
committed by guettli
co-authored by guettli Thomas SharedInbox
parent 6a60c8d73b
commit 3e2da2bdf8
12 changed files with 24 additions and 0 deletions
+8
View File
@@ -58,6 +58,14 @@ tasks:
cmds: cmds:
- echo "Setup complete." - echo "Setup complete."
generate-icons:
desc: Rasterise icon.svg → icon.png and regenerate all platform launcher icons
deps: [_pub-get]
cmds:
- rsvg-convert -w 1024 -h 1024 icon.svg -o icon.png
- rsvg-convert -w 512 -h 512 icon.svg -o playstore/icon.png
- fvm flutter pub run flutter_launcher_icons
generate-changelog: generate-changelog:
desc: Generate assets/changelog.txt from git history desc: Generate assets/changelog.txt from git history
cmds: cmds:
Binary file not shown.

Before

Width:  |  Height:  |  Size: 544 B

After

Width:  |  Height:  |  Size: 7.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 442 B

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 721 B

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 25 KiB

+1
View File
@@ -100,6 +100,7 @@
])) # used by stalwart-dev/start and deploy_playstore.py ])) # used by stalwart-dev/start and deploy_playstore.py
fgj # Codeberg/Forgejo CLI (like gh for GitHub) fgj # Codeberg/Forgejo CLI (like gh for GitHub)
skopeo # inspect OCI image manifests without pulling layers (used by check-ci-images) skopeo # inspect OCI image manifests without pulling layers (used by check-ci-images)
librsvg # rsvg-convert — SVG→PNG for generate-icons task
]); ]);
shellHook = '' shellHook = ''
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

+4
View File
@@ -102,3 +102,7 @@ if(NOT CMAKE_BUILD_TYPE MATCHES "Debug")
install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
COMPONENT Runtime) COMPONENT Runtime)
endif() endif()
install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/sharedinbox.png"
DESTINATION "${CMAKE_INSTALL_PREFIX}"
COMPONENT Runtime)
+2
View File
@@ -31,6 +31,8 @@ static void my_application_activate(GApplication* application) {
fl_register_plugins(FL_PLUGIN_REGISTRY(view)); fl_register_plugins(FL_PLUGIN_REGISTRY(view));
gtk_window_set_icon_from_file(window, "sharedinbox.png", nullptr);
// Show AFTER adding FlView so GTK's first layout pass allocates the full // Show AFTER adding FlView so GTK's first layout pass allocates the full
// window content area (1280×800) to FlView, not the default 1×1. // window content area (1280×800) to FlView, not the default 1×1.
gtk_widget_show_all(GTK_WIDGET(window)); gtk_widget_show_all(GTK_WIDGET(window));
Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

+9
View File
@@ -81,6 +81,15 @@ dev_dependencies:
sqlite3: ^3.1.5 # used directly in test/unit/db_test_helper.dart; 3.x required for Database.close() sqlite3: ^3.1.5 # used directly in test/unit/db_test_helper.dart; 3.x required for Database.close()
url_launcher_platform_interface: ^2.3.2 url_launcher_platform_interface: ^2.3.2
plugin_platform_interface: ^2.1.8 plugin_platform_interface: ^2.1.8
flutter_launcher_icons: ^0.13.1
flutter_icons:
android: "ic_launcher"
ios: false
image_path: "icon.png"
linux:
generate: true
image_path: "icon.png"
flutter: flutter:
uses-material-design: true uses-material-design: true