KDEUI
kdialog.cpp
Go to the documentation of this file.
78 kWarning(240) << q->metaObject()->className() << "created with a layout; don't do that, KDialog takes care of it, use mainWidget or setMainWidget instead";
181 q->setPlainCaption(KGlobal::caption()); // set appropriate initial window title for case it gets not set later
190 : QDialog(parent, sAllowEmbeddingInGraphicsView ? flags : flags | Qt::BypassGraphicsProxyWidget ), d_ptr(new KDialogPrivate)
196 : QDialog(parent, sAllowEmbeddingInGraphicsView ? flags : flags | Qt::BypassGraphicsProxyWidget), d_ptr(&dd)
560 if( !( widget->windowFlags() & Qt::X11BypassWindowManagerHint ) && widget->windowType() != Qt::Popup
1033 void KDialog::saveDialogSize( KConfigGroup& config, KConfigGroup::WriteConfigFlags options ) const
1040 config.writeEntry( QString::fromLatin1("Width %1").arg( desk.width() ), sizeToSave.width(), options );
1041 config.writeEntry( QString::fromLatin1("Height %1").arg( desk.height() ), sizeToSave.height(), options );
static int marginHint()
Returns the number of pixels that should be used between a dialog edge and the outermost widget(s) ac...
Definition: kdialog.cpp:427
ButtonCode defaultButton() const
Returns the button code of the default button, or NoDefault if there is no default button...
Definition: kdialog.cpp:324
QString caption()
QString i18n(const char *text)
void setButtonGuiItem(ButtonCode id, const KGuiItem &item)
Sets the KGuiItem directly for the button instead of using 3 methods to set the text, tooltip and whatsthis strings.
Definition: kdialog.cpp:699
static void centerOnScreen(QWidget *widget, int screen=-1)
Centers widget on the desktop, taking multi-head setups into account.
Definition: kdialog.cpp:554
bool isButtonEnabled(ButtonCode id) const
Returns whether any button is enabled.
Definition: kdialog.cpp:668
static bool avoidArea(QWidget *widget, const QRect &area, int screen=-1)
Places widget so that it doesn't cover a certain area of the screen.
Definition: kdialog.cpp:572
Show Cancel-button. (this button reject()s the dialog; result set to QDialog::Rejected) ...
Definition: kdialog.h:144
#define K_GLOBAL_STATIC(TYPE, NAME)
void setHelp(const QString &anchor, const QString &appname=QString())
Sets the help path and topic.
Definition: kdialog.cpp:967
Show Yes button. (this button closes the dialog and sets the result to KDialog::Yes) ...
Definition: kdialog.h:147
static void resizeLayout(QWidget *widget, int margin, int spacing)
Resize every layout manager used in widget and its nested children.
Definition: kdialog.cpp:499
static void setAllowEmbeddingInGraphicsView(bool allowEmbedding)
Allow embedding the dialogs based on KDialog into a graphics view.
Definition: kdialog.cpp:1044
Definition: netwm_def.h:614
bool isDetailsWidgetVisible() const
Returns the status of the Details button.
Definition: kdialog.cpp:824
void writeEntry(const QString &key, const QVariant &value, WriteConfigFlags pFlags=Normal)
Definition: kdialog.h:443
Definition: kdialog.h:138
virtual void slotButtonClicked(int button)
Activated when the button button is clicked.
Definition: kdialog.cpp:877
void setButtonWhatsThis(ButtonCode id, const QString &text)
Sets the "What's this?" text of any button.
Definition: kdialog.cpp:778
void setButtonFocus(ButtonCode id)
Sets the focus to the button of the passed id.
Definition: kdialog.cpp:798
void setButtonToolTip(ButtonCode id, const QString &text)
Sets the tooltip text of any button.
Definition: kdialog.cpp:758
virtual void setCaption(const QString &caption)
Make a KDE compliant caption.
Definition: kdialog.cpp:469
void enableButtonApply(bool state)
Enable or disable (gray out) the Apply button.
Definition: kdialog.cpp:682
static void invokeHelp(const QString &anchor=QString(), const QString &appname=QString(), const QByteArray &startup_id=QByteArray())
QString i18nc(const char *ctxt, const char *text)
QString buttonWhatsThis(ButtonCode id) const
Returns the "What's this?" text of any button.
Definition: kdialog.cpp:789
Definition: kdialog.h:444
void showButtonSeparator(bool state)
Hide or display the a separator line drawn between the action buttons an the main widget...
Definition: kdialog.cpp:624
void setButtonMenu(ButtonCode id, QMenu *menu, ButtonPopupMode popupmode=InstantPopup)
Sets the menu of any button.
Definition: kdialog.cpp:708
static QString makeStandardCaption(const QString &userCaption, QWidget *window=0, CaptionFlags flags=HIGCompliantCaption)
Builds a caption that contains the application name along with the userCaption using a standard layou...
Definition: kdialog.cpp:442
void setButtonsOrientation(Qt::Orientation orientation)
Sets the orientation of the button box.
Definition: kdialog.cpp:268
static int spacingHint()
Returns the number of pixels that should be used between widgets inside a dialog according to the KDE...
Definition: kdialog.cpp:432
void setEscapeButton(ButtonCode id)
Sets the button that will be activated when the Escape key is pressed.
Definition: kdialog.cpp:282
Definition: kdialog.h:445
void setHelpLinkText(const QString &text)
Sets the text that is shown as the linked text.
Definition: kdialog.cpp:975
QString buttonToolTip(ButtonCode id) const
Returns the tooltip of any button.
Definition: kdialog.cpp:769
void restoreDialogSize(const KConfigGroup &config)
Restores the dialog's size from the configuration according to the screen size.
Definition: kdialog.cpp:1018
void setButtons(ButtonCodes buttonMask)
Creates (or recreates) the button box and all the buttons in it.
Definition: kdialog.cpp:206
Show Help button. (this button will run the help set with setHelp)
Definition: kdialog.h:139
void setButtonIcon(ButtonCode id, const KIcon &icon)
Sets the icon of any button.
Definition: kdialog.cpp:742
bool isSupported(NET::Property property) const
Returns true if the given property is supported by the window manager.
Definition: netwm.cpp:2640
void setDelayedMenu(QMenu *delayed_menu)
Sets a delayed popup menu for consistency, since menu() isn't virtual.
Definition: kpushbutton.cpp:307
Show Ok button. (this button accept()s the dialog; result set to QDialog::Accepted) ...
Definition: kdialog.h:141
void enableButtonOk(bool state)
Enable or disable (gray out) the OK button.
Definition: kdialog.cpp:677
static int groupSpacingHint()
Returns the number of pixels that should be used to visually separate groups of related options in a ...
Definition: kdialog.cpp:437
void setDefaultButton(ButtonCode id)
Sets the button that will be activated when the Enter key is pressed.
Definition: kdialog.cpp:287
void setDetailsWidget(QWidget *detailsWidget)
Sets the widget that gets shown when "Details" is enabled.
Definition: kdialog.cpp:806
void showButton(ButtonCode id, bool state)
Hide or display a general action button.
Definition: kdialog.cpp:692
KPushButton * button(ButtonCode id) const
Returns the button that corresponds to the id.
Definition: kdialog.cpp:655
Definition: kdialog.h:160
Show No button. (this button closes the dialog and sets the result to KDialog::No) ...
Definition: kdialog.h:146
void setGuiItem(const KGuiItem &item)
Sets the KGuiItem for this button.
Definition: kpushbutton.cpp:215
Definition: netwm_def.h:692
Used when specifying a default button; indicates that no button should be marked by default...
Definition: kdialog.h:153
void enableButton(ButtonCode id, bool state)
Enable or disable (gray out) a general action button.
Definition: kdialog.cpp:661
void setDetailsWidgetVisible(bool visible)
Sets the status of the Details button.
Definition: kdialog.cpp:829
static QDebug kWarning(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
void enableButtonCancel(bool state)
Enable or disable (gray out) the Cancel button.
Definition: kdialog.cpp:687
void setButtonText(ButtonCode id, const QString &text)
Sets the text of any button.
Definition: kdialog.cpp:719
virtual void setPlainCaption(const QString &caption)
Make a plain caption without any modifications.
Definition: kdialog.cpp:488
void enableLinkedHelp(bool state)
Display or hide the help link area on the top of the dialog.
Definition: kdialog.cpp:941
Show Details button. (this button will show the detail widget set with setDetailsWidget) ...
Definition: kdialog.h:149
void saveDialogSize(KConfigGroup &config, KConfigGroup::WriteConfigFlags options=KConfigGroup::Normal) const
Saves the dialog's size dependent on the screen dimension either to the global or application config ...
Definition: kdialog.cpp:1033
virtual void closeEvent(QCloseEvent *e)
Detects when a dialog is being closed from the window manager controls.
Definition: kdialog.cpp:1001
T readEntry(const QString &key, const T &aDefault) const
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:49:14 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:49:14 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.