• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • kio/kfile
 

kio/kfile

  • kio
  • kfile
kurlrequester.h
1 /* This file is part of the KDE libraries
2  Copyright (C) 1999,2000,2001 Carsten Pfeiffer <pfeiffer@kde.org>
3 
4  library is free software; you can redistribute it and/or
5  modify it under the terms of the GNU Library General Public
6  License version 2, as published by the Free Software Foundation.
7 
8  This library is distributed in the hope that it will be useful,
9  but WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11  Library General Public License for more details.
12 
13  You should have received a copy of the GNU Library General Public License
14  along with this library; see the file COPYING.LIB. If not, write to
15  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16  Boston, MA 02110-1301, USA.
17 */
18 
19 
20 #ifndef KURLREQUESTER_H
21 #define KURLREQUESTER_H
22 
23 #include <tqhbox.h>
24 
25 #include <keditlistbox.h>
26 #include <kfile.h>
27 #include <kpushbutton.h>
28 #include <kurl.h>
29 
30 class KComboBox;
31 class KFileDialog;
32 class KLineEdit;
33 class KURLCompletion;
34 class KURLDragPushButton;
35 
36 class TQString;
37 class TQTimer;
38 
56 class KIO_EXPORT KURLRequester : public TQHBox
57 {
58  Q_OBJECT
59  Q_PROPERTY( TQString url READ url WRITE setURL )
60  Q_PROPERTY( bool showLocalProtocol READ showLocalProtocol WRITE setShowLocalProtocol )
61  Q_PROPERTY( TQString filter READ filter WRITE setFilter )
62  Q_PROPERTY( uint mode READ mode WRITE setMode )
63 
64 public:
68  KURLRequester( TQWidget *parent=0, const char *name=0 );
69 
74  KURLRequester( const TQString& url, TQWidget *parent=0, const char *name=0 );
75 
82  KURLRequester( TQWidget *editWidget, TQWidget *parent, const char *name=0 );
86  ~KURLRequester();
87 
94  TQString url() const;
95 
102  void setShowLocalProtocol( bool b );
103 
110  void setMode( uint m );
111 
117  uint mode() const;
118 
119 
124  void setFilter( const TQString& filter );
125 
131  TQString filter() const;
132 
138  bool showLocalProtocol() const { return myShowLocalProt; }
139  // ## KDE4: there's no reason to keep this, it should always be false
140 
149  virtual KFileDialog * fileDialog() const;
150 
158  KLineEdit * lineEdit() const;
159 
164  KComboBox * comboBox() const;
165 
170  KPushButton * button() const;
171 
175  KURLCompletion *completionObject() const { return myCompletion; }
176 
188  KEditListBox::CustomEditor customEditor();
189 
190 public slots:
197  void setURL( const TQString& url );
198 
204  void setKURL( const KURL& url );
205 
210  virtual void setCaption( const TQString& caption );
211 
215  void clear();
216 
217 signals:
218  // forwards from LineEdit
224  void textChanged( const TQString& );
225 
229  void returnPressed();
230 
235  void returnPressed( const TQString& );
236 
248  void openFileDialog( KURLRequester * );
249 
255  void urlSelected( const TQString& );
256 
257 protected:
258  void init();
259 
260  KURLCompletion * myCompletion;
261 
262 
263 private:
264  KURLDragPushButton * myButton;
265  bool myShowLocalProt;
266  mutable KFileDialog * myFileDialog;
267 
268 
269 protected slots:
274  void slotOpenDialog();
275 
276 private slots:
277  void slotUpdateURL();
278 
279 protected:
280  virtual void virtual_hook( int id, void* data );
281  bool eventFilter( TQObject *obj, TQEvent *ev );
282 private:
283  class KURLRequesterPrivate;
284  KURLRequesterPrivate *d;
285 };
286 
290 class KIO_EXPORT KURLComboRequester : public KURLRequester
291 {
292  Q_OBJECT
293 public:
297  KURLComboRequester( TQWidget *parent=0, const char *name=0 );
298 };
299 
300 
301 #endif // KURLREQUESTER_H
KFileDialog
Provides a user (and developer) friendly way to select files and directories.
Definition: kfiledialog.h:78
KURLComboRequester
URL requester with a combo box, for use in Designer.
Definition: kurlrequester.h:291
KURLRequester
This class is a widget showing a lineedit and a button, which invokes a filedialog.
Definition: kurlrequester.h:57
KURLRequester::textChanged
void textChanged(const TQString &)
Emitted when the text in the lineedit changes.
KURLRequester::urlSelected
void urlSelected(const TQString &)
Emitted when the user changed the URL via the file dialog.
KURLRequester::returnPressed
void returnPressed(const TQString &)
Emitted when return or enter was pressed in the lineedit.
KURLRequester::returnPressed
void returnPressed()
Emitted when return or enter was pressed in the lineedit.
KURLRequester::openFileDialog
void openFileDialog(KURLRequester *)
Emitted before the filedialog is going to open.
KURLRequester::completionObject
KURLCompletion * completionObject() const
Definition: kurlrequester.h:175
KURLRequester::showLocalProtocol
bool showLocalProtocol() const
Definition: kurlrequester.h:138

kio/kfile

Skip menu "kio/kfile"
  • Main Page
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

kio/kfile

Skip menu "kio/kfile"
  • arts
  • dcop
  • dnssd
  • interfaces
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for kio/kfile by doxygen 1.9.1
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |