为什么在 Windows 搜索工具栏中不使用 jpackage 图标? [英] why jpackage icon not used in windows search toolbar?

查看:78
本文介绍了为什么在 Windows 搜索工具栏中不使用 jpackage 图标?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用以下命令创建安装程序.我给 jpackage 使用的图标

jpackage --runtime-imagehellofx --modulehellofx/hellofx.HelloFX --win-shortcut --win-menu --icon smile.ico

当我安装程序时,图标用于桌面快捷方式,但在搜索工具栏中它仍然显示默认的 java 图标.有没有办法在搜索工具栏中使用给定的图标?我很感激任何帮助.谢谢!

更新:

在这里,图标似乎已正确应用于搜索工具栏中的应用图标.

更新 2:

开始菜单图标正确

解决方案

所以我终于解决了.正如坎贝尔指出的那样,这是一个缓存问题.由于某种原因,图标被缓存.这是一个例子.

我将图标更改为相机图标.新图标显示在桌面快捷方式和开始菜单中,如下所示.

在此图标之前,我使用了音乐图标.所以在搜索中旧图标仍然存在.所以这个图标出于某种原因被缓存.只有当我更改应用程序和图标时,所有图标才会更改为新图标.也许这是 Windows 10 的问题.所以问题现在已经解决了.

I am creating the installer using the following command. I am giving jpackage the icon to use

jpackage --runtime-image hellofx --module hellofx/hellofx.HelloFX --win-shortcut --win-menu --icon smile.ico

When i install the program the icon is used for desktop shortcut but in the search toolbar it still displays the default java icon. Is there a way to use the given icon in search toolbar as well? I appreciate any help. thanks!

UPDATE:

here it seems the icons are correctly applied to app icons in search toolbar.

https://walczak.it/blog/distributing-javafx-desktop-applications-without-requiring-jvm-using-jlink-and-jpackage

UPDATE 2:

Start menu icon is correct

解决方案

So i finally solved it. It was a caching issue like Campbell pointed out. For some reason the icon is cached. Here is an example.

I changed the icon to a camera icon. The new icons display in the desktop shortcut and in the start menu as shown below.

Before this icon i used a music icon. So in the search the old icon is still in place. So this icon is cached for some reason. Only if i change the app as well as icon then all icons are changed to the new icon. Maybe this is an issue with windows 10. So the issue is now solved.

这篇关于为什么在 Windows 搜索工具栏中不使用 jpackage 图标?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆