#include <dialog.h>
Inherits TQObject.
Public Types | |
enum | ContentInListView { Static , Configurable } |
Public Slots | |
void | show () |
Signals | |
void | pluginSelectionChanged () |
Public Member Functions | |
Dialog (TQWidget *parent=0, const char *name=0) | |
Dialog (ContentInListView content=Static, TQWidget *parent=0, const char *name=0) | |
Dialog (const TQStringList &components, TQWidget *parent=0, const char *name=0) | |
Dialog (const TQStringList &components, ContentInListView content, TQWidget *parent=0, const char *name=0) | |
void | addPluginInfos (const TQValueList< KPluginInfo * > &plugininfos) |
KCMultiDialog * | dialog () |
Protected Slots | |
void | configureTree () |
void | updateTreeList () |
Friends | |
class | PageNode |
Detailed Description
Generic configuration dialog that even works over component boundaries.
For more information see KSettings.
This class aims to standardize the use of configuration dialogs in KDE applications. Especially when using KParts and/or Plugins you face problems creating a consistent config dialog.
To show a configuration dialog you only have to call the show method and be done with it. A code example:
You initialize m_cfgdlg
with
If you use a KPart that was not especially designed for your app you can use the second constructor:
and the action for the config dialog is connected to the show slot:
If you need to be informed when the config was changed and applied in the dialog you might want to take a look at Dispatcher.
For more information see KSettings.
- Since
- 3.2
Member Enumeration Documentation
◆ ContentInListView
Tells the dialog whether the entries in the listview are all static or whether it should add a Configure...
button to select which parts of the optional functionality should be active or not.
Enumerator | |
---|---|
Static | Static listview, while running no entries are added or deleted. |
Configurable | Configurable listview. The user can select what functionality he wants. |
Constructor & Destructor Documentation
◆ Dialog() [1/4]
KSettings::Dialog::Dialog | ( | TQWidget * | parent = 0 , |
const char * | name = 0 |
||
) |
Construct a new Preferences Dialog for the application.
It uses all KCMs with X-TDE-ParentApp set to TDEGlobal::instance()->instanceName().
- Parameters
-
parent The parent is only used as the parent for the dialog - centering the dialog over the parent widget. name name
Definition at line 358 of file dialog.cpp.
◆ Dialog() [2/4]
KSettings::Dialog::Dialog | ( | ContentInListView | content = Static , |
TQWidget * | parent = 0 , |
||
const char * | name = 0 |
||
) |
Construct a new Preferences Dialog for the application.
It uses all KCMs with X-TDE-ParentApp set to TDEGlobal::instance()->instanceName().
- Parameters
-
content Select whether you want a static or configurable config dialog. parent The parent is only used as the parent for the dialog - centering the dialog over the parent widget. name name
Definition at line 367 of file dialog.cpp.
◆ Dialog() [3/4]
KSettings::Dialog::Dialog | ( | const TQStringList & | components, |
TQWidget * | parent = 0 , |
||
const char * | name = 0 |
||
) |
Construct a new Preferences Dialog with the pages for the selected instance names.
For example if you want to have the configuration pages for the kviewviewer KPart you would pass a TQStringList consisting of only the name of the part "kviewviewer".
- Parameters
-
components A list of the names of the components that your config dialog should merge the config pages in. parent The parent is only used as the parent for the dialog - centering the dialog over the parent widget. name name
Definition at line 377 of file dialog.cpp.
◆ Dialog() [4/4]
KSettings::Dialog::Dialog | ( | const TQStringList & | components, |
ContentInListView | content, | ||
TQWidget * | parent = 0 , |
||
const char * | name = 0 |
||
) |
Construct a new Preferences Dialog with the pages for the selected instance names.
For example if you want to have the configuration pages for the kviewviewer KPart you would pass a TQStringList consisting of only the name of the part "kviewviewer".
- Parameters
-
components A list of the names of the components that your config dialog should merge the config pages in. content Select whether you want a static or configurable config dialog. parent The parent is only used as the parent for the dialog - centering the dialog over the parent widget. name name
Definition at line 387 of file dialog.cpp.
Member Function Documentation
◆ addPluginInfos()
void KSettings::Dialog::addPluginInfos | ( | const TQValueList< KPluginInfo * > & | plugininfos | ) |
If you use a Configurable dialog you need to pass KPluginInfo objects that the dialog should configure.
Definition at line 402 of file dialog.cpp.
◆ pluginSelectionChanged
|
signal |
If you use the dialog in Configurable mode and want to be notified when the user changes the plugin selections use this signal.
It's emitted if the selection has changed and the user pressed Apply or Ok. In the slot you would then load and unload the plugins as requested.
◆ show
|
slot |
Show the config dialog.
The slot immediatly returns since the dialog is non-modal.
Definition at line 413 of file dialog.cpp.
The documentation for this class was generated from the following files: