我有一个自定义文件类型,为它制作了一个自定义 MIME 类型,并为其关联了一个图标。现在我想用我的自定义可执行文件打开它。如果我点击Open
我会得到一个对话框Could not display ... There is no application installed for ... files. Do you want to search for an application to open this file?,点击yes
一个包含ubuntu software
图标的弹出窗口Additional MIME types required. An application is requesting additional file format support.选择Open with another application
不会导致输入自定义命令行的可能性。
我的 ubuntu 是 18.04。我还有一个 lubuntu 18.04,它就像一个魅力。我觉得在 ubuntu 中我必须处理ubuntu software
我没有找到添加自定义应用程序的方法。如何才能做到这一点?
于是,我找到了一种方法,以我的自定义程序添加到列表All applications
中的一部分Open with other application
。我在~/.local/share/applications
包含内容的文件夹中添加了一个文件 myapp.desktop :
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Icon[en_US]=path_to_my_icon
Name[en_US]=myapp
Exec=path_to_my_executable %F
Hidden=false
然后就很容易了。我想知道是否有更简单的方法来获得相同的结果。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句