Class DesktopEntry

Subclass of IniLikeGroup for easy accessing of Desktop Entry properties.

class DesktopEntry
  : IniLikeGroup ;

Methods

NameDescription
actions Actions supported by application.
actions Sets the list of values for "Actions" list.
categories Categories this program belongs to.
categories Sets the list of values for the "Categories" list.
comment Tooltip for the entry, for example "View sites on the Internet".
comment Set "Comment" to commentary escaping the value if needed.
dbusActivable A boolean value specifying if D-Bus activation is supported for this application.
dbusActivable setter
displayName Specific name of the application, for example "Qupzilla".
displayName Set "Name" to name escaping the value if needed.
execValue Exec value of desktop file.
execValue Set "Exec" to exec escaping the value if needed.
genericName Generic name of the application, for example "Web Browser".
genericName Set "GenericName" to name escaping the value if needed.
hidden Hidden means the user deleted (at his level) something that was present (at an upper level, e.g. in the system dirs). It's strictly equivalent to the .desktop file not existing at all, as far as that user is concerned.
hidden setter
iconName Icon to display in file manager, menus, etc.
iconName Set Icon value.
keywords A list of strings which may be used in addition to other metadata to describe this entry.
keywords Sets the list of values for the "Keywords" list.
localizedComment
localizedDisplayName
localizedGenericName
localizedIconName
localizedKeywords A list of localied strings which may be used in addition to other metadata to describe this entry.
mimeTypes The MIME type(s) supported by this application.
mimeTypes Sets the list of values for the "MimeType" list.
noDisplay NoDisplay means "this application exists, but don't display it in the menus".
noDisplay setter
notShowIn A list of strings identifying the desktop environments that should not display a given desktop entry.
notShowIn setter
onlyShowIn A list of strings identifying the desktop environments that should display a given desktop entry.
onlyShowIn setter
showIn Check if desktop file should be shown in menu of specific desktop environment.
startupNotify A boolean value specifying if an application uses Startup Notification Protocol.
startupNotify setter
terminal Whether the program runs in a terminal window.
terminal setter
tryExecValue Value used to determine if the program is actually installed.
tryExecValue Set TryExec value escaping it if needed.
type Type of desktop entry.
type Sets "Type" field to type
url URL to access.
url Set "URL" to link escaping the value if needed.
workingDirectory The working directory to run the program in.
workingDirectory Set Path value.
addCommentAfter Add comment after some node.
addCommentBefore Add comment before some node.
appendComment Add comment line into the group.
appendValue Add key-value entry without diret association of the value with the key. Can be used to add duplicates.
byIniLine
byKeyValue Iterate by Key-Value pairs. Values are left in escaped form.
byNode Iterate over nodes of internal list.
contains Check if the group contains a value associated with the key.
emptyByKeyValue Empty range of the same type as byKeyValue. Can be used in derived classes if it's needed to have an empty range.
escapedValue Get value by key in escaped form.
escapedValue Perform locale matching lookup as described in Localized values for keys.
getNode Get internal list node for key.
groupName Get name of this group.
moveLineAfter Move line after other line in the group.
moveLineBefore Move line before other line in the group.
moveLineToBack Move line to the end of group.
moveLineToFront Move line to the start of group.
prependComment Add comment line at the start of group (after group header, before any key-value pairs).
removeEntry Removes entry by key. Do nothing if no value associated with key found.
removeEntry ditto, but remove entry by localized key.
removeEntry ditto, but remove entry by node.
setEscapedValue Set value associated with key.
setEscapedValue Set value associated with key and locale.
setUnescapedValue Set value by key. The value is considered to be in the unescaped form.
setUnescapedValue ditto, localized version
unescapedValue Get value by key.
validateKey Validate key before setting value to key for this group and throw exception if not valid. Can be reimplemented in derived classes.
validateValue Validate value for key before setting value to key for this group and throw exception if not valid. Can be reimplemented in derived classes. The key is provided because you may want to implement specific checks depending on the key name.

Inner structs

NameDescription
LineNode Wrapper for internal ListMap node.

Enums

NameDescription
Type Desktop entry type
InvalidKeyPolicy