• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeutils
 

tdeutils

Public Member Functions | Protected Member Functions | List of all members
TDECModuleInfo Class Reference
KControl module classes

#include <tdecmoduleinfo.h>

Public Member Functions

 TDECModuleInfo (const TQString &desktopFile)
 
 TDECModuleInfo (KService::Ptr moduleInfo)
 
 TDECModuleInfo (const TDECModuleInfo &rhs)
 
 TDECModuleInfo ()
 
TDECModuleInfo & operator= (const TDECModuleInfo &rhs)
 
bool operator== (const TDECModuleInfo &rhs) const
 
bool operator!= (const TDECModuleInfo &rhs) const
 
 ~TDECModuleInfo ()
 
TQString fileName () const
 
const TQStringList & keywords () const
 
TQString factoryName () const
 
TQString moduleName () const
 
KService::Ptr service () const
 
TQString comment () const
 
TQString icon () const
 
TQString docPath () const
 
TQString library () const
 
TQString handle () const
 
int weight () const
 
bool needsRootPrivileges () const
 
bool isHiddenByDefault () const TDE_DEPRECATED
 
bool needsTest () const
 

Protected Member Functions

void setKeywords (const TQStringList &keyword)
 
void setName (const TQString &name)
 
void setComment (const TQString &comment)
 
void setIcon (const TQString &icon)
 
void setLibrary (const TQString &lib)
 
void setHandle (const TQString &handle)
 
void setWeight (int weight)
 
void setNeedsTest (bool val)
 
void setNeedsRootPrivileges (bool needsRootPrivileges)
 
void setIsHiddenByDefault (bool isHiddenByDefault)
 
void setDocPath (const TQString &p)
 
void loadAll ()
 

Detailed Description

A class that provides information about a TDECModule.

TDECModuleInfo provides various technical information, such as icon, library etc. about a TDECModule.n

Note
Any values set with the set* functions is not written back with TDECModuleInfo it only reads value from the desktop file.

Definition at line 49 of file tdecmoduleinfo.h.

Constructor & Destructor Documentation

◆ TDECModuleInfo() [1/4]

TDECModuleInfo::TDECModuleInfo ( const TQString &  desktopFile)

Constructs a TDECModuleInfo.

Note
a TDECModuleInfo object will have to be manually deleted, it is not done automatically for you.
Parameters
desktopFilethe desktop file representing the module, or the name of the module.

Definition at line 54 of file tdecmoduleinfo.cpp.

◆ TDECModuleInfo() [2/4]

TDECModuleInfo::TDECModuleInfo ( KService::Ptr  moduleInfo)

Same as above but takes a KService::Ptr as argument.

Note
moduleInfo must be a valid pointer.
Parameters
moduleInfospecifies the module

Definition at line 61 of file tdecmoduleinfo.cpp.

◆ TDECModuleInfo() [3/4]

TDECModuleInfo::TDECModuleInfo ( const TDECModuleInfo &  rhs)

Same as above but takes a TDECModuleInfo as argument.

Parameters
rhsspecifies the module

Definition at line 66 of file tdecmoduleinfo.cpp.

◆ TDECModuleInfo() [4/4]

TDECModuleInfo::TDECModuleInfo ( )

Same as above but creates an empty TDECModuleInfo.

You should not normally call this.

Since
3.4

Definition at line 48 of file tdecmoduleinfo.cpp.

◆ ~TDECModuleInfo()

TDECModuleInfo::~TDECModuleInfo ( )

Default destructor.

Definition at line 117 of file tdecmoduleinfo.cpp.

Member Function Documentation

◆ comment()

TQString TDECModuleInfo::comment ( ) const
inline
Returns
the module's (translated) comment field

Definition at line 142 of file tdecmoduleinfo.h.

◆ docPath()

TQString TDECModuleInfo::docPath ( ) const
Returns
the path of the module's documentation

Definition at line 183 of file tdecmoduleinfo.cpp.

◆ factoryName()

TQString TDECModuleInfo::factoryName ( ) const

Returns the module's factory name, if it's set.

If not, the library name is returned.

Returns
the module's factory name
Since
3.4

Definition at line 95 of file tdecmoduleinfo.cpp.

◆ fileName()

TQString TDECModuleInfo::fileName ( ) const
inline
Returns
the filename of the .desktop file that describes the KCM

Definition at line 113 of file tdecmoduleinfo.h.

◆ handle()

TQString TDECModuleInfo::handle ( ) const
Returns
a handle (usually the contents of the FactoryName field)

Definition at line 192 of file tdecmoduleinfo.cpp.

◆ icon()

TQString TDECModuleInfo::icon ( ) const
inline
Returns
the module's icon name

Definition at line 147 of file tdecmoduleinfo.h.

◆ isHiddenByDefault()

bool TDECModuleInfo::isHiddenByDefault ( ) const
Deprecated:
Returns
the isHiddenByDefault attribute.

Definition at line 222 of file tdecmoduleinfo.cpp.

◆ keywords()

const TQStringList & TDECModuleInfo::keywords ( ) const
inline
Returns
the keywords associated with this KCM.

Definition at line 118 of file tdecmoduleinfo.h.

◆ library()

TQString TDECModuleInfo::library ( ) const
inline
Returns
the library name

Definition at line 157 of file tdecmoduleinfo.h.

◆ loadAll()

void TDECModuleInfo::loadAll ( )
protected

Reads the service entries specific for TDECModule from the desktop file.

The usual desktop entries are read in init.

Definition at line 150 of file tdecmoduleinfo.cpp.

◆ moduleName()

TQString TDECModuleInfo::moduleName ( ) const
inline
Returns
the module\'s (translated) name

Definition at line 131 of file tdecmoduleinfo.h.

◆ needsRootPrivileges()

bool TDECModuleInfo::needsRootPrivileges ( ) const
Returns
whether the module might require root permissions

Definition at line 213 of file tdecmoduleinfo.cpp.

◆ needsTest()

bool TDECModuleInfo::needsTest ( ) const
Returns
true if the module should be conditionally loaded.
Since
3.4

Definition at line 230 of file tdecmoduleinfo.cpp.

◆ operator!=()

bool TDECModuleInfo::operator!= ( const TDECModuleInfo &  rhs) const
Returns
true if rhs is not equal itself

Definition at line 112 of file tdecmoduleinfo.cpp.

◆ operator=()

TDECModuleInfo & TDECModuleInfo::operator= ( const TDECModuleInfo &  rhs)

Assignment operator.

Definition at line 75 of file tdecmoduleinfo.cpp.

◆ operator==()

bool TDECModuleInfo::operator== ( const TDECModuleInfo &  rhs) const

Equal operator.

Returns
true if rhs equals itself

Definition at line 107 of file tdecmoduleinfo.cpp.

◆ service()

KService::Ptr TDECModuleInfo::service ( ) const
inline
Returns
a TDESharedPtr to KService created from the modules .desktop file

Definition at line 137 of file tdecmoduleinfo.h.

◆ setComment()

void TDECModuleInfo::setComment ( const TQString &  comment)
inlineprotected

Sets the object's name.

Parameters
commentthe new comment

Definition at line 208 of file tdecmoduleinfo.h.

◆ setDocPath()

void TDECModuleInfo::setDocPath ( const TQString &  p)
inlineprotected

Sets the object's documentation path.

Parameters
pthe new documentation path

Definition at line 262 of file tdecmoduleinfo.h.

◆ setHandle()

void TDECModuleInfo::setHandle ( const TQString &  handle)
inlineprotected

Sets the factory name.

Parameters
handleThe new factory name

Definition at line 226 of file tdecmoduleinfo.h.

◆ setIcon()

void TDECModuleInfo::setIcon ( const TQString &  icon)
inlineprotected

Sets the object's icon.

Parameters
iconthe name of the new icon

Definition at line 214 of file tdecmoduleinfo.h.

◆ setIsHiddenByDefault()

void TDECModuleInfo::setIsHiddenByDefault ( bool  isHiddenByDefault)
inlineprotected
Deprecated:

Definition at line 255 of file tdecmoduleinfo.h.

◆ setKeywords()

void TDECModuleInfo::setKeywords ( const TQStringList &  keyword)
inlineprotected

Sets the object's keywords.

Parameters
keywordthe new keywords

Definition at line 196 of file tdecmoduleinfo.h.

◆ setLibrary()

void TDECModuleInfo::setLibrary ( const TQString &  lib)
inlineprotected

Set the object's library.

Parameters
libthe name of the new library without any extensions or prefixs.

Definition at line 220 of file tdecmoduleinfo.h.

◆ setName()

void TDECModuleInfo::setName ( const TQString &  name)
inlineprotected

Sets the object's name.

Parameters
namethe new name

Definition at line 202 of file tdecmoduleinfo.h.

◆ setNeedsRootPrivileges()

void TDECModuleInfo::setNeedsRootPrivileges ( bool  needsRootPrivileges)
inlineprotected

Toggles whether the represented module needs root privileges.

Use with caution.

Parameters
needsRootPrivilegesif module needs root privilges

Definition at line 249 of file tdecmoduleinfo.h.

◆ setNeedsTest()

void TDECModuleInfo::setNeedsTest ( bool  val)
protected

Sets if the module should be tested for loading.

Parameters
valthe value to set
Since
3.4

Definition at line 238 of file tdecmoduleinfo.cpp.

◆ setWeight()

void TDECModuleInfo::setWeight ( int  weight)
inlineprotected

Sets the object's weight property which determines in what order modules will be displayed.

Default is 100.

Parameters
weightthe new weight

Definition at line 234 of file tdecmoduleinfo.h.

◆ weight()

int TDECModuleInfo::weight ( ) const
Returns
the weight of the module which determines the order of the pages in the KCMultiDialog. It's set by the X-TDE-Weight field.

Definition at line 204 of file tdecmoduleinfo.cpp.


The documentation for this class was generated from the following files:
  • tdecmoduleinfo.h
  • tdecmoduleinfo.cpp

tdeutils

Skip menu "tdeutils"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

tdeutils

Skip menu "tdeutils"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeutils by doxygen 1.9.4
This website is maintained by Timothy Pearson.