添加qt桌面应用程序

添加qt桌面应用程序比较繁琐,提起来大家都是相当头疼的一块项目,经过我一系列的摸索,终于学会了用imx6添加qt桌面应用程序。
文件夹设置存放在:/usr/share/matchbox/vfolders
比如:dianyulinux.directory
[Desktop Entry]
Name=dianyulinux
Name[de]= Einstellungen
Comment=dianyulinux test app
Comment[de]=dianyulinux test app
Icon=mbfolder.png
Type=Directory
Match=dianyulinux
重要的是Match属性,它将决定何种类型的App显示在该文件夹中
文件夹的显示顺序在:/usr/share/matchbox/Root.order
dianyulinux
Applications
Utilities
Games
Settings
All

应用程序设置:
图标目录:/usr/share/pixmaps
应用程序的设置:/usr/share/applications
每一个应用程序对应一个.desktop文件,以Ping为例:
[Desktop Entry]
Name=Ping
Exec=/dianyulinux/qtbin/ping
Icon=ping-icon
Type=Application
Categories=dianyulinux;
Comment=Ping test.
它Icon指定了图标,Exec指定可执行程序的位置,Categories指定桌面中的哪个文件夹中显示,Comment注释名称。

点赞