• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdelibs-4.14.38 API Reference
  • KDE Home
  • Contact Us
 

KIO

Public Slots | Public Member Functions | Protected Slots | List of all members
KOpenWithDialog Class Reference

#include <kopenwithdialog.h>

Inheritance diagram for KOpenWithDialog:
KDialog QDialog

Public Slots

void slotHighlighted (const QString &_name, const QString &_exec)
 
void slotSelected (const QString &_name, const QString &_exec)
 
void slotTerminalToggled (bool)
 
void slotTextChanged ()
 
- Public Slots inherited from KDialog
void delayedDestruct ()
 
void enableButton (ButtonCode id, bool state)
 
void enableButtonApply (bool state)
 
void enableButtonCancel (bool state)
 
void enableButtonOk (bool state)
 
void enableLinkedHelp (bool state)
 
bool isDetailsWidgetVisible () const
 
virtual void setCaption (const QString &caption)
 
virtual void setCaption (const QString &caption, bool modified)
 
void setDetailsWidget (QWidget *detailsWidget)
 
void setDetailsWidgetVisible (bool visible)
 
void setHelp (const QString &anchor, const QString &appname=QString())
 
void setHelpLinkText (const QString &text)
 
virtual void setPlainCaption (const QString &caption)
 

Public Member Functions

 KOpenWithDialog (const KUrl::List &urls, const QString &text, const QString &value, QWidget *parent=0)
 
 KOpenWithDialog (const KUrl::List &urls, QWidget *parent=0)
 
 KOpenWithDialog (const QString &mimeType, const QString &value, QWidget *parent=0)
 
 KOpenWithDialog (QWidget *parent=0)
 
 ~KOpenWithDialog ()
 
void hideNoCloseOnExit ()
 
void hideRunInTerminal ()
 
KService::Ptr service () const
 
void setSaveNewApplications (bool b)
 
QString text () const
 
- Public Member Functions inherited from KDialog
 KDialog (QWidget *parent=0, Qt::WindowFlags flags=0)
 
 ~KDialog ()
 
KPushButton * button (ButtonCode id) const
 
KIcon buttonIcon (ButtonCode id) const
 
QString buttonText (ButtonCode id) const
 
QString buttonToolTip (ButtonCode id) const
 
QString buttonWhatsThis (ButtonCode id) const
 
ButtonCode defaultButton () const
 
QString helpLinkText () const
 
void incrementInitialSize (const QSize &size)
 
bool isButtonEnabled (ButtonCode id) const
 
QWidget * mainWidget ()
 
virtual QSize minimumSizeHint () const
 
void restoreDialogSize (const KConfigGroup &config)
 
void saveDialogSize (KConfigGroup &config, KConfigGroup::WriteConfigFlags options=KConfigGroup::Normal) const
 
void setButtonFocus (ButtonCode id)
 
void setButtonGuiItem (ButtonCode id, const KGuiItem &item)
 
void setButtonIcon (ButtonCode id, const KIcon &icon)
 
void setButtonMenu (ButtonCode id, QMenu *menu, ButtonPopupMode popupmode=InstantPopup)
 
void setButtons (ButtonCodes buttonMask)
 
void setButtonsOrientation (Qt::Orientation orientation)
 
void setButtonText (ButtonCode id, const QString &text)
 
void setButtonToolTip (ButtonCode id, const QString &text)
 
void setButtonWhatsThis (ButtonCode id, const QString &text)
 
void setDefaultButton (ButtonCode id)
 
void setEscapeButton (ButtonCode id)
 
void setInitialSize (const QSize &size)
 
void setMainWidget (QWidget *widget)
 
void showButton (ButtonCode id, bool state)
 
void showButtonSeparator (bool state)
 
virtual QSize sizeHint () const
 

Protected Slots

virtual void accept ()
 
- Protected Slots inherited from KDialog
virtual void slotButtonClicked (int button)
 
void updateGeometry ()
 

Additional Inherited Members

- Public Types inherited from KDialog
enum  ButtonCode
 
enum  ButtonPopupMode
 
enum  CaptionFlag
 
- Signals inherited from KDialog
void aboutToShowDetails ()
 
void applyClicked ()
 
void buttonClicked (KDialog::ButtonCode button)
 
void cancelClicked ()
 
void closeClicked ()
 
void defaultClicked ()
 
void finished ()
 
void helpClicked ()
 
void hidden ()
 
void layoutHintChanged ()
 
void noClicked ()
 
void okClicked ()
 
void resetClicked ()
 
void tryClicked ()
 
void user1Clicked ()
 
void user2Clicked ()
 
void user3Clicked ()
 
void yesClicked ()
 
- Static Public Member Functions inherited from KDialog
static bool avoidArea (QWidget *widget, const QRect &area, int screen=-1)
 
static void centerOnScreen (QWidget *widget, int screen=-1)
 
static int groupSpacingHint ()
 
static QString makeStandardCaption (const QString &userCaption, QWidget *window=0, CaptionFlags flags=HIGCompliantCaption)
 
static int marginHint ()
 
static void resizeLayout (QLayout *lay, int margin, int spacing)
 
static void resizeLayout (QWidget *widget, int margin, int spacing)
 
static void setAllowEmbeddingInGraphicsView (bool allowEmbedding)
 
static int spacingHint ()
 
- Public Attributes inherited from KDialog
 Apply
 
 AppNameCaption
 
 Cancel
 
 Close
 
 Default
 
 DelayedPopup
 
 Details
 
 Help
 
 HIGCompliantCaption
 
 InstantPopup
 
 ModifiedCaption
 
 No
 
 NoCaptionFlags
 
 NoDefault
 
 None
 
 Ok
 
 Reset
 
 Try
 
 User1
 
 User2
 
 User3
 
 Yes
 
- Protected Member Functions inherited from KDialog
 KDialog (KDialogPrivate &dd, QWidget *parent, Qt::WindowFlags flags=0)
 
virtual void closeEvent (QCloseEvent *e)
 
virtual void hideEvent (QHideEvent *)
 
virtual void keyPressEvent (QKeyEvent *)
 
- Protected Attributes inherited from KDialog
KDialogPrivate *const d_ptr
 

Detailed Description

"Open With" dialog box.

Note
To let the user choose an application and run it immediately, use simpler KRun::displayOpenWithDialog().
Author
David Faure faure.nosp@m.@kde.nosp@m..org

Definition at line 39 of file kopenwithdialog.h.

Constructor & Destructor Documentation

◆ KOpenWithDialog() [1/4]

KOpenWithDialog::KOpenWithDialog ( const KUrl::List &  urls,
QWidget *  parent = 0 
)
explicit

Create a dialog that asks for a application to open a given URL(s) with.

Parameters
urlsthe URLs that should be opened. The list can be empty, if the dialog is used to choose an application but not for some particular URLs.
parentparent widget

Definition at line 478 of file kopenwithdialog.cpp.

◆ KOpenWithDialog() [2/4]

KOpenWithDialog::KOpenWithDialog ( const KUrl::List &  urls,
const QString &  text,
const QString &  value,
QWidget *  parent = 0 
)

Create a dialog that asks for a application to open a given URL(s) with.

Parameters
urlsis the URL that should be opened
textappears as a label on top of the entry box.
valueis the initial value of the line
parentparent widget

Definition at line 499 of file kopenwithdialog.cpp.

◆ KOpenWithDialog() [3/4]

KOpenWithDialog::KOpenWithDialog ( const QString &  mimeType,
const QString &  value,
QWidget *  parent = 0 
)

Create a dialog to select a service for a given mimetype.

Note that this dialog doesn't apply to URLs.

Parameters
mimeTypethe mime type we want to choose an application for.
valueis the initial value of the line
parentparent widget

Definition at line 515 of file kopenwithdialog.cpp.

◆ KOpenWithDialog() [4/4]

KOpenWithDialog::KOpenWithDialog ( QWidget *  parent = 0)

Create a dialog to select an application Note that this dialog doesn't apply to URLs.

Parameters
parentparent widget

Definition at line 532 of file kopenwithdialog.cpp.

◆ ~KOpenWithDialog()

KOpenWithDialog::~KOpenWithDialog ( )

Destructor.

Definition at line 690 of file kopenwithdialog.cpp.

Member Function Documentation

◆ accept

void KOpenWithDialog::accept ( )
protectedvirtualslot

Reimplemented from QDialog::accept()

Definition at line 956 of file kopenwithdialog.cpp.

◆ hideNoCloseOnExit()

void KOpenWithDialog::hideNoCloseOnExit ( )

Hide the "Do not &close when command exits" Checkbox.

Definition at line 970 of file kopenwithdialog.cpp.

◆ hideRunInTerminal()

void KOpenWithDialog::hideRunInTerminal ( )

Hide the "Run in &terminal" Checkbox.

Definition at line 977 of file kopenwithdialog.cpp.

◆ service()

KService::Ptr KOpenWithDialog::service ( ) const
Returns
the chosen service in the application tree Can be null, if the user typed some text and didn't select a service.

Definition at line 983 of file kopenwithdialog.cpp.

◆ setSaveNewApplications()

void KOpenWithDialog::setSaveNewApplications ( bool  b)

Set whether a new .desktop file should be created if the user selects an application for which no corresponding .desktop file can be found.

Regardless of this setting a new .desktop file may still be created if the user has chosen to remember the file association.

The default is false: no .desktop files are created.

Definition at line 756 of file kopenwithdialog.cpp.

◆ slotHighlighted

void KOpenWithDialog::slotHighlighted ( const QString &  _name,
const QString &  _exec 
)
slot

Definition at line 708 of file kopenwithdialog.cpp.

◆ slotSelected

void KOpenWithDialog::slotSelected ( const QString &  _name,
const QString &  _exec 
)
slot

Definition at line 698 of file kopenwithdialog.cpp.

◆ slotTerminalToggled

void KOpenWithDialog::slotTerminalToggled ( bool  )
slot

Definition at line 732 of file kopenwithdialog.cpp.

◆ slotTextChanged

void KOpenWithDialog::slotTextChanged ( )
slot

Definition at line 723 of file kopenwithdialog.cpp.

◆ text()

QString KOpenWithDialog::text ( ) const
Returns
the text the user entered

Definition at line 962 of file kopenwithdialog.cpp.


The documentation for this class was generated from the following files:
  • kopenwithdialog.h
  • kopenwithdialog.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Feb 20 2023 00:00:00 by doxygen 1.9.6 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KIO

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

kdelibs-4.14.38 API Reference

Skip menu "kdelibs-4.14.38 API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal