HomePage > ComponentHowTo Components and HowTos > GuiIndex GUI > WindowManagers

.desktop files

.desktop files are the standard way for Linux programs to provide information about themselves and how they are run. These files are stored at /usr/share/applications. Many programs come ready with a .desktop file. If a menu entry is required include one. Here is the example of AbiWord AbiWord's:-

[Desktop Entry]
Exec=abiword 
Icon=/usr/share/icons/abiword_48.png
Terminal=false
Type=Application
Categories=X-DocumentUtility;
StartupNotify=true
X-Desktop-File-Install-Version=0.9
MimeType=application/x-abiword;text/x-abiword;text/x-xml-abiword;text/plain;application/msword;application/rtf;application/vnd.plain;application/xhtml+xml;text/html;application/x-crossmark;application/docbook+xml;application/x-t602;application/vnd.oasis.opendocument.text;application/vnd.oasis.opendocument.text-template;application/vnd.oasis.opendocument.text-web;application/vnd.sun.xml.writer;application/vnd.stardivision.writer;text/vnd.wap.wml;application/wordperfect6;application/wordperfect5.1;application/vnd.wordperfect;application/x-abicollab;
Name=AbiWord WordProcessor
GenericName=Word Processor
Comment=Compose, edit, and view documents
Name[de]=Textverarbeitung
Comment[de]=AbiWord Textverarbeitung
Name[nb]=Tekstbehandling
Comment[nb]=AbiWord Tekstbehandling
... (more languages) ...
Name[ja]=AbiWord ワードプロセッサ
Comment[ja]=AbiWord ワードプロセッサ


Exec= - Program's execute line. There may be no need to include '%F' if a program is only started from a menu and won't have a file passed to it.

Categories= - Entry controls which submenu they appears in. Run fixmenus and restart window manager after making alterations.

Icon= - If the icon is in folder /usr/share/pixmaps/ there is no need to include the its path (JWM automatically looks here)

Also on the Wiki


Categories
CategoryGUI
CategoryXDG
Comments
Comment by darkcity
2015-02-14 13:45:52
Merge with Software Package Creation
Comment by darkcity
2016-09-11 07:18:42
On second thoughts don't : -)
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki