lib Library API Documentation

koInsertLink.h

00001 /* This file is part of the KDE project
00002    Copyright (C)  2001 Montel Laurent <lmontel@mandrakesoft.com>
00003 
00004    This library is free software; you can redistribute it and/or
00005    modify it under the terms of the GNU Library General Public
00006    License as published by the Free Software Foundation; either
00007    version 2 of the License, or (at your option) any later version.
00008 
00009    This library is distributed in the hope that it will be useful,
00010    but WITHOUT ANY WARRANTY; without even the implied warranty of
00011    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012    Library General Public License for more details.
00013 
00014    You should have received a copy of the GNU Library General Public License
00015    along with this library; see the file COPYING.LIB.  If not, write to
00016    the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00017    Boston, MA 02111-1307, USA.
00018 */
00019 
00020 #ifndef __KoInsertLink__
00021 #define __KoInsertLink__
00022 
00023 #include <kdialogbase.h>
00024 
00025 class QLineEdit;
00026 class KURLRequester;
00027 
00031 class internetLinkPage : public QWidget
00032 {
00033     Q_OBJECT
00034 public:
00035     internetLinkPage( QWidget *parent = 0, char *name = 0 );
00036     QString linkName()const;
00037     QString hrefName();
00038     void setLinkName(const QString & _name);
00039     void setHrefName(const QString &_name);
00040 private:
00041     QString createInternetLink();
00042     QLineEdit* m_linkName, *m_hrefName;
00043 private slots:
00044     void textChanged ( const QString & );
00045 signals:
00046     void textChanged();
00047 };
00048 
00052 class bookmarkLinkPage : public QWidget
00053 {
00054     Q_OBJECT
00055 public:
00056     bookmarkLinkPage( QWidget *parent = 0, char *name = 0 );
00057     QString linkName()const;
00058     QString hrefName();
00059     void setLinkName(const QString & _name);
00060     void setHrefName(const QString &_name);
00061     void setBookmarkList(const QStringList &bkmlist);
00062 private:
00063     QString createBookmarkLink();
00064     QLineEdit* m_linkName;
00065     QComboBox *m_hrefName;
00066 private slots:
00067     void textChanged ( const QString & );
00068 signals:
00069     void textChanged();
00070 };
00071 
00075 class mailLinkPage : public QWidget
00076 {
00077     Q_OBJECT
00078 public:
00079     mailLinkPage( QWidget *parent = 0, char *name = 0 );
00080     QString linkName()const;
00081     QString hrefName();
00082     void setLinkName(const QString & _name);
00083     void setHrefName(const QString &_name);
00084 
00085 private slots:
00086     void textChanged ( const QString & );
00087 private:
00088     QString createMailLink();
00089     QLineEdit* m_linkName, *m_hrefName;
00090 signals:
00091     void textChanged();
00092 };
00093 
00097 class fileLinkPage : public QWidget
00098 {
00099     Q_OBJECT
00100 public:
00101     fileLinkPage( QWidget *parent = 0, char *name = 0 );
00102     QString linkName()const;
00103     QString hrefName();
00104     void setLinkName(const QString & _name);
00105     void setHrefName(const QString &_name);
00106 
00107 private slots:
00108     void textChanged ( const QString & );
00109     void slotSelectRecentFile( const QString & );
00110 private:
00111     QString createFileLink();
00112     QLineEdit* m_linkName;
00113     KURLRequester* m_hrefName;
00114 signals:
00115     void textChanged();
00116 };
00117 
00121 class KoInsertLinkDia : public KDialogBase
00122 {
00123     Q_OBJECT
00124 public:
00125     KoInsertLinkDia( QWidget *parent, const char *name = 0,bool displayBookmarkLink=true );
00126     static bool createLinkDia(QString & linkName, QString & hrefName, QStringList bkmlist, bool displayBookmarkLink = true );
00127 
00128     //internal
00129     QString linkName()const;
00130     QString hrefName();
00131     void setHrefLinkName(const QString &_href, const QString &_link, const QStringList & bkmlist);
00132 protected slots:
00133     virtual void slotOk();
00134     void slotTextChanged (  );
00135 
00136 private:
00137     fileLinkPage *fileLink;
00138     mailLinkPage *mailLink;
00139     internetLinkPage *internetLink;
00140     bookmarkLinkPage *bookmarkLink;
00141 };
00142 
00143 #endif
KDE Logo
This file is part of the documentation for lib Library Version 1.3.5.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Wed Nov 17 13:19:23 2004 by doxygen 1.3.5 written by Dimitri van Heesch, © 1997-2003