KDevelop API Documentation

filecreate_newfile.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *   Copyright (C) 2003 by Julian Rockey                                   *
00003  *   linux@jrockey.com                                                     *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU General Public License as published by  *
00007  *   the Free Software Foundation; either version 2 of the License, or     *
00008  *   (at your option) any later version.                                   *
00009  ***************************************************************************/
00010 #ifndef FILECREATE_NEWFILE_H
00011 #define FILECREATE_NEWFILE_H
00012 
00013 #include <qptrlist.h>
00014 #include <qmap.h>
00015 #include <kurl.h>
00016 #include <kdialogbase.h>
00017 
00018 #include "filecreate_filetype.h"
00019 
00020 class KURLRequester;
00021 class QGridLayout;
00022 class KComboBox;
00023 class QCheckBox;
00024 class QLineEdit;
00025 
00026 namespace FileCreate {
00027   class NewFileChooser : public KDialogBase {
00028       Q_OBJECT
00029   public:
00030     NewFileChooser(QWidget *parent=0);
00031     virtual ~NewFileChooser();
00032     void setFileTypes(QPtrList<FileType> typelist);
00033     KURL url() const;
00034     bool addToProject() const;
00035     const FileType *selectedType() const;
00036     void setCurrent(const FileType *filetype);
00037     void setDirectory(const QString & url);
00038     void setName(const QString & name);
00039     
00040     void setInProjectMode(bool m);
00041   private slots:
00042       void slotFileNameChanged(const QString &);
00043   protected:
00044     void addType(const FileType * filetype);
00045     void accept();
00046 
00047     QGridLayout *m_grid;
00048     KURLRequester *m_urlreq;
00049     KComboBox *m_filetypes;
00050     QCheckBox *m_addToProject;
00051     QLineEdit *m_filename;
00052 
00053     QMap<int,const FileType*> m_typeInCombo;
00054 
00055   };
00056 
00057 }
00058 
00059 #endif
KDE Logo
This file is part of the documentation for KDevelop Version 3.1.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Wed Mar 23 00:03:56 2005 by doxygen 1.3.9.1 written by Dimitri van Heesch, © 1997-2003