Skip to content

Commit 7085fb8

Browse files
committed
Another experimental AppImage icon change... for better support of AppImage desktopintegration
1 parent fc20838 commit 7085fb8

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

installer/build-server.py

+9-5
Original file line numberDiff line numberDiff line change
@@ -327,20 +327,24 @@ def parse_version_info(version_path):
327327
# Recursively create AppDir /usr folder
328328
os.makedirs(os.path.join(app_dir_path, "usr"), exist_ok=True)
329329

330-
# Install program icon
331-
icon_256_png = os.path.join(PATH, "xdg", "icon", "256", "openshot-qt.png")
332-
shutil.copyfile(icon_256_png, os.path.join(app_dir_path, "openshot-qt.png"))
330+
# Install program icon (as a 128x128 PNG & SVG)
331+
icon_svg = os.path.join(PATH, "xdg", "openshot-qt.svg")
332+
icon_128_png = os.path.join(PATH, "xdg", "icon", "128", "openshot-qt.png")
333+
shutil.copyfile(icon_128_png, os.path.join(app_dir_path, "openshot-qt.png"))
334+
shutil.copyfile(icon_svg, os.path.join(app_dir_path, "openshot-qt.svg"))
333335

334336
# Install .DirIcon AppImage icon
335337
# See: https://docs.appimage.org/reference/appdir.html
336338
# SVG icon not supported on Chrome OS (with AppImage desktop integration)
337339
# PNG is assumed with desktop integration
338-
shutil.copyfile(icon_256_png, os.path.join(app_dir_path, ".DirIcon"))
340+
shutil.copyfile(icon_128_png, os.path.join(app_dir_path, ".DirIcon"))
339341

340342
dest = os.path.join(app_dir_path, "usr", "share", "pixmaps")
341343
os.makedirs(dest, exist_ok=True)
342344

343-
shutil.copyfile(icon_256_png, os.path.join(dest, "openshot-qt.png"))
345+
# Copy pixmaps (as a 128x128 PNG & SVG)
346+
shutil.copyfile(icon_128_png, os.path.join(dest, "openshot-qt.png"))
347+
shutil.copyfile(icon_svg, os.path.join(dest, "openshot-qt.svg"))
344348

345349
# Install MIME handler
346350
dest = os.path.join(app_dir_path, "usr", "share", "mime", "packages")

0 commit comments

Comments
 (0)