• Skip to content
  • Skip to link menu
KDE 4.3 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KIO

kurlrequester.h

Go to the documentation of this file.
00001 /* This file is part of the KDE libraries
00002     Copyright (C) 1999,2000,2001 Carsten Pfeiffer <pfeiffer@kde.org>
00003 
00004     library is free software; you can redistribute it and/or
00005     modify it under the terms of the GNU Library General Public
00006     License version 2, as published by the Free Software Foundation.
00007 
00008     This library is distributed in the hope that it will be useful,
00009     but WITHOUT ANY WARRANTY; without even the implied warranty of
00010     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00011     Library General Public License for more details.
00012 
00013     You should have received a copy of the GNU Library General Public License
00014     along with this library; see the file COPYING.LIB.  If not, write to
00015     the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00016     Boston, MA 02110-1301, USA.
00017 */
00018 
00019 #ifndef KURLREQUESTER_H
00020 #define KURLREQUESTER_H
00021 
00022 #include <keditlistbox.h>
00023 #include <kfile.h>
00024 #include <kpushbutton.h>
00025 #include <kurl.h>
00026 #include <khbox.h>
00027 
00028 class KComboBox;
00029 class KFileDialog;
00030 class KLineEdit;
00031 class KUrlCompletion;
00032 
00033 class QString;
00034 class QEvent;
00035 
00053 class KIO_EXPORT KUrlRequester : public KHBox
00054 {
00055     Q_OBJECT
00056     Q_PROPERTY( KUrl url READ url WRITE setUrl USER true )
00057     Q_PROPERTY( QString filter READ filter WRITE setFilter )
00058     Q_FLAGS( KFile::Modes )
00059     Q_PROPERTY( KFile::Modes mode READ mode WRITE setMode )
00060     Q_PROPERTY( QString clickMessage READ clickMessage WRITE setClickMessage )
00061     Q_PROPERTY(QString text READ text WRITE setText)
00062 
00063 public:
00067     explicit KUrlRequester( QWidget *parent=0);
00068 
00072     explicit KUrlRequester( const KUrl& url, QWidget *parent=0);
00073 
00080     KUrlRequester( QWidget *editWidget, QWidget *parent);
00084     ~KUrlRequester();
00085 
00091     KUrl url() const;
00092 
00097     KUrl startDir() const;
00098     
00107     QString text() const;
00108 
00115     void setMode( KFile::Modes m );
00116 
00121     KFile::Modes mode() const;
00122 
00127     void setFilter( const QString& filter );
00128 
00133     QString filter() const;
00134 
00143     virtual KFileDialog * fileDialog() const;
00144 
00152     KLineEdit * lineEdit() const;
00153 
00158     KComboBox * comboBox() const;
00159 
00164     KPushButton * button() const;
00165 
00169     KUrlCompletion *completionObject() const;
00170 
00181     const KEditListBox::CustomEditor &customEditor();
00182 
00187     QString clickMessage() const;
00188 
00193     void setClickMessage(const QString& msg);
00194 
00195 
00196 public Q_SLOTS:
00200     void setUrl( const KUrl& url );
00201     
00207     void setStartDir( const KUrl& startDir );
00208     
00217     KDE_DEPRECATED void setPath(const QString& path);
00218 
00228     void setText(const QString& text);
00229 
00233     void clear();
00234 
00235 Q_SIGNALS:
00236     // forwards from LineEdit
00241     void textChanged( const QString& );
00242 
00246     void returnPressed();
00247 
00252     void returnPressed( const QString& );
00253 
00265     void openFileDialog( KUrlRequester * );
00266 
00271     void urlSelected( const KUrl& );
00272 
00273 protected:
00274     virtual void changeEvent (QEvent *e);
00275     bool eventFilter( QObject *obj, QEvent *ev );
00276 
00277 private:
00278     class KUrlRequesterPrivate;
00279     KUrlRequesterPrivate* const d;
00280 
00281     Q_DISABLE_COPY(KUrlRequester)
00282 
00283     Q_PRIVATE_SLOT(d, void _k_slotUpdateUrl())
00284     Q_PRIVATE_SLOT(d, void _k_slotOpenDialog())
00285 
00286 };
00287 
00288 class KIO_EXPORT KUrlComboRequester : public KUrlRequester // krazy:exclude=dpointer (For use in Qt Designer)
00289 {
00290     Q_OBJECT
00291 public:
00295     explicit KUrlComboRequester(QWidget *parent = 0);
00296 
00297 private:
00298     class Private;
00299     Private* const d;
00300 };
00301 
00302 #endif // KURLREQUESTER_H

KIO

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

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.6.1
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal