Qx v0.5.8
Qt Extensions Library
Loading...
Searching...
No Matches
Qx::ApplicationDesktopEntry Class Reference

The ApplicationDesktopEntry class represents an Application type desktop entry. More...

#include <qx/linux/qx-applicationdesktopentry.h>

Collaboration diagram for Qx::ApplicationDesktopEntry:
[legend]

Public Member Functions

 ApplicationDesktopEntry ()
 
DesktopAction action (const QString &actionName)
 
QList< DesktopActionactions ()
 
QStringList categories () const
 
QString exec ()
 
QString extension () const override
 
QStringList implements () const
 
void insertAction (const DesktopAction &action)
 
bool isDBusActivatable ()
 
bool isPrefersNonDefaultGPU () const
 
bool isSingleMainWindow () const
 
bool isStartupNotify () const
 
bool isTerminal ()
 
QStringList keywords () const
 
QStringList mimeTypes () const
 
QString path ()
 
void removeAction (const QString &actionName)
 
void setCategories (const QStringList &categories)
 
void setDBusActivatable (bool activatable)
 
void setExec (const QString &exec)
 
void setImplements (const QStringList &implements)
 
void setKeywords (const QStringList &keywords)
 
void setMimeTypes (const QStringList &mimeTypes)
 
void setPath (const QString &path)
 
void setPrefersNonDefaultGPU (bool prefers)
 
void setSingleMainWindow (bool single)
 
void setStartupNotify (bool notify)
 
void setStartupWMClass (const QString &wmClass)
 
void setTerminal (bool terminal)
 
void setTryExec (const QString &tryExec)
 
QString startupWMClass () const
 
QString toString () const override
 
QString tryExec ()
 
QString type () const override
 
- Public Member Functions inherited from Qx::DesktopEntry
QString comment () const
 
QString genericName () const
 
QString icon () const
 
bool isHidden () const
 
bool isNoDisplay () const
 
QString name () const
 
QStringList notShowIn () const
 
QStringList onlyShowIn () const
 
void setComment (const QString &comment)
 
void setGenericName (const QString &name)
 
void setHidden (bool hidden)
 
void setIcon (const QString &icon)
 
void setName (const QString &name)
 
void setNoDisplay (bool display)
 
void setNotShowIn (const QStringList &notIn)
 
void setOnlyShowIn (const QStringList &showIn)
 

Additional Inherited Members

- Static Public Member Functions inherited from Qx::DesktopEntry
static IoOpReport writeToDisk (QString path, const DesktopEntry *entry)
 
- Static Protected Member Functions inherited from Qx::DesktopEntry
static QString keyValueString (const QString &key, bool value)
 
static QString keyValueString (const QString &key, const char *value)
 
static QString keyValueString (const QString &key, const QString &value)
 
static QString keyValueString (const QString &key, const QStringList &value)
 

Detailed Description

See also
DesktopEntry.

Constructor & Destructor Documentation

◆ ApplicationDesktopEntry()

Qx::ApplicationDesktopEntry::ApplicationDesktopEntry ( )

Constructs an empty application desktop entry.

Member Function Documentation

◆ action()

DesktopAction Qx::ApplicationDesktopEntry::action ( const QString & actionName)

Returns the application action of this entry with the action name actionName, if present; otherwise, returns an empty action.

◆ actions()

QList< DesktopAction > Qx::ApplicationDesktopEntry::actions ( )

Returns the entry's application actions.

◆ categories()

QStringList Qx::ApplicationDesktopEntry::categories ( ) const

Returns the categories in which the entry should be shown in a menu.

◆ exec()

QString Qx::ApplicationDesktopEntry::exec ( )

Returns the full path of the associated application and its arguments.

◆ extension()

QString Qx::ApplicationDesktopEntry::extension ( ) const
overridevirtual

Returns the proper extension of the entry that corresponds to its type.

Implements Qx::DesktopEntry.

◆ implements()

QStringList Qx::ApplicationDesktopEntry::implements ( ) const

Returns the interfaces that the associated applications implements.

◆ insertAction()

void Qx::ApplicationDesktopEntry::insertAction ( const DesktopAction & action)

Adds the application action action to the entry.

◆ isDBusActivatable()

bool Qx::ApplicationDesktopEntry::isDBusActivatable ( )

Returns true if D-Bus activation is supported by the associated application; otherwise, returns false.

◆ isPrefersNonDefaultGPU()

bool Qx::ApplicationDesktopEntry::isPrefersNonDefaultGPU ( ) const

Returns true if the associated application prefers to be run on a more powerful discrete GPU if available; otherwise, returns false.

◆ isSingleMainWindow()

bool Qx::ApplicationDesktopEntry::isSingleMainWindow ( ) const

Returns true if the application has a single main window and does not support having an additional one opened; otherwise, returns false.

◆ isStartupNotify()

bool Qx::ApplicationDesktopEntry::isStartupNotify ( ) const

Returns true if the associated application sends a 'remove' message when started with the "DESKTOP_STARTUP_ID" environment variable set; otherwise, returns false.

◆ isTerminal()

bool Qx::ApplicationDesktopEntry::isTerminal ( )

Returns true if the program runs in a terminal window; otherwise, returns false.

◆ keywords()

QStringList Qx::ApplicationDesktopEntry::keywords ( ) const

Returns the additional words used to describe this entry.

◆ mimeTypes()

QStringList Qx::ApplicationDesktopEntry::mimeTypes ( ) const

Returns the MIME types supported by the associated application.

◆ path()

QString Qx::ApplicationDesktopEntry::path ( )

Returns the working directory of the associated application .

◆ removeAction()

void Qx::ApplicationDesktopEntry::removeAction ( const QString & actionName)

Removes the application action with the action name actionName from the entry if present; otherwise, does nothing.

◆ setCategories()

void Qx::ApplicationDesktopEntry::setCategories ( const QStringList & categories)

Sets the categories in which the entry should be shown in a menu to categories.

◆ setDBusActivatable()

void Qx::ApplicationDesktopEntry::setDBusActivatable ( bool activatable)

Sets whether or not D-Bus activation is supported by the associated application.

◆ setExec()

void Qx::ApplicationDesktopEntry::setExec ( const QString & exec)

Sets the full path of the associated application and its arguments to exec.

◆ setImplements()

void Qx::ApplicationDesktopEntry::setImplements ( const QStringList & implements)

Sets the interfaces that the associated application implements to implements.

◆ setKeywords()

void Qx::ApplicationDesktopEntry::setKeywords ( const QStringList & keywords)

Sets the additional words used to describe this entry to keywords.

◆ setMimeTypes()

void Qx::ApplicationDesktopEntry::setMimeTypes ( const QStringList & mimeTypes)

Sets the MIME types supported by the associated application to mimeTypes.

◆ setPath()

void Qx::ApplicationDesktopEntry::setPath ( const QString & path)

Sets the working directory of the associated application to path.

◆ setPrefersNonDefaultGPU()

void Qx::ApplicationDesktopEntry::setPrefersNonDefaultGPU ( bool prefers)

Sets whether or not the associated application prefers to be run on a more powerful discrete GPU if available

◆ setSingleMainWindow()

void Qx::ApplicationDesktopEntry::setSingleMainWindow ( bool single)

Sets whether or not the application has a single main window and does not support having an additional one opened

◆ setStartupNotify()

void Qx::ApplicationDesktopEntry::setStartupNotify ( bool notify)

Sets whether or not the associated application is known to send a 'remove' message when stared with the "DESKTOP_STARTUP_ID" environment variable set.

◆ setStartupWMClass()

void Qx::ApplicationDesktopEntry::setStartupWMClass ( const QString & wmClass)

Sets the string that the associated application is known to map to a least window as its WM class or WM name hint to wmClass.

◆ setTerminal()

void Qx::ApplicationDesktopEntry::setTerminal ( bool terminal)

Sets whether or not the program runs in a terminal window.

◆ setTryExec()

void Qx::ApplicationDesktopEntry::setTryExec ( const QString & tryExec)

Sets the path to the executable to use to determine if the associated application is actually installed to tryExec.

◆ startupWMClass()

QString Qx::ApplicationDesktopEntry::startupWMClass ( ) const

Returns the string that the associated application is known to map to a least window as its WM class or WM name hint.

◆ toString()

QString Qx::ApplicationDesktopEntry::toString ( ) const
overridevirtual

Composites the desktop entry into its string form, as would be found in an entry file on disk.

Warning
If this string is later written to disk, you must ensure that the correct extension is used in correspondence with the entry's type.
See also
extension(), and type().

Reimplemented from Qx::DesktopEntry.

◆ tryExec()

QString Qx::ApplicationDesktopEntry::tryExec ( )

Returns the path to an executable used to determine if associated application is actually installed.

◆ type()

QString Qx::ApplicationDesktopEntry::type ( ) const
overridevirtual

Returns the type string of the entry.

Implements Qx::DesktopEntry.


The documentation for this class was generated from the following files: